Skip to content

docs: add troubleshooting entry for wasm32-unknown-unknown build error on Rust 1.82+ #2482

Closed as not planned

Description

@leighmcculloch

Background

rs-soroban-sdk#1900 formally documented that the SDK rejects wasm32-unknown-unknown builds on Rust 1.82+ via a build-script error, because that target enables WebAssembly features (reference-types, multi-value) the Soroban runtime does not support.

A follow-up PR (stellar-docs#PR) added warnings to setup.mdx and rust-dialect.mdx. However, there are additional documentation gaps that warrant their own issues.

Missing / incomplete documentation

1. Dedicated troubleshooting page entry

There is no troubleshooting guide that covers the specific build error message a developer sees when they try to build with wasm32-unknown-unknown on Rust 1.82+. A developer who hits this error mid-project and searches for the error text will find nothing in the Stellar docs.

Suggested addition: a troubleshooting entry (either in a new docs/build/smart-contracts/getting-started/troubleshooting.mdx or an existing errors page) that:

  • Shows the exact build error message from soroban-sdk's build script
  • Explains the root cause
  • Gives the fix: upgrade to Rust 1.84+, rustup target add wasm32v1-none, use stellar contract build

2. Migration guide for teams upgrading Rust toolchain

Teams upgrading from Rust <1.82 to ≥1.82 need to know to switch targets. There is currently no migration guide that covers:

  • When wasm32-unknown-unknown broke for Soroban (Rust 1.82)
  • The minimum Rust version for wasm32v1-none (Rust 1.84)
  • Steps to update CI pipelines (e.g. rust-toolchain.toml, GitHub Actions workflows)

3. stellar contract build vs cargo build — explicit guidance

The docs show cargo build --target wasm32v1-none --release as an equivalent to stellar contract build, but do not explicitly say "do not use cargo build directly". The SDK PR wording says "Do not build contracts with cargo build" and this phrasing is absent from the docs. Consider adding it as a note in hello-world.mdx where the equivalence is currently shown.

4. i18n pages not updated

The translated (es) versions of setup.mdx and hello-world.mdx under i18n/ still refer to older patterns and have not received the wasm32v1-none guidance in the same level of detail. These will drift further if left unaddressed.

References

  • rs-soroban-sdk#1900 — SDK PR that introduced the documentation
  • rs-soroban-sdk#1843 — Scout team issue that triggered the change
  • rs-soroban-sdk#1844 — Related issue with community discussion

Activity

  1. added
    documentation
    on Jun 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentation

    Type

    No type

    Projects

    • Status
      No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions