Skip to content

Commit 54f0f30

Browse files
committed
sdk: fix breaking change in getrandom wasm build
1 parent 729fded commit 54f0f30

File tree

5 files changed

+7
-1
lines changed

5 files changed

+7
-1
lines changed

Cargo.lock

+3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+1
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,7 @@ flate2 = "1.0"
157157
flume = "0.11"
158158
fs_extra = "1.2"
159159
futures = "0.3"
160+
getrandom = "0.3"
160161
git2 = { version = "0.20", default-features = false }
161162
hyper = { version = "1.6", features = ["full"] }
162163
ibc = { version = "0.57.0", features = ["serde"] }

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ check-crates:
119119
cargo +$(nightly) check -Z unstable-options --tests $(all-crates) && \
120120
make -C $(wasms) check && \
121121
make -C $(wasms_for_tests) check && \
122-
cargo check --package namada_sdk --target wasm32-unknown-unknown --no-default-features && \
122+
RUSTFLAGS='--cfg getrandom_backend="wasm_js"' cargo check --package namada_sdk --target wasm32-unknown-unknown --no-default-features && \
123123
cargo check --package namada_sdk --all-features
124124

125125
clippy-wasm = $(cargo) +$(nightly) clippy --manifest-path $(wasm)/Cargo.toml --all-targets -- -D warnings

crates/sdk/Cargo.toml

+1
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@ tokio = { workspace = true, features = ["full"] }
145145

146146
[target.'cfg(target_family = "wasm")'.dependencies]
147147
tokio = { workspace = true, default-features = false, features = ["sync"] }
148+
getrandom = { workspace = true, features = ["wasm_js"] }
148149

149150
[dev-dependencies]
150151
namada_account = { path = "../account", features = ["testing"] }

wasm/Cargo.lock

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)