Spaces:
Runtime error
Runtime error
no need for json
Browse files
app.py
CHANGED
|
@@ -70,10 +70,10 @@ def update_repository():
|
|
| 70 |
with sqlite3.connect("./data/prompts.db") as db:
|
| 71 |
db.row_factory = sqlite3.Row
|
| 72 |
result = db.execute("SELECT * FROM prompts").fetchall()
|
| 73 |
-
data = [dict(row) for row in result]
|
| 74 |
|
| 75 |
-
with open('./data/data.json', 'w') as f:
|
| 76 |
-
|
| 77 |
|
| 78 |
print("Updating repository")
|
| 79 |
repo.push_to_hub(blocking=False)
|
|
|
|
| 70 |
with sqlite3.connect("./data/prompts.db") as db:
|
| 71 |
db.row_factory = sqlite3.Row
|
| 72 |
result = db.execute("SELECT * FROM prompts").fetchall()
|
| 73 |
+
# data = [dict(row) for row in result]
|
| 74 |
|
| 75 |
+
# with open('./data/data.json', 'w') as f:
|
| 76 |
+
# json.dump(data, f, separators=(',', ':'))
|
| 77 |
|
| 78 |
print("Updating repository")
|
| 79 |
repo.push_to_hub(blocking=False)
|