Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

spdx=0.4.1 dependency increases MSRV to 1.52 #415

Closed

Conversation

EndilWayfare
Copy link

@EndilWayfare EndilWayfare commented Jun 25, 2021

Running cargo install pyoxidizer with Rust 1.50.0 on Windows 10 failed, complaining about use of unstable feature str_split_once.

The usage occurs in spdx::lexer::find_document_and_license_ref. The change was introduced in [email protected] as part of removing dependence on regex/lazy_static. That's awesome for compilation-speed/binary-size, but now all depending crates transitively depend on Rust >=1.52, the version which stabilized str::split_once. This isn't a big deal for me personally, because I don't have a reason to use an older toolchain (I just hadn't upgraded for a bit). But, since this project's MSRV is 1.46, I thought this might become an issue for someone else.

python-packaging, tugger-licensing, and tugger-licensing-net all depend on spdx = "0.4". Cloning the repo and building from source succeeds; the Cargo.lock pins spdx=0.4.0. However, cargo install --path pyoxidizer fails just like cargo install pyoxidizer. Apparently, cargo install doesn't respect Cargo.lock unless you use --locked.

Constraining spdx = "= 0.4.0" fixes this, at the cost of shackling users with Rust >=1.52 to the old implementation. On the other hand, that may be desirable for consistency between MSRV up to current version.

Alternatively, the documentation could add a suggestion to use cargo install --locked for older toolchains.

MSRV of "0.4.1" is 1.52
`cargo install` fails for >1.52 even though `cargo build` succeeds
@EndilWayfare
Copy link
Author

Ok, I just found out that pyoxidizer enforces Rust 1.52.1 as the minimum rust version for use with the cli.

I only thought of the MSRV because I had seen #324, being curious as to the relationship of this project with pyo3. There, it was specified as 1.46, and I found 1.46 associated with the most recent usage of "minimum" searching in Project History. I see now that 1.52.1 is mentioned much more recently in the context of "Manged Rust toolchain".

I think this PR is entirely useless, then. 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant