Spaces:
Running
Running
Commit ·
96a9109
1
Parent(s): bcbd2ec
Cleanup: Remove debug logs and development config
Browse files- Remove reload=True from uvicorn config (production safety)
- Remove DEBUG print statements from knowledge_graphs.py
- Remove toast debug console.log from NotificationContext
- Remove proxy debug console.log from vite.config.ts
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
backend/main.py
CHANGED
|
@@ -95,7 +95,7 @@ def main():
|
|
| 95 |
host=args.host,
|
| 96 |
port=port,
|
| 97 |
log_level=args.log_level.lower(),
|
| 98 |
-
reload=
|
| 99 |
)
|
| 100 |
except KeyboardInterrupt:
|
| 101 |
logger.info("Server stopped by user")
|
|
|
|
| 95 |
host=args.host,
|
| 96 |
port=port,
|
| 97 |
log_level=args.log_level.lower(),
|
| 98 |
+
reload=False
|
| 99 |
)
|
| 100 |
except KeyboardInterrupt:
|
| 101 |
logger.info("Server stopped by user")
|
backend/routers/knowledge_graphs.py
CHANGED
|
@@ -965,10 +965,6 @@ async def get_stage_results(kg_id: str, stage: str, session: Session = Depends(g
|
|
| 965 |
reconstructions_data = []
|
| 966 |
for pr in prompt_reconstructions:
|
| 967 |
relation = relations_map.get(pr.relation_id)
|
| 968 |
-
print(f"DEBUG: Looking for relation_id '{pr.relation_id}' in relations_map")
|
| 969 |
-
print(f"DEBUG: Available relation IDs: {list(relations_map.keys())}")
|
| 970 |
-
print(f"DEBUG: Found relation: {relation}")
|
| 971 |
-
|
| 972 |
reconstruction = {
|
| 973 |
"id": pr.id, "relation_id": pr.relation_id, "reconstructed_prompt": pr.reconstructed_prompt,
|
| 974 |
"dependencies": pr.dependencies, "created_at": pr.created_at.isoformat() if pr.created_at else None,
|
|
|
|
| 965 |
reconstructions_data = []
|
| 966 |
for pr in prompt_reconstructions:
|
| 967 |
relation = relations_map.get(pr.relation_id)
|
|
|
|
|
|
|
|
|
|
|
|
|
| 968 |
reconstruction = {
|
| 969 |
"id": pr.id, "relation_id": pr.relation_id, "reconstructed_prompt": pr.reconstructed_prompt,
|
| 970 |
"dependencies": pr.dependencies, "created_at": pr.created_at.isoformat() if pr.created_at else None,
|
frontend/src/context/NotificationContext.tsx
CHANGED
|
@@ -40,11 +40,6 @@ export function NotificationProvider({ children }: { children: ReactNode }) {
|
|
| 40 |
};
|
| 41 |
|
| 42 |
const variant = getToastVariant(notification.type);
|
| 43 |
-
console.log("🍞 Toast call:", {
|
| 44 |
-
type: notification.type,
|
| 45 |
-
variant,
|
| 46 |
-
title: notification.title,
|
| 47 |
-
});
|
| 48 |
|
| 49 |
toast({
|
| 50 |
title: notification.title,
|
|
|
|
| 40 |
};
|
| 41 |
|
| 42 |
const variant = getToastVariant(notification.type);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 43 |
|
| 44 |
toast({
|
| 45 |
title: notification.title,
|
frontend/vite.config.ts
CHANGED
|
@@ -36,28 +36,12 @@ export default defineConfig({
|
|
| 36 |
target: process.env.VITE_API_URL || "http://127.0.0.1:5280",
|
| 37 |
changeOrigin: true,
|
| 38 |
secure: false,
|
| 39 |
-
configure: (proxy, _options) => {
|
| 40 |
-
proxy.on("error", (err, req, res) => {
|
| 41 |
-
console.log("proxy error", err);
|
| 42 |
-
});
|
| 43 |
-
proxy.on("proxyReq", (proxyReq, req, _res) => {
|
| 44 |
-
console.log("Proxying to backend:", req.method, req.url);
|
| 45 |
-
});
|
| 46 |
-
},
|
| 47 |
timeout: 60000,
|
| 48 |
},
|
| 49 |
"/auth": {
|
| 50 |
target: process.env.VITE_API_URL || "http://127.0.0.1:5280",
|
| 51 |
changeOrigin: true,
|
| 52 |
secure: false,
|
| 53 |
-
configure: (proxy, _options) => {
|
| 54 |
-
proxy.on("error", (err, req, res) => {
|
| 55 |
-
console.log("auth proxy error", err);
|
| 56 |
-
});
|
| 57 |
-
proxy.on("proxyReq", (proxyReq, req, _res) => {
|
| 58 |
-
console.log("Proxying auth to backend:", req.method, req.url);
|
| 59 |
-
});
|
| 60 |
-
},
|
| 61 |
timeout: 60000,
|
| 62 |
},
|
| 63 |
},
|
|
|
|
| 36 |
target: process.env.VITE_API_URL || "http://127.0.0.1:5280",
|
| 37 |
changeOrigin: true,
|
| 38 |
secure: false,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 39 |
timeout: 60000,
|
| 40 |
},
|
| 41 |
"/auth": {
|
| 42 |
target: process.env.VITE_API_URL || "http://127.0.0.1:5280",
|
| 43 |
changeOrigin: true,
|
| 44 |
secure: false,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 45 |
timeout: 60000,
|
| 46 |
},
|
| 47 |
},
|