Skip to content

[Bug] Environment Variable Conflicts Not Detected - Overrides Cause Issues #374

@anshul23102

Description

@anshul23102

Description

Environment variable conflicts are not detected when multiple configurations set the same variable. Later values override earlier ones without notification. Users don't realize their configuration is being overridden.

Steps to Reproduce

  1. Config A sets: export NODE_ENV=development
  2. Config B sets: export NODE_ENV=production
  3. Both loaded in same environment
  4. No conflict warning shown
  5. Production config silently overrides development

Environment Information

  • Config loading: Multiple sources (global, project, user)
  • Variables: Environment variables
  • Conflict detection: Not implemented
  • Logging: No warning on override

Expected Behavior

  • Conflict detected before applying variables
  • Warning message shown to user
  • Manual resolution required
  • Clear indication of which config wins

Actual Behavior

  • Silent override (last one wins)
  • No warning or notification
  • User unaware of conflict
  • Debugging is difficult

Code Reference

  • File: src/devshell/config_loader.py
  • Method: load_variables() - no conflict detection
  • Missing: Variable tracking and logging
  • Missing: Conflict resolution strategy

Additional Context

Level 2 reliability issue. Fix requires:

  • Tracking all variable assignments
  • Detecting and reporting conflicts
  • User-configurable conflict resolution
  • Clear documentation

Suggested Labels

bug, configuration, developer-experience, debugging, env-vars

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions