Spaces:
Sleeping
Sleeping
Update planmate/config.py
Browse files22 unmodified lines23242526272822 unmodified linesOPENWEATHER_BASE = "https://api.openweathermap.org"OPENTRIPMAP_BASE = "https://api.opentripmap.com/0.1/en"def get_env(key: str) -> str:val = os.getenv(key)if not val:22 unmodified lines232425262728293031323334353637383940414243444522 unmodified linesOPENWEATHER_BASE = "https://api.openweathermap.org"OPENTRIPMAP_BASE = "https://api.opentripmap.com/0.1/en"# ---------- Hugging Face Secrets Configuration ----------def get_secret(key, default=None):"""Get secret from Hugging Face Spaces environment or fallback to local .env"""# Try to get from environment first (Hugging Face Spaces)value = os.getenv(key)if value is None and default is not None:return defaultelif value is None:st.error(f"Missing required secret: {key}")st.info("Please add this secret in your Hugging Face Space settings.")st.stop()return valuedef get_env(key: str) -> str:val = os.getenv(key)if not val:
planmate/config.py+17