Update app.py
Browse files
app.py
CHANGED
@@ -48,10 +48,10 @@ except Exception as e:
|
|
48 |
# MongoDB API configuration for text analysis results
|
49 |
#mongo_connection_string = os.environ.get("MONGODB_CONNECTION_STRING")
|
50 |
cosmos_mongodb_connection_string = os.getenv("MONGODB_CONNECTION_STRING")
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
|
56 |
# Variable global para el cliente de MongoDB
|
57 |
mongo_client = None
|
|
|
48 |
# MongoDB API configuration for text analysis results
|
49 |
#mongo_connection_string = os.environ.get("MONGODB_CONNECTION_STRING")
|
50 |
cosmos_mongodb_connection_string = os.getenv("MONGODB_CONNECTION_STRING")
|
51 |
+
if not cosmos_mongodb_connection_string:
|
52 |
+
logger.error("La variable de entorno MONGODB_CONNECTION_STRING no está configurada")
|
53 |
+
else:
|
54 |
+
logger.info("La variable de entorno MONGODB_CONNECTION_STRING está configurada")
|
55 |
|
56 |
# Variable global para el cliente de MongoDB
|
57 |
mongo_client = None
|