Really-amin commited on
Commit
c05d01c
·
verified ·
1 Parent(s): 52e380b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -6
app.py CHANGED
@@ -1,3 +1,9 @@
 
 
 
 
 
 
1
  import gradio as gr
2
  import pandas as pd
3
  import plotly.graph_objects as go
@@ -12,7 +18,7 @@ import traceback
12
 
13
  # Import local modules
14
  import config
15
- import database # برای database.get_database()
16
  import collectors
17
  import ai_models
18
  import utils
@@ -21,9 +27,7 @@ import utils
21
  logger = utils.setup_logging()
22
 
23
  # Initialize database
24
- db = database.get_database()
25
-
26
- # Global state for background collection
27
 
28
  # Global state for background collection
29
  _collection_started = False
@@ -1449,7 +1453,7 @@ def main():
1449
 
1450
  # Initialize database
1451
  logger.info("Initializing database...")
1452
- db = database.get_database()
1453
  logger.info("Database initialized successfully")
1454
 
1455
  # Start background data collection
@@ -1488,4 +1492,4 @@ def main():
1488
 
1489
 
1490
  if __name__ == "__main__":
1491
- main()
 
1
+ #!/usr/bin/env python3
2
+ """
3
+ Crypto Data Aggregator - Complete Gradio Dashboard
4
+ 6-tab comprehensive interface for cryptocurrency data analysis
5
+ """
6
+
7
  import gradio as gr
8
  import pandas as pd
9
  import plotly.graph_objects as go
 
18
 
19
  # Import local modules
20
  import config
21
+ from database import Database
22
  import collectors
23
  import ai_models
24
  import utils
 
27
  logger = utils.setup_logging()
28
 
29
  # Initialize database
30
+ db = Database()
 
 
31
 
32
  # Global state for background collection
33
  _collection_started = False
 
1453
 
1454
  # Initialize database
1455
  logger.info("Initializing database...")
1456
+ db = Database()
1457
  logger.info("Database initialized successfully")
1458
 
1459
  # Start background data collection
 
1492
 
1493
 
1494
  if __name__ == "__main__":
1495
+ main()