Skip to content

Prefer MSRV-compatible deps in the ubrn build - #1797

Merged
spacebear21 merged 1 commit into
payjoin:masterfrom
spacebear21:pin-globset-msrv
Aug 5, 2026
Merged

Prefer MSRV-compatible deps in the ubrn build#1797
spacebear21 merged 1 commit into
payjoin:masterfrom
spacebear21:pin-globset-msrv

Conversation

@spacebear21

Copy link
Copy Markdown
Collaborator

Fixes the javascript CI job, which has been broken since 2026-08-04 on every
PR that touches payjoin-ffi/**.

ubrn is compiled from source during binding generation, out of a workspace
that ships no lock file, so cargo resolves it fresh on every run and takes the
newest semver-compatible release of each crate. globset 0.4.20 raised its
MSRV to 1.88, so that resolution now yields a crate the javascript dev shell's
pinned 1.85.0 toolchain refuses to build:

error: rustc 1.85.0 is not supported by the following package:
  globset@0.4.20 requires rustc 1.88

Rather than extend the existing cargo add pin list with a second entry, this
sets CARGO_RESOLVER_INCOMPATIBLE_RUST_VERSIONS=fallback and drops the list
entirely. Cargo's MSRV-aware resolver prefers versions compatible with the
rustc in use, and derives globset 0.4.19 and home 0.5.11 on its own, the
same two versions the manual pins named. Future MSRV drift resolves the same
way with no further edits.

It also stops the build mutating node_modules. cargo add was writing pins
into node_modules/uniffi-bindgen-react-native/crates/ubrn_cli/Cargo.toml;
that manifest now stays pristine.

Verified locally on macOS with nix develop .#javascript -c ./payjoin-ffi/javascript/contrib/test.sh against a clean npm ci: 31 tests
pass, and the generated lock records globset 0.4.19 / home 0.5.11.

Pull Request Checklist

Please confirm the following before requesting review:

Disclosure: co-authored by Claude Opus 5

The uniffi-bindgen-react-native command is compiled from source during
binding generation, from a workspace that ships no lock file, so cargo
resolves its dependency graph fresh on every run and takes the newest
semver-compatible release of each crate. When one of those raises its
MSRV past the javascript dev shell's pinned toolchain, the build breaks:

    error: rustc 1.85.0 is not supported by the following package:
      globset@0.4.20 requires rustc 1.88

globset 0.4.20, published 2026-08-04, did exactly that. The existing
workaround pinned each offending crate by hand with cargo add, a list
that only grows as dependencies drift, and wrote those pins into
node_modules as a side effect.

Set CARGO_RESOLVER_INCOMPATIBLE_RUST_VERSIONS=fallback instead. Cargo's
MSRV-aware resolver then prefers versions compatible with the rustc in
use, deriving globset 0.4.19 and home 0.5.11 on its own, the same
versions the manual pins named.

This only breaks CI on pull requests that touch payjoin-ffi/**, the
workflow's path filter, which is why master looks green.
@coveralls

Copy link
Copy Markdown
Collaborator

Coverage Report for CI Build 31029745925

Coverage remained the same at 86.685%

Details

  • Coverage remained the same as the base build.
  • Patch coverage: No coverable lines changed in this PR.
  • No coverage regressions found.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

No coverage regressions found.


Coverage Stats

Coverage Status
Relevant Lines: 16418
Covered Lines: 14232
Line Coverage: 86.69%
Coverage Strength: 344.28 hits per line

💛 - Coveralls

@benalleng benalleng left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 834dd1b

Builds cleanly, nice

@spacebear21
spacebear21 merged commit 401966c into payjoin:master Aug 5, 2026
29 checks passed
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.

3 participants