cli: accept snap file in legacy upload-metadata command
Metadata
Current evaluation
PR #3975 was merged as commit d685a2314, adding a snap-file path argument to legacy upload-metadata and related documentation/environment fixes.
Resolution: closed resolved
Reason: The approved PR was merged into main as commit d685a2314, resolving the legacy upload-metadata command's unrecognized snap-file argument error.
Evaluated by: mr-cal-bot
No scores available.
Issue body
- [x] Have you followed the [guidelines for contributing](https://github.com/snapcore/snapcraft/blob/master/CONTRIBUTING.md)?
- [x] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)?
- [x] Have you successfully run `make lint`?
- [x] Have you successfully run `pytest tests/unit`?
-----
fxes: https://bugs.launchpad.net/snapcraft/+bug/1995857
The legacy upload-metadata command didn't have a location argument for the snap file itself. This PR adds that argument, and fixes some issues with the hacking doc and environment setup.
```shell
$snapcraft upload-metadata signal-desktop_5.57.0_amd64-core18.snap
Usage: snapcraft [options] command [args]...
Try 'snapcraft upload-metadata -h' for help.
Error: unrecognized arguments: signal-desktop_5.57.0_amd64-core18.snap
```
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed resolved | PR #3975 was merged as commit d685a2314, adding a snap-file path argument to legacy upload-metadata and related documentation/environment fixes. | |
| stealth/space-bunny-alpha | — | closed resolved | Merged in snapcraft#3975 as commit d685a2314, adding a snap-file argument to legacy upload-metadata so it accepts .snap paths. | |
| stealth/space-bunny-alpha | — | closed resolved | Merged into main in PR #3975: legacy upload-metadata now accepts a snap file path, fixing the unrecognized-arguments error. | |
| qwen/qwen3.6-35b-a3b | — | — | Merged into main. Adds a missing snap file path argument to the legacy upload-metadata CLI command, resolving a usage error. Approved by one reviewer, passed CI checks, and integrated with minor adjustments. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Merged PR adding a snap file path argument to the legacy snapcraft upload-metadata CLI command, resolving bug #1995857. The update enables direct file uploads and corrects documentation, despite a minor coverage decrease noted during review. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #1995857 upload-metadata not working | snapcraft (launchpad) | open | Legacy `snapcraft upload-metadata` rejected the positional snap-file argument, unlike `push-metadata`. Fixed by merged PR #3975 (commit d685a2314); current command accepts snap_file and is unit tested. | |
| #413 add the option to upload an existing snap | snapcraft | merged | Merged via commit d027fcd65, adding explicit upload of an existing .snap; SNAP_FILE became mandatory and the legacy lifecycle upload path was removed. |