ApiLogicServer / ApiLogicServer-src

Create an executable project (API and Admin App) from a database or natural language prompt with 1 command, customize with declarative rules and Python in your IDE, containerize and deploy.
https://apilogicserver.github.io/Docs/
BSD 3-Clause "New" or "Revised" License
30 stars 5 forks source link

Multiple Database support failing due to config error #24

Closed valhuber closed 1 year ago

valhuber commented 1 year ago

Adding a database to a project can cause errors like this when accessing database via swagger:

Generic Error: (sqlite3.OperationalError) no such table
valhuber commented 1 year ago

Investigation indicates that you can fix this by updating config.py to designate the proper url, eg.

    SQLALCHEMY_DATABASE_URI_TODO = 'sqlite:///../database/Todo_db.sqlite'    # repair uri like this
    app_logger.info(f'config.py - SQLALCHEMY_DATABASE_URI_TODO: {SQLALCHEMY_DATABASE_URI_TODO}\n')
valhuber commented 1 year ago

Fixed in 9.05.08