Error creating new user - AttributeError: 'Database' object has no attribute 'inserted_id'
mhkc opened this issue · comments
Describe the bug
I get the following stack trace when trying to create a user using bonsai API cli.
command: docker-compose -f docker-compose.markus.new.yml exec api bonsai_api create-user -u user -p user -r user
File "/home/worker/app/app/cli.py", line 80, in create_user
loop.run_until_complete(func)
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 653, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "/home/worker/app/app/crud/user.py", line 42, in create_user
inserted_id = db_obj.inserted_id
^^^^^^^^^^^^^^^^^^
AttributeError: 'Database' object has no attribute 'inserted_id'