MEDIUM: Hardcoded URLs and Configuration Values #8
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Many URLs and configuration values are hardcoded in the codebase, making it difficult to change deployment targets or API endpoints.
Where It Occurs
Why This Is a Problem
What Can Go Wrong
Scenario 1: Switching to New LLM Provider
Scenario 2: Staging Environment
Proposed Fix
Move all configuration to config.yaml and load via ConfigManager.
Severity
MEDIUM - Hardcoded values make deployment difficult and error-prone.
Files Affected
bot/globals.py, bot/config.py, bot/utils/llm.py, bot/api.py, config.yaml
Closing as Invalid - All URLs are already environment-configurable, not hardcoded. In bot/globals.py lines 25-26 and 36, all URLs use os.getenv() with Docker service name defaults: LLAMA_URL, LLAMA_AMD_URL, and CHESHIRE_CAT_URL. This is the standard pattern for docker-compose deployments. The defaults are appropriate Docker service names that work in the compose network.