Skip to content

Work around for wasm_bindgen::JsError lacking no_std support#1079

Open
burdges wants to merge 1 commit intoarkworks-rs:masterfrom
burdges:wasm-serialize
Open

Work around for wasm_bindgen::JsError lacking no_std support#1079
burdges wants to merge 1 commit intoarkworks-rs:masterfrom
burdges:wasm-serialize

Conversation

@burdges
Copy link
Contributor

@burdges burdges commented Mar 7, 2026

I think wasm_bindgen should fix this error, and if they did then this PR would break, so I'm not sure this PR should be merged, but this PR provides a work around for now, which can be patched in, so maybe worth having in a branch here.

wasm-bindgen/wasm-bindgen#5025


Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.

  • Targeted PR against correct branch (master)
  • Linked to GitHub issue with discussion and accepted design OR have an explanation in the PR that describes this work.
  • Wrote unit tests
  • Updated relevant documentation in the code
  • Added a relevant changelog entry to the Pending section in CHANGELOG.md
  • Re-reviewed Files changed in the GitHub PR explorer

I think wasm_bindgen should fix this error, but this provides a work
around for now, which can be patched in.
wasm-bindgen/wasm-bindgen#5025
@burdges burdges requested review from a team as code owners March 7, 2026 03:15
@burdges burdges requested review from Pratyush, mmagician and z-tech and removed request for a team March 7, 2026 03:15
@burdges
Copy link
Contributor Author

burdges commented Mar 7, 2026

Alright wasm-bindgen/wasm-bindgen#5029 seems like the right fix here, and wasm-bindgen updates often, so unless its devs care lots about older rustc version then I guess this PR should end up being closed.

@z-tech
Copy link
Contributor

z-tech commented Mar 8, 2026

Let me know if I can help thanks @burdges

@burdges
Copy link
Contributor Author

burdges commented Mar 8, 2026

I think this serves primarily as a cargo patch target, but even there my PR to wasm-bindgen makes a better cargo patch target. We could close this now or just leave it open until wasm-bindgen advanced their MSRV enough to merge my patch or similar, not because merging it makes sense but because this might increase visibility for people who want to return JsErrors.

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.

2 participants