Skip to content

CodeWhale Config Paths Fragmented Across OS and Cygwin (Plus Silent Migration Bug) #2369

Description

@buko

config-mismatch.patch

Config and secret paths diverge across environments

Original report

On Windows and Cygwin, configuration files can resolve through different home-directory rules. A legacy migration can also leave users editing an old file that is no longer authoritative. The attached community patch is useful evidence, but its forced banner-and-exit behavior is not accepted without a separate design review.

Current v0.9.3 scope

Re-audit current main before changing code: some path consolidation has landed since this report. The remaining contract is one resolver for Codewhale home, config, settings, sessions, and the file-backed secret store, with explicit compatibility migration and diagnostics.

Acceptance criteria

  • One canonical home resolver is used by config, settings, sessions, credentials, provider setup, diagnostics, and migration code.
  • An explicit Codewhale-home override has the same meaning in every process and terminal; platform fallbacks are documented and covered on Unix, native Windows, and Cygwin-like environments.
  • Every provider credential entry flow writes through the same selected secret backend and a second fresh terminal using the same home can read the credential.
  • Diagnostics report the resolved home, config/settings paths, selected secret backend, and present/missing state without ever printing a secret value.
  • Legacy migration is idempotent, records source and destination, preserves the original until success is verified, and gives a concise notice without an unconditional process exit.
  • Conflicting legacy/current files produce a truthful actionable diagnostic instead of silently choosing an unexpected file.
  • Tests isolate all homes/backends and prove no dependence on the developer machine.

Related UI ownership: #3957.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingmigrationProject rename and compatibility migration workreliabilityReliability, flaky behavior, retries, fallbacks, and robustnessv0.9.3Targeting v0.9.3

    Projects

    Status
    Backlog

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions