Reputation: 2821
I can't connect mongodb on server with debian and python 2.6.6 on this line:
connection = pymongo.Connection('mongodb://localhost', safe = True)
TypeError: init() got an unexpected keyword argument 'safe'
The same code works on window machine with python 2.7.3. Could you please explain how to correct this error?
I have pymongo version 2.3 on machine where it works and 1.7 where it doesn't work.
Upvotes: 1
Views: 1373
Reputation:
Ensure that both servers have the same pymongo version installed. Likely a version mismatch with slightly different parameter lists for the Connection constructor.
Upvotes: 1