-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/uri based construction #42
base: dev
Are you sure you want to change the base?
Conversation
# Conflicts: # py2store/persisters/mongo_w_pymongo.py
There are persisters that I could not think of a proper way to add uri/collection args:
Also, while implementing it, there were persisters with 2 kinds of URI param - as a string like
And I feel concerned about this. 2 types, not consistent. Maybe convert string-typed URIs to dict ones also. Would be more complex to use, but more consistent overall. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What we talked about during our chat...
files_list_folder_kwargs=None, rev=None): | ||
def __init__( | ||
self, | ||
rootdir, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rootdir? Or uri?
data_fields=None, | ||
): | ||
db_name = uri.pop('db_name') | ||
self._mongo_client = MongoClient(**uri) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like old interface is broken with this. Need to either change all usages of MongoPersister, or handle the case where uri is db_name. I'll look into this myself, but note this effect for other persisters you take care of.
Per #38