Skip to content

Conversation

@jtharpla
Copy link
Contributor

Fixes a regression caused by #1151 where host can no longer be a list when calling connect() as this triggers the following error:

    mongoengine/connection.py line 61 in register_connection
      if conn_host.startswith('mongomock://'):
   AttributeError: 'list' object has no attribute 'startswith'

Adds a new unit test to cover this possibility and follows the same approach used by pymongo.MongoClient, which is designed to accept host as either a list or a string.

@lafrech lafrech merged commit 6767b50 into MongoEngine:master Oct 19, 2016
@lafrech
Copy link
Member

lafrech commented Oct 19, 2016

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants