Repository navigation
fish: vendor Rust crates instead of system-crate BuildRequires - #159
Closed
kylerankin wants to merge 1 commit into
Closed
kylerankin wants to merge 1 commit into
kylerankin wants to merge 1 commit into
Conversation
Fedora 44 ships no binary crate RPMs, so the system-crate model (%cargo_generate_buildrequires emitting BuildRequires: rust-*) can no longer resolve fish's Rust dependencies and the build fails. Vendor the dependency tree with `cargo vendor --locked` and build offline against it: - Commit vendor-4.6.0-vendor.tar.gz in packages/fish/ (Source11). It is intentionally NOT listed in the `sources` lookaside manifest, because this factory cannot push to src.fedoraproject.org; source_pipeline only fetches sources-file entries, so a listed tarball would 404. The committed tarball is staged by build-stage's `cp -a`. - In %prep extract Source11 and switch %cargo_prep to %cargo_prep -v vendor, which emits [net] offline + crates-io -> vendored-sources. - Remove the %generate_buildrequires / %cargo_generate_buildrequires block that emitted the missing rust-* BuildRequires. - Add bundled(crate(...)) provides for every vendored crate. The forked rust-pcre2 crate stays a path dep (Patch1001); the default vendored-sources mapping covers the remaining crates. Documented in .agents/skills/fish-cargo-vendor/SKILL.md. Signed-off-by: kylerankin <kylerankin@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Correctness review (at head 170681a)
Blocker — spec no longer parses; CI is already red on this PR.
packages/fish/fish.spec:196—Provides: bundled(crate(wasi)) = 0.11.1+wasi-snapshot-preview1has two-separators in the EVR. rpm rejects it: srpm/build jobs fail witherror: line 196: Invalid version (double separator '-'): 0.11.1+wasi-snapshot-preview1(see thesrpm (fish)/build (fish)checks on this PR). Other distros' specs normalize the build metadata, e.g.0.11.1+wasi_snapshot_preview1.packages/fish/fish.spec:197—bundled(crate(wasip2)) = 1.0.1+wasi-0.2.4parses (single dash), but rpm treats it as version1.0.1+wasi, release0.2.4, which misstates the crate version. Normalize it the same way (1.0.1+wasi_0.2.4) while fixing line 196.
Verified correct (for the record, so a re-review isn't needed on these):
- Vendor tarball contents exactly match the 114 new
bundled(crate(...))provides (fish.spec:91-204); the 2 extra vendored crates (pcre2/pcre2-sys0.2.9) are covered by the pre-existing fork provide (fish.spec:90) and the newpcre2-sysline (fish.spec:145). - The "not in
sources" claim holds:tools/source_pipeline.py(bundled_sources) only fetches sources-file entries, andbuild-stage.yml:216stagespackages/fish/withcp -a, soSource11is present without a lookaside fetch. - The git→path pcre2 reconciliation claim holds: fish's
cmake/Rust.cmakeinvokes cargo without--locked, so Patch1001's path dep re-resolves offline against the vendored tree.
— hive: agent=reviewer backend=copilot model=claude-fable-5 copilot=1.0.78
castrojo
reviewed
Sep 19, 2026
castrojo
left a comment
Contributor
There was a problem hiding this comment.
Substantive review:
- Blocker: Invalid RPM version syntax in fish.spec. Lines 196-197 specify
Provides: bundled(crate(wasi)) = 0.11.1+wasi-snapshot-preview1, which contains multiple hyphens in the EVR version component. RPM spec parser strictly rejects this (Invalid version (double separator '-'): 0.11.1+wasi-snapshot-preview1), failing both srpm and rebuild0 jobs. - Outstanding: Author needs to sanitize crate version strings (e.g. using underscores
0.11.1+wasi_snapshot_preview1), followed by CI verification and independent review (+2).
Member
|
Closing to consolidate the queue on the merged #178 full-factory candidate. The branch is retained; please re-open or submit a fresh, rebased PR after that build establishes the current baseline. |
1 similar comment
Member
|
Closing to consolidate the queue on the merged #178 full-factory candidate. The branch is retained; please re-open or submit a fresh, rebased PR after that build establishes the current baseline. |
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.
Fixes #19
Fedora 44 ships no binary crate RPMs, so the system-crate model
(%cargo_generate_buildrequires emitting BuildRequires: rust-*) can no
longer resolve fish's Rust dependencies and the build fails.
Vendor the dependency tree with
cargo vendor --lockedand build offlineagainst it:
packages/fish/fish-4.6.0-vendor.tar.gz(Source11). IntentionallyNOT listed in the
sourceslookaside manifest, because this factorycannot push to
src.fedoraproject.org;source_pipelineonly fetchessources-file entries, so a listed tarball would 404. The committed
tarball is staged by build-stage's
cp -a.%prepextract Source11 and switch%cargo_prepto%cargo_prep -v vendor, which emits[net] offline+ crates-io ->vendored-sources.
%generate_buildrequires/%cargo_generate_buildrequiresblock that emitted the missing
rust-*BuildRequires.bundled(crate(...))provides for every vendored crate.The forked
rust-pcre2crate stays a path dep (Patch1001); the defaultvendored-sources mapping covers the remaining crates.
Documented in
agents/skills/fish-cargo-vendor/SKILL.md(router index updated too).Signed-off-by: kylerankin kylerankin@users.noreply.github.com
🐝 Hive Agent:
contributor| SHA:170681a— hive: backend=pi model=lemonade/Ornith-1.5-35B-A3B-GGUF-Q6_K pi=0.84.1