Spaces:
Runtime error
Runtime error
fix: use connection context in load_preprocessed_projects to resolve pandas engine warnings
Browse files
Data/database/sql_connector.py
CHANGED
|
@@ -56,10 +56,11 @@ def load_preprocessed_projects():
|
|
| 56 |
FROM PreProcessed_Projects
|
| 57 |
"""
|
| 58 |
|
| 59 |
-
|
| 60 |
-
|
| 61 |
-
|
| 62 |
-
|
|
|
|
| 63 |
|
| 64 |
if "features" in df.columns:
|
| 65 |
|
|
|
|
| 56 |
FROM PreProcessed_Projects
|
| 57 |
"""
|
| 58 |
|
| 59 |
+
with engine.connect() as conn:
|
| 60 |
+
df = pd.read_sql(
|
| 61 |
+
query,
|
| 62 |
+
conn
|
| 63 |
+
)
|
| 64 |
|
| 65 |
if "features" in df.columns:
|
| 66 |
|