13 lines
471 B
Python
13 lines
471 B
Python
import sqlite3, uuid
|
|
from datetime import datetime
|
|
|
|
db_path = '/home/hmo/.hermes/kanban.db'
|
|
db = sqlite3.connect(db_path)
|
|
# inspect schema
|
|
schema = db.execute("SELECT sql FROM sqlite_master WHERE name='tasks'").fetchone()
|
|
print(schema[0] if schema else 'no tasks table')
|
|
print()
|
|
# recent rows to see id format and fields
|
|
for r in db.execute("SELECT id, title, status, assignee, created_by, created_at FROM tasks ORDER BY created_at DESC LIMIT 5"):
|
|
print(r)
|
|
db.close() |