Skip to content

Python 3.13 compatibility issue: SQLite objects created in a thread can only be used in that same thread. #46

@guillaume-fr

Description

@guillaume-fr

Python 3.13 added a SQLITE provider for DBM
https://docs.python.org/3/library/dbm.html#module-dbm.sqlite3
python/cpython#114481

It's the first in provider list, it'll be used by default.

I'm getting the following error

error: SQLite objects created in a thread can only be used in that same thread. The object was created in thread id 8448270080 and this is thread id 6155415552.

It's likely related to the following issue: python/cpython#131918

Workaround: re-generate .bossmancache database with an old python version (without dbm.sqlite).

rm .bossmancache
uvx --python 3.12 bossman apply

Once the db file is initialized, you can use 3.13 as dbm will detect format and NOT use SQLITE.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions