workaround rust-nix* test failures due to 4-part kernel version issue#16461
Merged
christopherco merged 4 commits intotomls/base/mainfrom Apr 4, 2026
Merged
workaround rust-nix* test failures due to 4-part kernel version issue#16461christopherco merged 4 commits intotomls/base/mainfrom
christopherco merged 4 commits intotomls/base/mainfrom
Conversation
Azure Linux 3.0 kernels, used on our current Koji builders, have 4-part version strings (e.g. 6.6.121.1-1.azl3) which the semver crate's Version::parse() rejects. Three tests (gro, gso, test_txtime) panic on unwrap of the parse error. Apply the same fix-4part-kernel-version.patch already used by rust-nix: truncate to 3 numeric components before parsing so the extra part becomes a pre-release suffix (which is cleared immediately after).
Azure Linux 3.0 kernels, used on our current Koji builders, have 4-part version strings (e.g. 6.6.121.1-1.azl3) which the semver crate's Version::parse() rejects. Three tests (gro, gso, test_txtime) panic on unwrap of the parse error. Apply the same fix-4part-kernel-version.patch already used by rust-nix: truncate to 3 numeric components before parsing so the extra part becomes a pre-release suffix (which is cleared immediately after).
Azure Linux 3.0 kernels, used on our current Koji builders, have 4-part version strings (e.g. 6.6.121.1-1.azl3) which the semver crate's Version::parse() rejects. Three tests (gro, gso, test_txtime) panic on unwrap of the parse error. Apply the same fix-4part-kernel-version.patch already used by rust-nix: truncate to 3 numeric components before parsing so the extra part becomes a pre-release suffix (which is cleared immediately after).
Azure Linux 3.0 kernels, used on our current Koji builders, have 4-part version strings (e.g. 6.6.121.1-1.azl3) which the semver crate's Version::parse() rejects. Two tests (gro, gso) panic on unwrap of the parse error. Apply the same fix-4part-kernel-version.patch already used by rust-nix: truncate to 3 numeric components before parsing so the extra part becomes a pre-release suffix (which is cleared immediately after).
Contributor
There was a problem hiding this comment.
Pull request overview
Adds Azure Linux–specific overlays to multiple rust-nix* component variants to prevent %check panics on Koji builders running AZL3 kernels that report a 4-part uname -r version string (rejected by semver::Version::parse()), aligning these variants with the already-established workaround used elsewhere in the repo.
Changes:
- Add per-component overlays for
rust-nix0.23,rust-nix0.28,rust-nix0.29, andrust-nix0.30to ship and registerfix-4part-kernel-version.patch. - Introduce the patch in each component directory to rewrite the kernel version string into semver-parseable form for the affected tests.
- Remove these components’ bare entries from
components-full.tomlnow that they have dedicated*.comp.tomldefinitions.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| base/comps/rust-nix0.30/rust-nix0.30.comp.toml | Adds overlays to include/register the kernel-version parsing workaround patch. |
| base/comps/rust-nix0.30/fix-4part-kernel-version.patch | Implements semver-compatible handling for 4-part uname -r strings in test helper code. |
| base/comps/rust-nix0.29/rust-nix0.29.comp.toml | Same overlay approach for the 0.29 variant. |
| base/comps/rust-nix0.29/fix-4part-kernel-version.patch | Same patch content for the 0.29 variant. |
| base/comps/rust-nix0.28/rust-nix0.28.comp.toml | Same overlay approach for the 0.28 variant. |
| base/comps/rust-nix0.28/fix-4part-kernel-version.patch | Same patch content for the 0.28 variant. |
| base/comps/rust-nix0.23/rust-nix0.23.comp.toml | Same overlay approach for the 0.23 variant. |
| base/comps/rust-nix0.23/fix-4part-kernel-version.patch | Same patch content for the 0.23 variant. |
| base/comps/components-full.toml | Removes entries for components that now have dedicated *.comp.toml files. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Contributor
|
Looks good to me. We probably will ever know why they did not use a regular expression. |
binujp
approved these changes
Apr 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Azure Linux 3.0 kernels, used on our current Koji builders, have 4-part
version strings (e.g. 6.6.121.1-1.azl3) which the semver crate's
Version::parse() rejects. Two tests (gro, gso) panic on unwrap of the
parse error.
Apply the same fix-4part-kernel-version.patch already used by rust-nix:
truncate to 3 numeric components before parsing so the extra part
becomes a pre-release suffix (which is cleared immediately after).
Apply to rust-nix0.23, rust-nix0.28, rust-nix0.29, rust-nix0.30.
This workaround can be undone when the Koji builders move to a
kernel with 3-part version strings, although the current logic will still
continue to function as intended with a standard 3-part kernel version
string.