Skip to content

Cowork diagnostic polish — hide experimental key and fix verbose log #923

@sergio-sisternes-epam

Description

@sergio-sisternes-epam

Follow-up to #913. Surfaced by the APM Expert Review Panel (CLI Logging specialist). MEDIUM severity, cosmetic / discoverability. CEO arbitration: acceptable as follow-ups.

1. _valid_config_keys() leaks cowork-skills-dir when flag is off

File: src/apm_cli/commands/config.py:56 (approx)

cowork-skills-dir always appears in the valid-keys list used for error messages. A user with the cowork flag disabled sees this key in "unknown config key" suggestions — leaks experimental surface awareness.

Display-side gating is already correct in apm config list (the row is hidden when the flag is off). Mirror that pattern here.

Fix: gate cowork-skills-dir in _valid_config_keys() on experimental.is_enabled("cowork"). unset path stays ungated (safety valve).

2. Verbose target log prints placeholder root_dir instead of resolved OneDrive path

File: src/apm_cli/install/phases/targets.py:70-71

The --verbose target listing prints cowork (~/cowork/) — the placeholder root_dir from the TargetProfile constructor — instead of the real resolved OneDrive path. Debugging output becomes actively misleading.

Fix: when logging cowork, prefer target.resolved_deploy_root (or target.deploy_path() result) over target.root_dir.


Acceptance criteria

  • apm config set unknown-key value with cowork flag OFF does not mention cowork-skills-dir in the valid-keys list; with flag ON it does.
  • apm install --target cowork --global --verbose prints the actual resolved OneDrive directory.
  • Unit tests for both branches of the config-key gating.

/cc panel review: #913

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/cliCLI command surface, flags, help text (cross-cutting).area/multi-targetMulti-target deploy spec, target directory creation, agent surface routing.enhancementDeprecated: use type/feature. Kept for issue history; will be removed in milestone 0.10.0.experimentalstatus/acceptedDirection approved, safe to start work.status/triagedInitial agentic triage complete; pending maintainer ratification (silence = approval).type/bugSomething does not work as documented.

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions