Some libraries aren’t 100% packaged Python code, some of them are bindings to external libraries. They offer a Python interface so you can call them inside your code. On these cases, we need to install them previously at the system so the python package can work.
When that happens, we get this kind of error:
ImproperlyConfigured: Error loading either pysqlite2 or sqlite3 modules (tried in that order): No module named _sqlite3 To solve errors like that, you need to install the external library, and the system configures everything to you.