osdir.com


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to specify sqlite engine path in sqlalchemy using Zipapp


I don't know how to specify sqlalchemy's engine path for sqlite within
zipapp.

Using:

engine = create_engine('sqlite:///{}'.format(
        os.path.join(dirp, 'db/items.db')
    ))

i get

unable to open database file

I've rounded the problem with as much info as possible here:

https://stackoverflow.com/questions/59767920/how-to-specify-sqlite-engine-path-in-sqlalchemy-using-zipapp

It seems that you can read db files from zips but i'm asking how you maange
sqlalchemy.

Thank You.

Yours,

Abdur-Rahmaan Janhangeer
pythonmembers.club <http://www.pythonmembers.club/> | github
<https://github.com/Abdur-rahmaanJ>
Mauritius