Closed norendren closed 10 years ago
@seeker44 When you call the function with a local dictionary the remote function is invoked with a proxy object, not a real dict. It looks like pymongo doesn't like that.
It's not ideal, but the following will work:
spec = conn.eval("{}")
spec.update({"status": "error"})
asset.find_one(spec)
(you can inline the dictionary keys/values in the eval
if they're simple values)
You, sir, are a gentleman and a scholar. Pymongo must indeed dislike proxied dictionaries, but Pushy works entirely too well for what I'm doing to consider anything else.
Thank you SO much for the workaround!
Hi there,
I am using pushy to work with a MongoDB on a remote server and I'm running into a problem passing a dictionary to a function using the remote interpreter. I am using the pymongo library to remotely operate on the database and as you can see in the first part of the code below, calling the function with no arguments returns data successfully.
However, whenever I try to access information in the returned Mongo cursor, I get the error included in the code. If you're able to take a look at this, I would GREATLY appreciate it :)