Closed Abdur-rahmaanJ closed 5 months ago
@Abdur-rahmaanJ What is the error you are seeing?
Sorry, filling up
I began experiencing sqlite errors on 3 python hosts,
dbapi = dbapi_meth(**dbapi_args)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/render/project/src/.venv/lib/python3.11/site-packages/sqlalchemy_libsql/__init__.py", line 92, in import_dbapi
from libsql_client import dbapi2 as libsql_client
File "/opt/render/project/src/.venv/lib/python3.11/site-packages/libsql_client/dbapi2/__init__.py", line 16, in <module>
from ._reexports import * # noqa: F401,F403
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/render/project/src/.venv/lib/python3.11/site-packages/libsql_client/dbapi2/_reexports.py", line 76, in <module>
from sqlite3.dbapi2 import (
ImportError: cannot import name 'SQLITE_BUSY_TIMEOUT' from 'sqlite3.dbapi2' (/usr/local/lib/python3.11/sqlite3/dbapi2.py)
The app runs fine on my PC, mint 20 with Python3.11, and Python3.12 though. It just gives errors on deploys.
While searching for an answer i saw this SO post about AttributeNotFound for SQLite, with the issue being a file named sqlite3.py present in the target project.
Iit's never a good idea, irrespective of my issue to name a file the same as a module or package, happens often when people name their first Flask app, flask.py.
The project i was trying to deploy is this one: https://github.com/linkversity/linkversity
I contacted Render's support, they are as clueless as me.
So, @penberg hope it helps!
It renames sqlite3.py to sqlite3_utils and renames imports accordingly.
@penberg You have an idea when this fix will be deployed?
@Abdur-rahmaanJ I just released 0.3.1 with this fix.
…d runtime errors