fix(cli): make device status/release selectors explicit-only

Closed
PC
33m ago
+97-9

Fixes #4298

Cause. agent-device.json defaults merge into the parsed flags key by key, so a config udid survived an explicit --serial, and the claim filter (udid ?? serial) then used the config value. device status / device release therefore ignored the typed selector.

Fix. Declare platform, device, udid and serial as explicitOnlyFlags for the device command, as the maintainer's triage suggested. The existing parser step drops config/env-only values for these keys, so only typed selectors narrow claim queries.

Test. New case in src/cli/resolve-cli-options.test.ts with a config containing all four selectors: red before (config udid present), green after. Parser, repo-guard and command-surface suites pass (848 tests), oxlint and oxfmt clean on touched files.

This change was prepared with the assistance of Claude Code (AI), and submitted by a human who is accountable for it.


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.