Ali2206 commited on
Commit
f2be85d
·
1 Parent(s): 09d17f9

Fix logger issue in app.py - Replace logger calls with print statements before logger is defined, and remove mongodb.env.example file

Browse files
Files changed (2) hide show
  1. app.py +3 -3
  2. mongodb.env.example +0 -8
app.py CHANGED
@@ -41,13 +41,13 @@ from dotenv import load_dotenv
41
  # For Hugging Face Spaces, environment variables are set in the Space settings
42
  try:
43
  load_dotenv('mongodb.env')
44
- logger.info("✅ Loaded environment variables from mongodb.env")
45
  except:
46
  try:
47
  load_dotenv('.env')
48
- logger.info("✅ Loaded environment variables from .env")
49
  except:
50
- logger.info("ℹ️ No .env file found, using system environment variables")
51
 
52
  # Configure logging
53
  logging.basicConfig(
 
41
  # For Hugging Face Spaces, environment variables are set in the Space settings
42
  try:
43
  load_dotenv('mongodb.env')
44
+ print("✅ Loaded environment variables from mongodb.env")
45
  except:
46
  try:
47
  load_dotenv('.env')
48
+ print("✅ Loaded environment variables from .env")
49
  except:
50
+ print("ℹ️ No .env file found, using system environment variables")
51
 
52
  # Configure logging
53
  logging.basicConfig(
mongodb.env.example DELETED
@@ -1,8 +0,0 @@
1
- # MongoDB Configuration
2
- MONGODB_URI=mongodb+srv://yakdhanali97:Syrou2206@cluster0.szf60ea.mongodb.net/audit_checklist?retryWrites=true&w=majority&appName=Cluster0
3
-
4
- # Server Configuration
5
- PORT=5000
6
-
7
- # CORS Configuration
8
- CORS_ORIGIN=http://localhost:3000