Spaces:
Runtime error
Runtime error
Commit
·
5a3212d
1
Parent(s):
6b08a33
Update app.py
Browse files
app.py
CHANGED
@@ -44,7 +44,7 @@ except sqlite3.OperationalError:
|
|
44 |
'''
|
45 |
CREATE TABLE reviews (id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
|
46 |
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP NOT NULL,
|
47 |
-
name TEXT, rate INTEGER,
|
48 |
''')
|
49 |
db.commit()
|
50 |
db.close()
|
@@ -59,7 +59,7 @@ def get_latest_reviews(db: sqlite3.Connection):
|
|
59 |
def ccogsphere(name: str, rate: int, celsci: str):
|
60 |
db = sqlite3.connect(DB_FILE)
|
61 |
cursor = db.cursor()
|
62 |
-
|
63 |
db.commit()
|
64 |
reviews, total_reviews = get_latest_reviews(db)
|
65 |
db.close()
|
|
|
44 |
'''
|
45 |
CREATE TABLE reviews (id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
|
46 |
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP NOT NULL,
|
47 |
+
name TEXT, rate INTEGER, celsci_Result TEXT)
|
48 |
''')
|
49 |
db.commit()
|
50 |
db.close()
|
|
|
59 |
def ccogsphere(name: str, rate: int, celsci: str):
|
60 |
db = sqlite3.connect(DB_FILE)
|
61 |
cursor = db.cursor()
|
62 |
+
reviews = pd.DataFrame(reviews, columns=["id", "date_created", "name", "rate", "celsci_Result"])
|
63 |
db.commit()
|
64 |
reviews, total_reviews = get_latest_reviews(db)
|
65 |
db.close()
|