Swift-Query / tests /check_env.py
Darshan Kumar R
Deploy to Hugging Face Spaces (Clean)
ed0b977
Raw History Blame Contribute Delete
312 Bytes
import os
from dotenv import load_dotenv
load_dotenv()
uri = os.environ.get("MONGO_URI")
if uri:
if "<db_password>" in uri:
print("ERROR: Placeholder <db_password> found in MONGO_URI.")
else:
print(f"MONGO_URI found: {uri[:15]}...{uri[-10:]}")
else:
print("MONGO_URI NOT found.")