Skip to content

Commit 3f183c8

Browse files
Always build external example/contract repos with latest stable Rust
The test-with-soroban-examples and test-with-openzeppelin-stellar-contracts workflows installed Rust with a bare `rustup update` and no toolchain override, so a rust-toolchain.toml pin (in this repo or the external repo) could take effect. With the MSRV now at 1.93, an older pinned toolchain makes cargo's MSRV-aware resolver pick an older soroban-sdk for transitive deps (e.g. soroban-poseidon) than the path-patched local 26.0.1, compiling two copies of soroban-sdk and failing with duplicate lang item (panic_impl) errors. Force RUSTUP_TOOLCHAIN=stable so these builds always use the latest stable Rust regardless of any pin. https://claude.ai/code/session_015kBhoioxYh6bD9o6eb9Ksh
1 parent 53afdac commit 3f183c8

2 files changed

Lines changed: 16 additions & 0 deletions

File tree

.github/workflows/test-with-openzeppelin-stellar-contracts.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,14 @@ concurrency:
1414
# repository does not gain access to anything in this repo.
1515
permissions: {}
1616

17+
# Always build with the latest stable Rust, overriding any rust-toolchain.toml
18+
# pinned by this repo or the external contracts repo. A pinned/older toolchain
19+
# makes cargo's MSRV-aware resolver select an older soroban-sdk for transitive
20+
# dependencies (e.g. soroban-poseidon) than the path-patched local one, which
21+
# compiles two copies of soroban-sdk and fails with duplicate lang item errors.
22+
env:
23+
RUSTUP_TOOLCHAIN: stable
24+
1725
jobs:
1826
collect-crates:
1927
runs-on: ubuntu-latest

.github/workflows/test-with-soroban-examples.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,14 @@ concurrency:
1414
# repository does not gain access to anything in this repo.
1515
permissions: {}
1616

17+
# Always build with the latest stable Rust, overriding any rust-toolchain.toml
18+
# pinned by this repo or the external examples repo. A pinned/older toolchain
19+
# makes cargo's MSRV-aware resolver select an older soroban-sdk for transitive
20+
# dependencies (e.g. soroban-poseidon) than the path-patched local one, which
21+
# compiles two copies of soroban-sdk and fails with duplicate lang item errors.
22+
env:
23+
RUSTUP_TOOLCHAIN: stable
24+
1725
jobs:
1826
collect-examples:
1927
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)