Add authentication
This commit is contained in:
10
app/db.py
10
app/db.py
@@ -0,0 +1,10 @@
|
||||
import sqlite3
|
||||
from pathlib import Path
|
||||
|
||||
BASE_DIR = Path(__file__).resolve().parent.parent
|
||||
DB_PATH = BASE_DIR / "data" / "app.db"
|
||||
|
||||
|
||||
def get_conn():
|
||||
# check_same_thread=False, damit Streamlit mehrere Threads nutzen kann
|
||||
return sqlite3.connect(DB_PATH, check_same_thread=False)
|
||||
|
||||
Reference in New Issue
Block a user