Migrate snapcraft_legacy store commands
Metadata
Current evaluation
Partially completed. Migrated upload-metadata and set-default-track to modern snapcraft code. Promote and metrics commands deferred to a separate effort. Issue closed.
Suggested action: —
No scores available.
Issue body
### What needs to get done
Migrate the following commands to modern Snapcraft code.
* These commands use `snapcraft_legacy.store_api.StoreClient`
* Use the publisher gateway if possible, otherwise they will need to be implemented in snapcraft's store service
- [x] `snapcraft upload-metadata` (#6109)
- [ ] `snapcraft promote`
- [x] `snapcraft set-default-track` (https://github.com/canonical/snapcraft/pull/6128)
- [ ] `snapcraft metrics`
### Why it needs to get done
To use a modern craft-store client
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| qwen/qwen3.6-35b-a3b | — | — | Partially completed. Migrated upload-metadata and set-default-track to modern snapcraft code. Promote and metrics commands deferred to a separate effort. Issue closed. | |
| qwen/qwen3.6-35b-a3b | — | — | Migrated upload-metadata and set-default-track commands to modern snapcraft code. The issue is closed as completed, with promote and metrics deferred to a separate migration effort. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Closed as completed after merging PRs #6109 and #6128, which migrated upload-metadata and set-default-track to modern Snapcraft. promote and metrics deferred to a separate effort. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Resolved by migrating upload-metadata and set-default-track commands to modern snapcraft code using the craft-store client. The promote and metrics commands are deferred to a separate effort. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #5339 Migrate snapcraft_legacy store assertion commands | snapcraft | closed | Rejected because each command requires separate tracking. The list-validation-sets command was migrated via PR 6050. Remaining commands need individual tasks. | |
| #5982 Trim down snapcraft_legacy and plan migration effort | snapcraft | closed | Closed by author mr-cal. Abandoned in favor of a revised migration strategy: moving store commands out of snapcraft_legacy first, then deleting the module entirely. A Jira ticket was created for tracking. | |
| #4194 Migrate snapcraft_legacy subcommands to use craft-cli | snapcraft | closed | Abandoned. The maintainer rejected the proposed approach, confirming the legacy CLI handler will remain in use short-term while commands are fully migrated out of snapcraft_legacy in the medium term. | |
| #6218 refactor: migrate promote command | snapcraft | merged | Migrated the promote command from snapcraft_legacy to the main codebase as a near-verbatim port to preserve complex legacy behaviors. Approved by two reviewers and merged after passing most CI checks, despite one store integration test failure. | |
| #1560158 Migrate old Snapcraft state tracking to new | snapcraft (launchpad) | closed | Closed without resolution or comments. The legacy state tracking migration request appears abandoned or superseded by subsequent Snapcraft updates. No fix or merge was recorded. |