As discussed with @igorbenav, this PR closes #138.
I took the freedom to marginally expand the documentation and rationale of using ARQ Job Queues and added a small h4 section on dealing with a database session.
On a semi-related note, another aspect we could futher explore is dealing with Pydantic objects in these tasks, as ARQ does not deal with them correctly due to serialization. Some approaches require you to cast them back to Pydantic (your_object = YourObjectPydanticClass(**your_object_dict_from_db) some just deal with them as dictionaries. Might be useful to point users to a best practice?
On a less-related note, @igorbenav I'd love to contribute more and have some ideas to improve the project I'd like to explore. Feel free to drop me a note using my email on my profile.
As discussed with @igorbenav, this PR closes #138.
I took the freedom to marginally expand the documentation and rationale of using ARQ Job Queues and added a small h4 section on dealing with a database session.
On a semi-related note, another aspect we could futher explore is dealing with Pydantic objects in these tasks, as ARQ does not deal with them correctly due to serialization. Some approaches require you to cast them back to Pydantic (
your_object = YourObjectPydanticClass(**your_object_dict_from_db)
some just deal with them as dictionaries. Might be useful to point users to a best practice?On a less-related note, @igorbenav I'd love to contribute more and have some ideas to improve the project I'd like to explore. Feel free to drop me a note using my email on my profile.