Qalam commited on
Commit
cbf2be6
·
verified ·
1 Parent(s): f3c6339

Upload app.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. app.py +3 -5
app.py CHANGED
@@ -37,10 +37,9 @@ try:
37
  from loguru import logger
38
  import plotly.express as px
39
  gradio_available = True
40
- except Exception as e:
41
- print(f"WARNING: Initialization error: {e}")
42
- import traceback
43
- traceback.print_exc()
44
  gradio_available = False
45
 
46
  try:
@@ -1038,7 +1037,6 @@ def sync_to_hf_dataset(report: Dict) -> bool:
1038
  """Sync a cycle report to the public HF dataset."""
1039
  try:
1040
  from huggingface_hub import HfApi, create_repo
1041
- # from huggingface_hub import HfFolder # Removed to avoid import error
1042
  hf_token = os.getenv("HF_TOKEN", "").strip()
1043
  if not hf_token or not hf_token.startswith("hf_"):
1044
  return False
 
37
  from loguru import logger
38
  import plotly.express as px
39
  gradio_available = True
40
+ except ImportError as e:
41
+ print(f"WARNING: Missing dependency: {e}")
42
+ print("Install with: pip install gradio pandas loguru plotly")
 
43
  gradio_available = False
44
 
45
  try:
 
1037
  """Sync a cycle report to the public HF dataset."""
1038
  try:
1039
  from huggingface_hub import HfApi, create_repo
 
1040
  hf_token = os.getenv("HF_TOKEN", "").strip()
1041
  if not hf_token or not hf_token.startswith("hf_"):
1042
  return False