SQLite objects created in a thread can only be used in that same thread with Django 2.2.2 and ipdb
Try using the --reload
flag to run runserver. ./manage.py runserver --noreload
It stops the server reloading on code changes but I think avoids the issue you're having.