Optional env var handling #24

Merged
quoije merged 3 commits from cursor/optional-env-var-handling-ebfa into 2026 2025-12-21 14:56:19 -05:00
quoije commented 2025-12-21 14:42:11 -05:00 (Migrated from github.com)

Gracefully handle missing DOG_NAMES and OMDB_API environment variables to prevent registration failures and OMDb-related errors.

If DOG_NAMES is not configured, user registration now bypasses the 'dog name' check instead of always failing. For OMDB_API, adding movies proceeds with placeholders if the key is missing, and refreshing OMDb data returns a 503 error, preventing invalid external API calls and improving error handling.


Open in Cursor Open in Web

Gracefully handle missing `DOG_NAMES` and `OMDB_API` environment variables to prevent registration failures and OMDb-related errors. If `DOG_NAMES` is not configured, user registration now bypasses the 'dog name' check instead of always failing. For `OMDB_API`, adding movies proceeds with placeholders if the key is missing, and refreshing OMDb data returns a 503 error, preventing invalid external API calls and improving error handling. --- <a href="https://cursor.com/background-agent?bcId=bc-bc6ca869-298b-4b03-8dbb-3cb202640052"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/open-in-cursor-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/open-in-cursor-light.svg"><img alt="Open in Cursor" src="https://cursor.com/open-in-cursor.svg"></picture></a>&nbsp;<a href="https://cursor.com/agents?id=bc-bc6ca869-298b-4b03-8dbb-3cb202640052"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/open-in-web-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/open-in-web-light.svg"><img alt="Open in Web" src="https://cursor.com/open-in-web.svg"></picture></a>
cursor[bot] commented 2025-12-21 14:42:12 -05:00 (Migrated from github.com)

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

Cursor Agent can help with this pull request. Just `@cursor` in comments and I'll start working on changes in this branch. <sub>[Learn more](https://cursor.com/docs/background-agent/web-and-mobile) about Cursor Agents</sub>
Sign in to join this conversation.