axodotdev / axodotdev/cargo-dist

Unable to parse the version number in a multi-package workspace if a package includes a `v`

Open
#926 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
2.1k
Forks
149
Avg merge
1d 11h
Merged PRs (30d)
32

Description

I've got [a project](https://github.com/Michael-F-Bryan/wit-lsp) with multiple different components, `wit-language-server`, `tree-sitter-wit`, `wit-compiler`, and `vscode-plugin`. When I'm ready to cut a release, I'll merge a Release PR (in this case, https://github.com/Michael-F-Bryan/wit-lsp/pull/2) and [Release Please](https://github.com/googleapis/release-please) will automatically update the changelog, create tags, and create a GitHub Release for each component being released.

From there, I'm using `cargo-dist` to make a nice bundle and installer for the `wit-language-server` binary.

The "plan" step for my Release workflow just failed ([build logs](https://github.com/Michael-F-Bryan/wit-lsp/actions/runs/8647272333/job/23708354557)) with the following:

```
× Couldn't parse the version from the provided announcement tag (vscode-plugin-v1.1.0)
╰─▶ unexpected character 's' while parsing major version number
```

I assume this is just an issue where we do `tag.split_once('v')` to extract the version number when we should actually be using `tag.rsplit_once()`.

Contributor guide

Open the contributing guide

Research direction

Start by tracing the version-parsing path used during the workflow's "plan" step and reproduce it with the announcement tag `vscode-plugin-v1.1.0`. Done means the multi-package tag is accepted and its version is parsed correctly without breaking other announcement tags.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
build-system, release
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.