Skip to content

Commit 955a971

Browse files
Upgrade Subxt and Forge (#1553)
* upgrade * update subxt signer * add back logs * revert log
1 parent 6d4062f commit 955a971

File tree

5 files changed

+43
-29
lines changed

5 files changed

+43
-29
lines changed

flake.lock

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

smoketest/Cargo.lock

Lines changed: 18 additions & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

smoketest/Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@ scale-info = { features = ["derive"], version = "2.11.6", default-features = fal
1313
hex = "0.4.3"
1414
hex-literal = "0.4.1"
1515
serde = { version = "1.0.210", features = ["derive"] }
16-
subxt = { version = "0.42.1" }
17-
subxt-signer = { version = "0.42.1" }
16+
subxt = { version = "0.43.0" }
17+
subxt-signer = { version = "0.43.0" }
1818
alloy = { version = "1.0.9", features = ["full"] }
1919
lazy_static = "1.4.0"
2020
sp-core = { version = "36.1.0" }
2121
sp-crypto-hashing = { version = "0.1.0" }
2222
sp-runtime = { version = "41.1.0" }
2323

2424
[features]
25-
legacy-v1 = []
25+
legacy-v1 = []

smoketest/make-bindings.sh

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ forge bind --module --overwrite \
1919
# Install subxt
2020
command -v subxt || cargo install subxt-cli \
2121
--git https://github.com/paritytech/subxt.git \
22-
--tag v0.42.1
22+
--tag v0.43.0
2323

2424
eth_network="${ETH_NETWORK:-localhost}"
2525
polkadot_network="${POLKADOT_NETWORK:-localhost}"
@@ -36,13 +36,27 @@ else
3636
exit 1
3737
fi
3838
# Fetch metadata from BridgeHub and generate client
39-
subxt codegen --url ws://localhost:11144 >src/parachains/bridgehub.rs
39+
subxt codegen --url ws://localhost:11144 >src/parachains/bridgehub.rs \
40+
--derive ::subxt::ext::subxt_core::ext::codec::Encode \
41+
--derive ::subxt::ext::subxt_core::ext::codec::Decode
4042
subxt codegen --url ws://localhost:12144 > src/parachains/assethub.rs \
4143
--derive-for-type staging_xcm::v5::location::Location=Clone,recursive \
44+
--derive-for-type staging_xcm::v5::location::Location=::subxt::ext::codec::Encode,recursive \
45+
--derive-for-type staging_xcm::v5::location::Location=::subxt::ext::codec::Decode,recursive \
46+
--derive-for-type xcm::VersionedXcm=::subxt::ext::codec::Encode,recursive \
47+
--derive-for-type xcm::VersionedXcm=::subxt::ext::codec::Decode,recursive \
4248
--derive-for-type staging_xcm::v5::asset::AssetId=Clone,recursive \
4349
--derive-for-type staging_xcm::v5::asset::Assets=Clone,recursive
44-
subxt codegen --url ws://localhost:9944 >src/parachains/relaychain.rs
45-
subxt codegen --url ws://localhost:13144 >src/parachains/penpal.rs
50+
subxt codegen --url ws://localhost:9944 >src/parachains/relaychain.rs \
51+
--derive ::subxt::ext::subxt_core::ext::codec::Encode \
52+
--derive ::subxt::ext::subxt_core::ext::codec::Decode
53+
subxt codegen --url ws://localhost:13144 >src/parachains/penpal.rs \
54+
--derive-for-type staging_xcm::v5::location::Location=Clone,recursive \
55+
--derive-for-type staging_xcm::v5::asset::AssetId=Clone,recursive \
56+
--derive-for-type staging_xcm::v5::asset::Assets=Clone,recursive \
57+
--derive ::subxt::ext::subxt_core::ext::codec::Encode \
58+
--derive ::subxt::ext::subxt_core::ext::codec::Decode
59+
4660
fi
4761

4862

smoketest/src/penpal_helper.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ pub async fn ensure_penpal_asset_exists(
233233
penpal_client: &mut OnlineClient<PenpalConfig>,
234234
asset: PenpalLocation,
235235
) {
236-
let existing_asset = penpal::api::storage().foreign_assets().asset(&asset);
236+
let existing_asset = penpal::api::storage().foreign_assets().asset(asset.clone());
237237
let result = penpal_client
238238
.storage()
239239
.at_latest()

0 commit comments

Comments
 (0)