Skip to content
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

PPDB no versions for pymongo specified #8

Open
Brinsby opened this issue Mar 3, 2022 · 0 comments
Open

PPDB no versions for pymongo specified #8

Brinsby opened this issue Mar 3, 2022 · 0 comments

Comments

@Brinsby
Copy link

Brinsby commented Mar 3, 2022

Installing the latest pymongo breaks this code for the ppdb sub project. There is no listing of the version of pymongo needed for this to work.

If you would like to keep it up to date with the latest I think you need to change the following offending lines
Both are located in ppdb.py Lines 103 & 104

self.db["incidents"].update({"_id": i["_id"]}, i, upsert=True) -> self.db["incidents"].insert_one({"_id": i["_id"]}, i) which does not exactly fix the issue because it no longer does the upsert

self.db["schedule"].find_and_modify({"_id": a_id}, {"$set": {"last_update": datetime.datetime.now()}}) -> self.db["schedule"].find_one_and_update({"_id": a_id}, {"$set": {"last_update": datetime.datetime.now()}})

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

No branches or pull requests

1 participant