- Sep 04, 2024
-
-
Liu-Cheng Xu authored
There are basically three commits in this PR. Since all these commits essentially have no logical changes, I packed them into one PR. Review by per-commit is recommended. - The first commit avoids unnecessarily updating the block gap storage when the value remains unchanged, as discovered when I worked on https://github.com/paritytech/polkadot-sdk/issues/5406. - The second commit is purely about format string style changes but deletes ~10 lines of code, which slightly helps me look into this file :P - The third commit is added to avoid the unnecessary block gap update in `BlockchainDb`. --------- Co-authored-by: Davide Galassi <[email protected]>
-
bader y authored
When using with `polkadot-parachain`, you usually need to specify the `relay_chain` and `para_id` fields in the chain spec. With this PR it can be achieved by specifying newly added `--para-id` and `--relay-chain` command line args, e.g: ``` chain-spec-builder create -r _runtime.wasm --para-id 100 --relay-chain xxx default ``` This was implemented by simple _json_ blobs merging. Additionally unit tests covering basic functionality were added. Also adds a fix for not overwriting the chain spec with the default config each time, swallowing not standard fields is also fixed. Fixes: #4873 --------- Co-authored-by: Sebastian Kunert <[email protected]> Co-authored-by: Michal Kucharczyk <[email protected]>
-
- Sep 03, 2024
-
-
Iulian Barbu authored
# Description Adds retry logic that makes the RPC relay chain interface more reliable for the cases of a collator connecting to external RPC servers. Closes #5514 Closes #4278 Final solution still debated on #5514 , what this PR addresses might change (e.g. #4278 might require a more advanced approach). ## Integration Users that start collators should barely observe differences based on this logic, since the retry logic applies only in case the collators fail to connect to the RPC servers. In practice I assume the RPC servers are already live before starting collators, and the issue isn't visible. ## Review Notes The added retry logic is for retrying the connection to the RPC servers (which can be multiple). It is at the level of the cumulus/client/relay-chain-rpc-interface module, but more specifically relevant to the RPC clients logic (`ClientManager`). The retry logic is not configurable, it tries to connect to the RPC client for 5 times, with an exponential backoff in between each iteration starting with 1 second wait time and ending with 16 seconds. The same logic is applied in case an existing connection to an RPC is dropped. There is a `ReconnectingWebsocketWorker` who ensures there is connectivity to at least on RPC node, and the retry logic makes this stronger by insisting on trying connections to the RPC servers list for 5 times. ## Testing - This was tested manually by starting zombienet natively based on [006-rpc_collator_builds_blocks.toml](https://github.com/paritytech/polkadot-sdk/blob/master/cumulus/zombienet/tests/0006-rpc_collator_builds_blocks.toml) and observing collators don't fail anymore: ```bash zombienet -l text --dir zbn-run -f --provider native spawn polkadot-sdk/cumulus/zombienet/tests/0006-rpc_collator_builds_blocks.toml ``` - Added a unit test that exercises the retry logic for a client connection to a server that comes online in 10 seconds. The retry logic can wait for as long as 30 seconds, but thought that it is too much for a unit test. Just being conscious of CI time if it runs this test, but I am happy to see suggestions around it too. I am not that sure either it runs in CI, haven't figured it out entirely yet. The test can be considered an integration test too, but it exercises crate internal implementation, not the public API. Collators example logs after the change: ``` 2024-08-29 14:28:11.730 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=0 index=2 url="ws://127.0.0.1:37427/" 2024-08-29 14:28:12.737 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=1 index=0 url="ws://127.0.0.1:43617/" 2024-08-29 14:28:12.739 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=1 index=1 url="ws://127.0.0.1:37965/" 2024-08-29 14:28:12.755 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=1 index=2 url="ws://127.0.0.1:37427/" 2024-08-29 14:28:14.758 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=2 index=0 url="ws://127.0.0.1:43617/" 2024-08-29 14:28:14.759 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=2 index=1 url="ws://127.0.0.1:37965/" 2024-08-29 14:28:14.760 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=2 index=2 url="ws://127.0.0.1:37427/" 2024-08-29 14:28:18.766 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=3 index=0 url="ws://127.0.0.1:43617/" 2024-08-29 14:28:18.768 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=3 index=1 url="ws://127.0.0.1:37965/" 2024-08-29 14:28:18.768 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=3 index=2 url="ws://127.0.0.1:37427/" 2024-08-29 14:28:26.770 INFO tokio-runtime-worker reconnecting-websocket-client: [Parachain] Trying to connect to next external relaychain node. current_iteration=4 index=0 url="ws://127.0.0.1:43617/" ``` --------- Signed-off-by: Iulian Barbu <[email protected]> Co-authored-by: Sebastian Kunert <[email protected]>
-
Alexandru Vasile authored
The https://github.com/paritytech/polkadot-sdk/issues/5512 has surfaced that we reported a `BestBlock` event for a block not previously reported via `NewBlock`. This is because of a race between: - the stream of events that announces new blocks - `self.client.info().best_block` It is possible that `client.info()` contains newer information than the information polled from the block stream (that may be lagging). To mitigate this, instead of relying on the client's info use the last finalized block to emit a new event. There are two cases when a new best block event is emitted: - The best block is in the pruned list and is reported immediately - The best block is not a descendant of the last finalized block Closes: https://github.com/paritytech/polkadot-sdk/issues/5512 Thanks @jsdw and @josepot for helping debug this
🙏 cc @paritytech/subxt-team --------- Signed-off-by: Alexandru Vasile <[email protected]> Co-authored-by: Sebastian Kunert <[email protected]> Co-authored-by: command-bot <> -
Maksym H authored
Closes https://github.com/paritytech/ci_cd/issues/1017 - Enabled subsystem-benchmarks 100% + adjusted them to publish as separate job so it can use environment for scope secrets - Added -v1.* triggers for GHA checks - Removed remove subkey & polkavm from gitlab --------- Co-authored-by: Alexander Samusev <[email protected]>
-
Oliver Tale-Yazdi authored
Also make the backport bot use the new release.
-
Alexander Theißen authored
Before we only supported CREATE2 semantics for contract address derivations. In order to be compatible we also want to allow CREATE1 semantics. We accomplish this to make the salt an `Option` in all places where it is used. Supplying `None` will use CREATE1 semantics by just using the deployers account nonce. ## Todo - [x] Add new tests specific for CREATE1
-
Kian Paimani authored
Co-authored-by: Javier Viola <[email protected]> Co-authored-by: Alexandru Vasile <[email protected]> Co-authored-by: command-bot <>
-
- Sep 02, 2024
-
-
dharjeezy authored
closes https://github.com/paritytech/polkadot-sdk/issues/2441 Polkadot address: 12GyGD3QhT4i2JJpNzvMf96sxxBLWymz4RdGCxRH5Rj5agKW --------- Signed-off-by: Oliver Tale-Yazdi <[email protected]> Co-authored-by: Oliver Tale-Yazdi <[email protected]> Co-authored-by: Bastian Köcher <[email protected]>
-
Clara van Staden authored
Allow free Snowbridge consensus updates, if the header interval is larger than the configured value (set to 32, so once a epoch). This PR also moves the Rococo Snowbridge pallet config into its own module. Original PR: https://github.com/Snowfork/polkadot-sdk/pull/159 --------- Co-authored-by: Francisco Aguirre <[email protected]>
-
PG Herveou authored
Co-authored-by: Alexander Theißen <[email protected]> Co-authored-by: command-bot <>
-
Andrei Sandu authored
closes https://github.com/paritytech/polkadot-sdk/issues/5044 This PR switches the runtime to the new receipts format (vstaging primitives). I've implemented `From` to convert from new primitives to `v7` primitives and used them in the node runtime api client implementation. Until we implement the support in the node, it will continue e to use the v7 primitives but the runtime apis already use the new primitives. An expected downside of RFC103 is decoding V2 receipts shows garbage values if the input is V1: _![ima_9ce77de](https://github.com/user-attachments/assets/71d80e78-e238-4518-8cd1-548ae0d74b70)_ TODO: - [x] fix tests - [x] A few more tests for the new primitives - [x] PRDoc --------- Signed-off-by: Andrei Sandu <[email protected]>
-
Alexander Theißen authored
Created a new @paritytech/smart-contracts team that is now referenced in the review bot config and CODEOWNERS file. Also excluded the new pallet in the other review bot rules.
-
Branislav Kontur authored
Relates to: https://github.com/paritytech/parity-bridges-common/issues/2451 Closes: https://github.com/paritytech/parity-bridges-common/issues/2500 ## Summary Now, the bridging pallet supports only static lanes, which means lanes that are hard-coded in the runtime files. This PR fixes that and adds support for dynamic, also known as permissionless, lanes. This means that allowed origins (relay chain, sibling parachains) can open and close bridges (through BridgeHubs) with another bridged (substrate-like) consensus using just `xcm::Transact` and `OriginKind::Xcm`. _This PR is based on the migrated code from the Bridges V2 [branch](https://github.com/paritytech/polkadot-sdk/pull/4427) from the old `parity-bridges-common` [repo](https://github.com/paritytech/parity-bridges-common/tree/bridges-v2)._ ## Explanation Please read [bridges/modules/xcm-bridge-hub/src/lib.rs](https://github.com/paritytech/polkadot-sdk/blob/149b0ac2 /bridges/modules/xcm-bridge-hub/src/lib.rs#L17-L136) to understand how managing bridges works. The basic concepts around `BridgeId` and `LaneId` are also explained there. ## TODO - [x] search and fix for comment: `// TODO:(bridges-v2) - most of that stuff was introduced with free header execution: https://github.com/paritytech/polkadot-sdk/pull/4102` - more info in the comment [bellow](https://github.com/paritytech/polkadot-sdk/pull/4427#issuecomment-2126625043) - [x] TODO: there's only one impl of `EnsureOrigin<Success = Location>` ## TODO - not blocking review **benchmarking:** - [x] regenerate all relevant weights for BH/AH runtimes - [ ] regenerate default weights for bridging pallets e.g. `modules/messages/src/weights.rs` - [ ] add benchmarks for `xcm-bridge-hub` pallet https://github.com/paritytech/polkadot-sdk/issues/5550 **testing:** - [ ] add xcm-emulator tests for Rococo/Penpal to Westend/Penpal with full opening channel and sending/receiving `xcm::Transact` **migrations:** - [x] add migrations for BridgeHubRococo/Westend https://github.com/paritytech/parity-bridges-common/issues/2794 (to be reusable for P/K bridge) - [x] check also storage migration, if needed for pallets - [ ] migration for XCM type (optional) - [x] migration for static lanes to the dynamic (reuse for fellows) **investigation:** - [ ] revisit https://github.com/paritytech/parity-bridges-common/issues/2380 - [ ] check congestion around `LocalXcmChannelManager` and `OutboundLanesCongestedSignals` impls - https://github.com/paritytech/polkadot-sdk/issues/5551 - to be reusable for polkadot-fellows - return `report_bridge_status` was remove, so we need to `XcmpQueue` alternative? --------- Signed-off-by: Branislav Kontur <[email protected]> Co-authored-by: Svyatoslav Nikolsky <[email protected]> Co-authored-by: command-bot <> Co-authored-by: Francisco Aguirre <[email protected]>
-
dependabot[bot] authored
Bumps [toml](https://github.com/toml-rs/toml) from 0.8.8 to 0.8.12. <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/toml-rs/toml/commit/3a777b326b8c91f48c79ea6fc21aabc695f7dc3d"><code>3a777b3</code></a> chore: Release</li> <li><a href="https://github.com/toml-rs/toml/commit/79799052128f3ea64316d3acc4c54e63fc6f285c"><code>7979905</code></a> docs: Update changelog</li> <li><a href="https://github.com/toml-rs/toml/commit/487768d8d7c41b12eb7547cab4e964b3dede002b"><code>487768d</code></a> Merge pull request <a href="https://redirect.github.com/toml-rs/toml/issues/703">#703</a> from epage/overflow</li> <li><a href="https://github.com/toml-rs/toml/commit/6987f77649aacc7a6cc2b9cff0d1f22c260f9643"><code>6987f77</code></a> chore(ci): Run with default opt-level</li> <li><a href="https://github.com/toml-rs/toml/commit/21f545d05ca57560485f24cbf78aaf8478a52c5d"><code>21f545d</code></a> fix(parser): Don't stackoverflow on opt-level=0</li> <li><a href="https://github.com/toml-rs/toml/commit/af1f97dbf5a40740e26eb4f705a0bd744744807b"><code>af1f97d</code></a> refactor(parser): Pull recursion limit out to variable</li> <li><a href="https://github.com/toml-rs/toml/commit/eb865434a251b30ca1a9699b8762a1f5f4670c1c"><code>eb86543</code></a> chore: Release</li> <li><a href="https://github.com/toml-rs/toml/commit/246b2920e28919e02a94c0b3eab8e55c7742f5d0"><code>246b292</code></a> docs: Update changelog</li> <li><a href="https://github.com/toml-rs/toml/commit/d41c62ca5d09c50064905f7da04fc103d78ff566"><code>d41c62c</code></a> Merge pull request <a href="https://redirect.github.com/toml-rs/toml/issues/701">#701</a> from epage/cleanup</li> <li><a href="https://github.com/toml-rs/toml/commit/31457b3aedcddae92549b5fe19c1938d29a73a2d"><code>31457b3</code></a> refactor(error): Clean up highlight code</li> <li>Additional commits viewable in <a href="https://github.com/toml-rs/toml/compare/toml-v0.8.8...toml-v0.8.12">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=toml&package-manager=cargo&previous-version=0.8.8&new-version=0.8.12)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Bastian Köcher <[email protected]>
-
dependabot[bot] authored
Bumps [clap_complete](https://github.com/clap-rs/clap) from 4.4.0 to 4.5.13. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/clap-rs/clap/releases">clap_complete's releases</a>.</em></p> <blockquote> <h2>v4.5.13</h2> <h2>[4.5.13] - 2024-07-31</h2> <h3>Fixes</h3> <ul> <li><em>(derive)</em> Improve error message when <code>#[flatten]</code>ing an optional <code>#[group(skip)]</code></li> <li><em>(help)</em> Properly wrap long subcommand descriptions in help</li> </ul> <h2>v4.5.12</h2> <h2>[4.5.12] - 2024-07-31</h2> <h2>v4.5.10</h2> <h2>[4.5.10] - 2024-07-23</h2> <h2>v4.5.9</h2> <h2>[4.5.9] - 2024-07-09</h2> <h3>Fixes</h3> <ul> <li><em>(error)</em> When defining a custom help flag, be sure to suggest it like we do the built-in one</li> </ul> <h2>v4.5.8</h2> <h2>[4.5.8] - 2024-06-28</h2> <h3>Fixes</h3> <ul> <li>Reduce extra flushes</li> </ul> <h2>v4.5.7</h2> <h2>[4.5.7] - 2024-06-10</h2> <h3>Fixes</h3> <ul> <li>Clean up error message when too few arguments for <code>num_args</code></li> </ul> <h2>v4.5.6</h2> <h2>[4.5.6] - 2024-06-06</h2> <h2>v4.5.4</h2> <h2>[4.5.4] - 2024-03-25</h2> <h3>Fixes</h3> <ul> <li><em>(derive)</em> Allow non-literal <code>#[arg(id)]</code> attributes again</li> </ul> <h2>v4.5.3</h2> <h2>[4.5.3] - 2024-03-15</h2> <h3>Internal</h3> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/clap-rs/clap/blob/master/CHANGELOG.md">clap_complete's changelog</a>.</em></p> <blockquote> <h2>[4.5.13] - 2024-07-31</h2> <h3>Fixes</h3> <ul> <li><em>(derive)</em> Improve error message when <code>#[flatten]</code>ing an optional <code>#[group(skip)]</code></li> <li><em>(help)</em> Properly wrap long subcommand descriptions in help</li> </ul> <h2>[4.5.12] - 2024-07-31</h2> <h2>[4.5.11] - 2024-07-25</h2> <h2>[4.5.10] - 2024-07-23</h2> <h2>[4.5.9] - 2024-07-09</h2> <h3>Fixes</h3> <ul> <li><em>(error)</em> When defining a custom help flag, be sure to suggest it like we do the built-in one</li> </ul> <h2>[4.5.8] - 2024-06-28</h2> <h3>Fixes</h3> <ul> <li>Reduce extra flushes</li> </ul> <h2>[4.5.7] - 2024-06-10</h2> <h3>Fixes</h3> <ul> <li>Clean up error message when too few arguments for <code>num_args</code></li> </ul> <h2>[4.5.6] - 2024-06-06</h2> <h2>[4.5.5] - 2024-06-06</h2> <h3>Fixes</h3> <ul> <li>Allow <code>exclusive</code> to override <code>required_unless_present</code>, <code>required_unless_present_any</code>, <code>required_unless_present_all</code></li> </ul> <h2>[4.5.4] - 2024-03-25</h2> <h3>Fixes</h3> <ul> <li><em>(derive)</em> Allow non-literal <code>#[arg(id)]</code> attributes again</li> </ul> <h2>[4.5.3] - 2024-03-15</h2> <h3>Internal</h3> <ul> <li><em>(derive)</em> Update <code>heck</code></li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/clap-rs/clap/commit/d222ae4cb62d08b4d8f635aa80ddb3c880b82e6e"><code>d222ae4</code></a> chore: Release</li> <li><a href="https://github.com/clap-rs/clap/commit/a8abcb40c5f2628bfa671adf61a090a1bbfbcfa2"><code>a8abcb4</code></a> docs: Update changelog</li> <li><a href="https://github.com/clap-rs/clap/commit/2690e1bdb19df3e4dde7a50fc33b14a3bf6f0b8a"><code>2690e1b</code></a> Merge pull request <a href="https://redirect.github.com/clap-rs/clap/issues/5621">#5621</a> from shannmu/dynamic_valuehint</li> <li><a href="https://github.com/clap-rs/clap/commit/7fd7b3e40bd835070253432accf4076bb020beda"><code>7fd7b3e</code></a> feat(clap_complete): Support to complete custom value of argument</li> <li><a href="https://github.com/clap-rs/clap/commit/fc6aaca52b42d0e4ae13805e7480cbb05f63a0ca"><code>fc6aaca</code></a> Merge pull request <a href="https://redirect.github.com/clap-rs/clap/issues/5638">#5638</a> from epage/cargo</li> <li><a href="https://github.com/clap-rs/clap/commit/631e54bc715ed2fa53d8457dc273a25b92d3b354"><code>631e54b</code></a> docs(cookbook): Style cargo plugin</li> <li><a href="https://github.com/clap-rs/clap/commit/6fb49d08bb2acfbc2f2aa5f717ccd4a4018ca872"><code>6fb49d0</code></a> Merge pull request <a href="https://redirect.github.com/clap-rs/clap/issues/5636">#5636</a> from gibfahn/styles_const</li> <li><a href="https://github.com/clap-rs/clap/commit/6f215eee98c4f73099b0ede2ac62ba019ada24ce"><code>6f215ee</code></a> refactor(styles): make styles example use a const</li> <li><a href="https://github.com/clap-rs/clap/commit/bbb2e6fdde1c724e39c2f2616332310252c12ab8"><code>bbb2e6f</code></a> test: Add test case for completing custom value of argument</li> <li><a href="https://github.com/clap-rs/clap/commit/999071c46dca0367d93f66ecd97b2e3507963284"><code>999071c</code></a> fix: Change <code>visible</code> to <code>hidden</code></li> <li>Additional commits viewable in <a href="https://github.com/clap-rs/clap/compare/clap_complete-v4.4.0...clap_complete-v4.5.13">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=clap_complete&package-manager=cargo&previous-version=4.4.0&new-version=4.5.13)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
-
Bastian Köcher authored
There is a race condition when a validator sends its heads to the collator, but the collator doesn't yet know these heads. Before it is aware of these heads by importing the block(s), any collation registered on the collator is not announced to the validators. The collations aren't advertised, because the collator doesn't know yet that these heads of the validator are descendants of the collations relay parent. The solution is to store these unknown heads of the validators and to handle them when the collator updates its own view.
-
Nazar Mokrynskyi authored
This improves `sc-service` API by not requiring the whole `&Configuration`, using specific configuration options instead. `RpcConfiguration` was also extracted from `Configuration` to group all RPC options together. We don't use Substrate's CLI and would rather not use `Configuration` either, but some key public functions require it even though they ignored most of the fields anyway. `RpcConfiguration` is very helpful not just for consolidation of the fields, but also to finally make RPC optional for our use case, while Substrate still runs RPC server on localhost even if listening address is explicitly set to `None`, which is annoying (and I suspect there is a reason for it, so didn't want to change the default just yet). While this is a breaking change, most developers will not notice it if they use higher-level APIs. Fixes https://github.com/paritytech/polkadot-sdk/issues/2897 --------- Co-authored-by: Niklas Adolfsson <[email protected]>
-
Francisco Aguirre authored
# Context Fees can already be paid in other assets locally thanks to the Trader implementations we have. This doesn't work when sending messages because delivery fees go through a different mechanism altogether. The idea is to fix this leveraging the `AssetExchanger` config item that's able to turn the asset the user wants to pay fees in into the asset the router expects for delivery fees. # Main addition An adapter was needed to use `pallet-asset-conversion` for exchanging assets in XCM. This was created in https://github.com/paritytech/polkadot-sdk/pull/5130. The XCM executor was modified to use `AssetExchanger` (when available) to swap assets to pay for delivery fees. ## Limitations We can only pay for delivery fees in different assets in intermediate hops. We can't pay in different assets locally. The first hop will always need the native token of the chain (or whatever is specified in the `XcmRouter`). This is a byproduct of using the `BuyExecution` instruction to know which asset should be used for delivery fee payment. Since this instruction is not present when executing an XCM locally, we are left with this limitation. To illustrate this limitation, I'll show two scenarios. All chains involved have pools. ### Scenario 1 Parachain A --> Parachain B Here, parachain A can use any asset in a pool with its native asset to pay for local execution fees. However, as of now we can't use those for local delivery fees. This means transfers from A to B need some amount of A's native token to pay for delivery fees. ### Scenario 2 Parachain A --> Parachain C --> Parachain B Here, Parachain C's remote delivery fees can be paid with any asset in a pool with its native asset. This allows a reserve asset transfer between A and B with C as the reserve to only need A's native token at the starting hop. After that, it could all be pool assets. ## Future work The fact that delivery fees go through a totally different mechanism results in a lot of bugs and pain points. Unfortunately, this is not so easy to solve in a backwards compatible manner. Delivery fees will be integrated into the language in future XCM versions, following https://github.com/polkadot-fellows/xcm-format/pull/53. Old PR: https://github.com/paritytech/polkadot-sdk/pull/4375.
-
Alexandru Gheorghe authored
# Prerequisite This is part of the work to further optimize the approval subsystems, if you want to understand the full context start with reading https://github.com/paritytech/polkadot-sdk/pull/4849#issue-2364261568, # Description This PR contain changes, so that the crypto checks are performed by the approval-distribution subsystem instead of the approval-voting one. The benefit for these, is twofold: 1. Approval-distribution won't have to wait every single time for the approval-voting to finish its job, so the work gets to be pipelined between approval-distribution and approval-voting. 2. By running in parallel multiple instances of approval-distribution as described here https://github.com/paritytech/polkadot-sdk/pull/4849#issue-2364261568, this significant body of work gets to run in parallel. ## Changes: 1. When approval-voting send `ApprovalDistributionMessage::NewBlocks` it needs to pass the core_index and candidate_hash of the candidates. 2. ApprovalDistribution needs to use `RuntimeInfo` to be able to fetch the SessionInfo from the runtime. 3. Move `approval-voting` logic that checks VRF assignment into `approval-distribution` 4. Move `approval-voting` logic that checks vote is correctly signed into `approval-distribution` 5. Plumb `approval-distribution` and `approval-voting` tests to support the new logic. ## Benefits Even without parallelisation the gains are significant, for example on my machine if we run approval subsystem bench for 500 validators and 100 cores and trigger all 89 tranches of assignments and approvals, the system won't fall behind anymore because of late processing of messages. ``` Before change Chain selection approved after 11500 ms hash=0x0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a After change Chain selection approved after 5500 ms hash=0x0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a ``` ## TODO: - [x] Run on versi. - [x] Update parachain host documentation. --------- Signed-off-by: Alexandru Gheorghe <[email protected]>
-
dependabot[bot] authored
Bumps [color-eyre](https://github.com/eyre-rs/eyre) from 0.6.2 to 0.6.3. <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/eyre-rs/eyre/commit/f544fed447df75b1accbc95bc2c26aa8fedc312e"><code>f544fed</code></a> chore: Release</li> <li><a href="https://github.com/eyre-rs/eyre/commit/7689b983de53562d678f58a05a6dcfc57d5fae76"><code>7689b98</code></a> chore: don't inherit workspace readme</li> <li><a href="https://github.com/eyre-rs/eyre/commit/63cb4122fcff401efcab862ecf6c65509bc9d1c0"><code>63cb412</code></a> chore: remove old metadata</li> <li><a href="https://github.com/eyre-rs/eyre/commit/7e7e17319aaf7b42bffd9e9cd4a12cb1c2bc8318"><code>7e7e173</code></a> chore: update changelog</li> <li><a href="https://github.com/eyre-rs/eyre/commit/7a5c32acd7a4a6139448b7900a6787f70b5b69fb"><code>7a5c32a</code></a> Add color-eyre to workspace (<a href="https://redirect.github.com/eyre-rs/eyre/issues/110">#110</a>)</li> <li><a href="https://github.com/eyre-rs/eyre/commit/eb8d059c501fbad8de6c6c8af4745f73083969a3"><code>eb8d059</code></a> Merge remote-tracking branch 'origin/master' into color-eyre</li> <li><a href="https://github.com/eyre-rs/eyre/commit/75beaaea3fc85ddab5e9c81570d3c76ea3a21ac8"><code>75beaae</code></a> fix: remove <code>anyhow</code> feature flag from <code>OptionExt</code> location test (<a href="https://redirect.github.com/eyre-rs/eyre/issues/148">#148</a>)</li> <li><a href="https://github.com/eyre-rs/eyre/commit/e57015195082391e00132b4ea4a7ed9fe4536248"><code>e570151</code></a> color-spantrace: bump owo-colors to 4.0 (<a href="https://redirect.github.com/eyre-rs/eyre/issues/156">#156</a>)</li> <li><a href="https://github.com/eyre-rs/eyre/commit/cb4bab6fd0355461f6eec4241e4db9949d890e73"><code>cb4bab6</code></a> chore: update issues redirect</li> <li><a href="https://github.com/eyre-rs/eyre/commit/8ebc308a0ae54f04a410911d2f9c621c988b766a"><code>8ebc308</code></a> fix: make theme test more lenient</li> <li>Additional commits viewable in <a href="https://github.com/eyre-rs/eyre/compare/v0.6.2...color-eyre-v0.6.3">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=color-eyre&package-manager=cargo&previous-version=0.6.2&new-version=0.6.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
-
- Aug 31, 2024
-
-
Maksym H authored
Tiny fix for subweight diff in /cmd
-
Alexander Theißen authored
Added the new contracts pallet and also added @pgherveou as code owners.
-
- Aug 30, 2024
-
-
dependabot[bot] authored
Bumps the known_good_semver group with 4 updates in the / directory: [quote](https://github.com/dtolnay/quote), [serde](https://github.com/serde-rs/serde), [serde_json](https://github.com/serde-rs/json) and [syn](https://github.com/dtolnay/syn). Updates `quote` from 1.0.36 to 1.0.37 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/dtolnay/quote/releases">quote's releases</a>.</em></p> <blockquote> <h2>1.0.37</h2> <ul> <li>Implement ToTokens for CStr and CString (<a href="https://redirect.github.com/dtolnay/quote/issues/283">#283</a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/dtolnay/quote/commit/b1ebffa035363a430862e033aa3268e8cb17affa"><code>b1ebffa</code></a> Release 1.0.37</li> <li><a href="https://github.com/dtolnay/quote/commit/43acd77961424b3cb5035688f74d14d556eefe90"><code>43acd77</code></a> Delete unneeded use of <code>ref</code></li> <li><a href="https://github.com/dtolnay/quote/commit/9382c2182ea10f8e0f90d1e5f15ca3f20a777dff"><code>9382c21</code></a> Merge pull request <a href="https://redirect.github.com/dtolnay/quote/issues/283">#283</a> from dtolnay/cstr</li> <li><a href="https://github.com/dtolnay/quote/commit/6ac432877bbfe43892677e32af7e3f0e28b6333e"><code>6ac4328</code></a> Add C string tests</li> <li><a href="https://github.com/dtolnay/quote/commit/9fb0591a17893eea81260351c6eb431e1fd83524"><code>9fb0591</code></a> Implement ToTokens for CStr and CString</li> <li><a href="https://github.com/dtolnay/quote/commit/ba7a9d08c9acba8ae97926dcc18822b20441c0fa"><code>ba7a9d0</code></a> Organize test imports</li> <li><a href="https://github.com/dtolnay/quote/commit/aa9970f9838a5b6dd5438c662921470f873e2b3a"><code>aa9970f</code></a> Inline the macro that generates primitive impls</li> <li><a href="https://github.com/dtolnay/quote/commit/ba411091c98c311526774adde73e724448836337"><code>ba41109</code></a> Merge pull request <a href="https://redirect.github.com/dtolnay/quote/issues/282">#282</a> from dtolnay/tokens</li> <li><a href="https://github.com/dtolnay/quote/commit/c77340a4c6869690ad7b40069e8ca1cb90e4abb8"><code>c77340a</code></a> Consistently use 'tokens' as the name of the &mut TokenStream arg</li> <li><a href="https://github.com/dtolnay/quote/commit/a4a0abf12fa0137eca5aaa74fe88ca6694e78746"><code>a4a0abf</code></a> Merge pull request <a href="https://redirect.github.com/dtolnay/quote/issues/281">#281</a> from dtolnay/char</li> <li>Additional commits viewable in <a href="https://github.com/dtolnay/quote/compare/1.0.36...1.0.37">compare view</a></li> </ul> </details> <br /> Updates `serde` from 1.0.206 to 1.0.209 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/serde-rs/serde/releases">serde's releases</a>.</em></p> <blockquote> <h2>v1.0.209</h2> <ul> <li>Fix deserialization of empty structs and empty tuples inside of untagged enums (<a href="https://redirect.github.com/serde-rs/serde/issues/2805">#2805</a>, thanks <a href="https://github.com/Mingun"><code>@Mingun</code></a>)</li> </ul> <h2>v1.0.208</h2> <ul> <li>Support serializing and deserializing unit structs in a <code>flatten</code> field (<a href="https://redirect.github.com/serde-rs/serde/issues/2802">#2802</a>, thanks <a href="https://github.com/jonhoo"><code>@jonhoo</code></a>)</li> </ul> <h2>v1.0.207</h2> <ul> <li>Improve interactions between <code>flatten</code> attribute and <code>skip_serializing</code>/<code>skip_deserializing</code> (<a href="https://redirect.github.com/serde-rs/serde/issues/2795">#2795</a>, thanks <a href="https://github.com/Mingun"><code>@Mingun</code></a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/serde-rs/serde/commit/30752ac4ffdaa284606eda34055ad185e28c5499"><code>30752ac</code></a> Release 1.0.209</li> <li><a href="https://github.com/serde-rs/serde/commit/b84e6ca4f5fef69b3de985c586a07b1246f3eb9a"><code>b84e6ca</code></a> Improve wording of PR 2805 comments</li> <li><a href="https://github.com/serde-rs/serde/commit/87a2fb0f1a2774ea5bb20c0ed988b9ba57fc8166"><code>87a2fb0</code></a> Wrap comments from PR 2805 to 80 columns</li> <li><a href="https://github.com/serde-rs/serde/commit/9eaf7b9824f2082c50d17ad22b786322dc283a61"><code>9eaf7b9</code></a> Merge pull request <a href="https://redirect.github.com/serde-rs/serde/issues/2805">#2805</a> from Mingun/untagged-tests</li> <li><a href="https://github.com/serde-rs/serde/commit/7bde100237875d4f435de5ad90074b0479c37486"><code>7bde100</code></a> Replace MapRefDeserializer with value::MapDeserializer</li> <li><a href="https://github.com/serde-rs/serde/commit/da7fc795ee654252effa232a62a5a1e6d4f551ee"><code>da7fc79</code></a> Fix deserialization of empty struct variant in untagged enums</li> <li><a href="https://github.com/serde-rs/serde/commit/4c5fec1363d363f995375426f72db11c28f357c1"><code>4c5fec1</code></a> Test special cases that reaches SeqRefDeserializer::deserialize_any len==0 co...</li> <li><a href="https://github.com/serde-rs/serde/commit/6588b0ad3777f7ad930d68ab4b9ec5b9c25398e0"><code>6588b0a</code></a> Cover Content::Seq case in VariantRefDeserializer::struct_variant</li> <li><a href="https://github.com/serde-rs/serde/commit/0093f74cfee5ee3239514a7aad5fb44843eddcdd"><code>0093f74</code></a> Split test newtype_enum into four tests for each variant</li> <li><a href="https://github.com/serde-rs/serde/commit/171c6da57af712cfcf01c6c124b14cabfca364ba"><code>171c6da</code></a> Complete coverage of ContentRefDeserializer::deserialize_newtype_struct</li> <li>Additional commits viewable in <a href="https://github.com/serde-rs/serde/compare/v1.0.206...v1.0.209">compare view</a></li> </ul> </details> <br /> Updates `serde_derive` from 1.0.206 to 1.0.209 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/serde-rs/serde/releases">serde_derive's releases</a>.</em></p> <blockquote> <h2>v1.0.209</h2> <ul> <li>Fix deserialization of empty structs and empty tuples inside of untagged enums (<a href="https://redirect.github.com/serde-rs/serde/issues/2805">#2805</a>, thanks <a href="https://github.com/Mingun"><code>@Mingun</code></a>)</li> </ul> <h2>v1.0.208</h2> <ul> <li>Support serializing and deserializing unit structs in a <code>flatten</code> field (<a href="https://redirect.github.com/serde-rs/serde/issues/2802">#2802</a>, thanks <a href="https://github.com/jonhoo"><code>@jonhoo</code></a>)</li> </ul> <h2>v1.0.207</h2> <ul> <li>Improve interactions between <code>flatten</code> attribute and <code>skip_serializing</code>/<code>skip_deserializing</code> (<a href="https://redirect.github.com/serde-rs/serde/issues/2795">#2795</a>, thanks <a href="https://github.com/Mingun"><code>@Mingun</code></a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/serde-rs/serde/commit/30752ac4ffdaa284606eda34055ad185e28c5499"><code>30752ac</code></a> Release 1.0.209</li> <li><a href="https://github.com/serde-rs/serde/commit/b84e6ca4f5fef69b3de985c586a07b1246f3eb9a"><code>b84e6ca</code></a> Improve wording of PR 2805 comments</li> <li><a href="https://github.com/serde-rs/serde/commit/87a2fb0f1a2774ea5bb20c0ed988b9ba57fc8166"><code>87a2fb0</code></a> Wrap comments from PR 2805 to 80 columns</li> <li><a href="https://github.com/serde-rs/serde/commit/9eaf7b9824f2082c50d17ad22b786322dc283a61"><code>9eaf7b9</code></a> Merge pull request <a href="https://redirect.github.com/serde-rs/serde/issues/2805">#2805</a> from Mingun/untagged-tests</li> <li><a href="https://github.com/serde-rs/serde/commit/7bde100237875d4f435de5ad90074b0479c37486"><code>7bde100</code></a> Replace MapRefDeserializer with value::MapDeserializer</li> <li><a href="https://github.com/serde-rs/serde/commit/da7fc795ee654252effa232a62a5a1e6d4f551ee"><code>da7fc79</code></a> Fix deserialization of empty struct variant in untagged enums</li> <li><a href="https://github.com/serde-rs/serde/commit/4c5fec1363d363f995375426f72db11c28f357c1"><code>4c5fec1</code></a> Test special cases that reaches SeqRefDeserializer::deserialize_any len==0 co...</li> <li><a href="https://github.com/serde-rs/serde/commit/6588b0ad3777f7ad930d68ab4b9ec5b9c25398e0"><code>6588b0a</code></a> Cover Content::Seq case in VariantRefDeserializer::struct_variant</li> <li><a href="https://github.com/serde-rs/serde/commit/0093f74cfee5ee3239514a7aad5fb44843eddcdd"><code>0093f74</code></a> Split test newtype_enum into four tests for each variant</li> <li><a href="https://github.com/serde-rs/serde/commit/171c6da57af712cfcf01c6c124b14cabfca364ba"><code>171c6da</code></a> Complete coverage of ContentRefDeserializer::deserialize_newtype_struct</li> <li>Additional commits viewable in <a href="https://github.com/serde-rs/serde/compare/v1.0.206...v1.0.209">compare view</a></li> </ul> </details> <br /> Updates `serde_json` from 1.0.124 to 1.0.127 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/serde-rs/json/releases">serde_json's releases</a>.</em></p> <blockquote> <h2>1.0.127</h2> <ul> <li>Add more removal methods to OccupiedEntry (<a href="https://redirect.github.com/serde-rs/json/issues/1179">#1179</a>, thanks <a href="https://github.com/GREsau"><code>@GREsau</code></a>)</li> </ul> <h2>1.0.126</h2> <ul> <li>Improve string parsing on targets that use 32-bit pointers but also have fast 64-bit integer arithmetic, such as aarch64-unknown-linux-gnu_ilp32 and x86_64-unknown-linux-gnux32 (<a href="https://redirect.github.com/serde-rs/json/issues/1182">#1182</a>, thanks <a href="https://github.com/CryZe"><code>@CryZe</code></a>)</li> </ul> <h2>1.0.125</h2> <ul> <li>Speed up \uXXXX parsing and improve handling of unpaired surrogates when deserializing to bytes (<a href="https://redirect.github.com/serde-rs/json/issues/1172">#1172</a>, <a href="https://redirect.github.com/serde-rs/json/issues/1175">#1175</a>, thanks <a href="https://github.com/purplesyringa"><code>@purplesyringa</code></a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/serde-rs/json/commit/5ebf65cc480f90714c94f82099ca9161d80cbb10"><code>5ebf65c</code></a> Release 1.0.127</li> <li><a href="https://github.com/serde-rs/json/commit/f287a3b1a93ecb1a11cee31cb638bd9523a58add"><code>f287a3b</code></a> Merge pull request 1179 from GREsau/patch-1</li> <li><a href="https://github.com/serde-rs/json/commit/ec980b02774abbff12fd3e26b0a1582eb14dcef7"><code>ec980b0</code></a> Release 1.0.126</li> <li><a href="https://github.com/serde-rs/json/commit/e6282b0c479947805a33c7f167b1d19dd4c7ad4f"><code>e6282b0</code></a> Merge pull request <a href="https://redirect.github.com/serde-rs/json/issues/1184">#1184</a> from serde-rs/fastarithmetic</li> <li><a href="https://github.com/serde-rs/json/commit/ffc4a43453029cdc5603cfe3ef08414488fd45de"><code>ffc4a43</code></a> Improve cfg names for fast arithmetic</li> <li><a href="https://github.com/serde-rs/json/commit/4b1048d0ecc4d326d6657531689513f182a4f850"><code>4b1048d</code></a> Merge pull request <a href="https://redirect.github.com/serde-rs/json/issues/1183">#1183</a> from serde-rs/arithmetic</li> <li><a href="https://github.com/serde-rs/json/commit/f268173a9fb1f5f8a80f47af62b564525cf33764"><code>f268173</code></a> Unify chunk size choice between float and string parsing</li> <li><a href="https://github.com/serde-rs/json/commit/fec03769743c3f0ceb6b5b56d91321fdc856dff2"><code>fec0376</code></a> Merge pull request <a href="https://redirect.github.com/serde-rs/json/issues/1182">#1182</a> from CryZe/chunk-64bit</li> <li><a href="https://github.com/serde-rs/json/commit/3d837e1cc4a0f1df56ba6645c3b6d144768b5d9d"><code>3d837e1</code></a> Ensure the SWAR chunks are 64-bit in more cases</li> <li><a href="https://github.com/serde-rs/json/commit/11fc61c7af7b59ea80fb2ef7d78db94465dfbd54"><code>11fc61c</code></a> Add <code>OccupiedEntry::shift_remove()</code> and <code>swap_remove()</code></li> <li>Additional commits viewable in <a href="https://github.com/serde-rs/json/compare/v1.0.124...1.0.127">compare view</a></li> </ul> </details> <br /> Updates `syn` from 2.0.61 to 2.0.65 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/dtolnay/syn/releases">syn's releases</a>.</em></p> <blockquote> <h2>2.0.65</h2> <ul> <li>Optimize the implementation of <code>Fold</code> to compile faster (<a href="https://redirect.github.com/dtolnay/syn/issues/1666">#1666</a>, <a href="https://redirect.github.com/dtolnay/syn/issues/1667">#1667</a>, <a href="https://redirect.github.com/dtolnay/syn/issues/1668">#1668</a>)</li> </ul> <h2>2.0.64</h2> <ul> <li>Support using ParseBuffer across <code>catch_unwind</code> (<a href="https://redirect.github.com/dtolnay/syn/issues/1646">#1646</a>)</li> <li>Validate that the expression in a let-else ends in brace as required by rustc (<a href="https://redirect.github.com/dtolnay/syn/issues/1648">#1648</a>, <a href="https://redirect.github.com/dtolnay/syn/issues/1649">#1649</a>)</li> <li>Legalize invalid const generic arguments by wrapping in braces (<a href="https://redirect.github.com/dtolnay/syn/issues/1654">#1654</a>, <a href="https://redirect.github.com/dtolnay/syn/issues/1655">#1655</a>)</li> <li>Fix some expression precedence edge cases involving <code>break</code> and <code>return</code> in loop headers (<a href="https://redirect.github.com/dtolnay/syn/issues/1656">#1656</a>)</li> <li>Always print closure bodies with a brace when the closure has an explicit return type (<a href="https://redirect.github.com/dtolnay/syn/issues/1658">#1658</a>)</li> <li>Automatically insert necessary parentheses in ToTokens for Expr when required by expression precedence (<a href="https://redirect.github.com/dtolnay/syn/issues/1659">#1659</a>)</li> <li>Support struct literal syntax in match guard expressions (<a href="https://redirect.github.com/dtolnay/syn/issues/1662">#1662</a>)</li> </ul> <h2>2.0.63</h2> <ul> <li>Parse and print long if-else-if chains without reliance on deep recursion to avoid overflowing stack (<a href="https://redirect.github.com/dtolnay/syn/issues/1644">#1644</a>, <a href="https://redirect.github.com/dtolnay/syn/issues/1645">#1645</a>)</li> </ul> <h2>2.0.62</h2> <ul> <li>Reject invalid unparenthesized range and comparison operator expressions (<a href="https://redirect.github.com/dtolnay/syn/issues/1642">#1642</a>, <a href="https://redirect.github.com/dtolnay/syn/issues/1643">#1643</a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/dtolnay/syn/commit/9f2371eefa6f681b53e4d74458d86dd41673227f"><code>9f2371e</code></a> Release 2.0.65</li> <li><a href="https://github.com/dtolnay/syn/commit/4cd181325f3488c47866f15966977682be610da1"><code>4cd1813</code></a> Merge pull request <a href="https://redirect.github.com/dtolnay/syn/issues/1668">#1668</a> from dtolnay/foldhelper</li> <li><a href="https://github.com/dtolnay/syn/commit/ed54092bcea6798ab0b5ed7aca6755f8918fc79e"><code>ed54092</code></a> Eliminate gen::helper module</li> <li><a href="https://github.com/dtolnay/syn/commit/eacc8ab1b98b590df3ce9462510fd755cddf6762"><code>eacc8ab</code></a> Eliminate FoldHelper trait</li> <li><a href="https://github.com/dtolnay/syn/commit/6e20bb8d7799d0f4c34c144e80b3bd1b6e9afd27"><code>6e20bb8</code></a> Merge pull request <a href="https://redirect.github.com/dtolnay/syn/issues/1667">#1667</a> from dtolnay/punctuatedfold</li> <li><a href="https://github.com/dtolnay/syn/commit/9d95cab6d332d08903538d5ce3d6e47c1598912e"><code>9d95cab</code></a> Optimize punctuated::fold</li> <li><a href="https://github.com/dtolnay/syn/commit/82ffe86c2b721b9985edb6f368e7366bd202bc5b"><code>82ffe86</code></a> Move Punctuated fold helper to punctuated module</li> <li><a href="https://github.com/dtolnay/syn/commit/3dfacc1538f655d33c5c8037b14669149bcd81cd"><code>3dfacc1</code></a> Ignore manual_map clippy lint</li> <li><a href="https://github.com/dtolnay/syn/commit/7273aa77aa09ee2562b279a5d9495a212d9c0876"><code>7273aa7</code></a> Merge pull request <a href="https://redirect.github.com/dtolnay/syn/issues/1666">#1666</a> from dtolnay/foldhelper</li> <li><a href="https://github.com/dtolnay/syn/commit/8124c0eb99e11cae036d2c967f91f0c456c50368"><code>8124c0e</code></a> Generate fewer monomorphizations in Fold</li> <li>Additional commits viewable in <a href="https://github.com/dtolnay/syn/compare/2.0.61...2.0.65">compare view</a></li> </ul> </details> <br /> Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore <dependency name> major version` will close this group update PR and stop Dependabot creating any more for the specific dependency's major version (unless you unignore this specific dependency's major version or upgrade to it yourself) - `@dependabot ignore <dependency name> minor version` will close this group update PR and stop Dependabot creating any more for the specific dependency's minor version (unless you unignore this specific dependency's minor version or upgrade to it yourself) - `@dependabot ignore <dependency name>` will close this group update PR and stop Dependabot creating any more for the specific dependency (unless you unignore this specific dependency or upgrade to it yourself) - `@dependabot unignore <dependency name>` will remove all of the ignore conditions of the specified dependency - `@dependabot unignore <dependency name> <ignore condition>` will remove the ignore condition of the specified dependency and ignore conditions </details> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
-
Jan-Jan authored
# Description Trivial doc fixes: * Replace the word `reminder` with `remainder` so that the English matches the code intent. * Explicit instruct the reader to `clone`. ## Review Notes * Trivial Co-authored-by: Jan-Jan <[email protected]>
-
Michal Kucharczyk authored
Gensis config presets moved from `parachain-template-node` binary into `parachain-template-runtime` runtime. cc: @PierreBesson
-
Michal Kucharczyk authored
Gensis config presets moved from `polkadot-parachain` binary into `asset-hub-rococo` runtime. relates to: #3944 --------- Co-authored-by: Dónal Murray <[email protected]> Co-authored-by: Bastian Köcher <[email protected]>
-
Maksym H authored
- restore update-ui.sh (accidentally removed with bunch of bash
😅 - fix empty context and pushing to dev branch (supporting forks) tested fork here: https://github.com/paritytech-stg/polkadot-sdk/pull/45 -
zjb0807 authored
# Description The error message should be logged out when the check method returns an error. Because specific information is lost when `UmpAcceptanceCheckErr`, `ProcessedDownwardMessagesAcceptanceErr`, `HrmpWatermarkAcceptanceErr`, `OutboundHrmpAcceptanceErr` are converted to `AcceptanceCheckErr`, a log is added to each check. ## Integration ## Review Notes # Checklist * [ ] My PR includes a detailed description as outlined in the "Description" and its two subsections above. * [ ] My PR follows the [labeling requirements]( https://github.com/paritytech/polkadot-sdk/blob/master/docs/contributor/CONTRIBUTING.md#Process ) of this project (at minimum one label for `T` required) * External contributors: ask maintainers to put the right label on your PR. * [ ] I have made corresponding changes to the documentation (if applicable) * [ ] I have added tests that prove my fix is effective or that my feature works (if applicable)
-
Andrei Sandu authored
As Runtime release 1.3.0 includes all of the remaining staging primitives and APIs we can now release primitives version 8. No other changes other than renaming/moving done here. --------- Signed-off-by: Andrei Sandu <[email protected]>
-
Liu-Cheng Xu authored
Tiny changes to simplify the code: - Remove an unnecessary `collect`. - Reduce the code duplication a little bit. --------- Co-authored-by: Alexandru Vasile <[email protected]>
-
Javyer authored
This is used for the steps that use the `macos` runner. It installs the Rust version that we are using in the [`forklift` image](https://github.com/paritytech/polkadot-sdk/blob/master/.github/env). To be used in #5386.
-
Alexandru Gheorghe authored
Add support in subsystem-benchmarks to profile memory usage using the jemalloc builting profiler, this allows us to run each benchmark with profiling enabled and determine if the memory usage patters are in conformance with our expectations. --------- Signed-off-by: Alexandru Gheorghe <[email protected]>
-
- Aug 29, 2024
-
-
Alexander Samusev authored
PR moves rococo and wococo check-runtime-migration jobs to GHA cc https://github.com/paritytech/ci_cd/issues/1006
-
dharjeezy authored
closes https://github.com/paritytech/polkadot-sdk/issues/5448 --------- Co-authored-by: Gonçalo Pestana <[email protected]> Co-authored-by: Ankan <[email protected]>
-
ordian authored
On top of #5082. ## Background Previously, before #3479, we would [include](https://github.com/paritytech/polkadot-sdk/blame/75074952/polkadot/runtime/parachains/src/builder.rs#L508C12-L508C44) the cost enacting the candidate into the cost of processing a single bitfield. [Now](https://github.com/paritytech/polkadot-sdk/blame/dd48544a/polkadot/runtime/parachains/src/builder.rs#L529) it is different, although the benchmarks seems to be not-up-to date. Including the cost of enacting a candidate into a processing a single bitfield cost was incorrect, since we multiple that by the number of bitfields we have. Instead, we should separate calculate the cost of processing a single bitfield without enactment, and multiple the cost of enactment by the actual number of processed candidates (which is limited by the number cores, not validators). ## Bench Previously, the weight of `enact_candidate` was calculated manually (without a benchmark) and then neglected: https://github.com/paritytech/polkadot-sdk/blob/dd48544a /polkadot/runtime/parachains/src/inclusion/mod.rs#L584 In this PR, we have a benchmark for it and it's based on the number of ump and sent hrmp messages as well as whether the candidate has a runtime upgrade (new_validation_code). The differences from the previous attempt https://github.com/paritytech/polkadot/pull/6929 are that * we don't include the cost of enactment into the cost of processing a backed candidate. The reason for it is that enactment happens not in the same block as backing (typically the next one), since we process bitfields before backing votes. * we don't take into account the size of the runtime upgrade, the benchmark weight doesn't seem to depend much on it, but rather whether there was one or not. Similarly to the previous attempt, we don't account for dmp messages (fixed cost). Also we don't account properly for received hrmp messages (hrmp_watermark) because the cost of it depends on the runtime state and can't be statically deduced in the benchmark (unless we pass the information about channels as benchmark u32 arguments). The total weight cost of processing a parainherent now includes the cost of enactment of each candidate, but we don't do filtering based on that (because we enact after processing bitfields and making other changes to the storage). ## Numbers ``` Reads = 7 + (0 * u) + (3 * h) + (8 * c) Writes = 10 + (1 * u) + (3 * h) + (7 * c) ``` In addition, there is a fixed cost of a few of ms (!) per candidate. This might result a full block slightly overflowing its weight with 200 enacted candidates, which in turn could prevent non-mandatory transactions from being included in a block. Given our modest limits on max ump and hrmp messages: ``` maxUpwardMessageNumPerCandidate: 16 hrmpMaxMessageNumPerCandidate: 10 ``` and the fact that runtime upgrades are can't happen very frequently (`validation_upgrade_cooldown`), we might only go over the limits in case of many disputes. TODOs: - [x] Fix the overweight test - [x] Generate the weights for Westend and Rococo - [x] PRDoc --------- Co-authored-by: command-bot <> Co-authored-by: Alin Dima <[email protected]>
-
Oliver Tale-Yazdi authored
Changes: - Backport bot should just commit merge conflicts instead of failing.
-
Lech Głowiak authored
# Description Add `starting_timestamp` function for `Slot` type. ## Integration This is an addition of public function to a type, so integration should be seamless for idiomatic use of Rust. ## Review Notes Since `Slot` is just a slot number, the it's starting timestamp depends on `SlotDuration` which is a parameter to the added function. This function can be seen as dual to existing `fn from_timestamp`. Because there is a potential for overflow, the return type is `Option`. Q1: should I introduce tests for in this crate and add cases for both case: overflow (`None`) and no overflow (`Some`)? Q2: How can I add labels? IMO they should be `T0-node` and `D0-easy` but I cannot add them using GH interface. # Checklist * [x] My PR includes a detailed description as outlined in the "Description" and its two subsections above. * [ ] My PR follows the [labeling requirements](CONTRIBUTING.md#Process) of this project (at minimum one label for `T` required) * External contributors: ask maintainers to put the right label on your PR. * [ ] I have made corresponding changes to the documentation (if applicable) * [ ] I have added tests that prove my fix is effective or that my feature works (if applicable) --------- Co-authored-by: Squirrel <[email protected]> Co-authored-by: Davide Galassi <[email protected]>
-
Alexander Samusev authored
PR migrates jobs `quick-benchmarks`, `cargo-clippy`, `check-try-runtime` and `check-core-crypto-features` from Gitlab to GitHub cc https://github.com/paritytech/ci_cd/issues/1006 --------- Co-authored-by: Maksym H <[email protected]>
-
ordian authored
closes #849 ## Context For the background on this and the long-term fix, see https://github.com/paritytech/polkadot-sdk/issues/849#issuecomment-2247895862. ## Changes * The weigh files are renamed from `runtime_(parachains|common).*` to `polkadot_runtime_(parachains|common).*`. The reason for it is the renaming introduced in #4633. The new weight command and files are generated now include `polkadot_` prefix. * The WeightInfo for `paras_inherent` now includes `enter_empty` which calculates the cost of processing an empty parachains inherent. This cost is subtracted dynamically when calculating other weights (so the other weights remain the same) ## Benefits See https://github.com/paritytech/polkadot-sdk/issues/849#issuecomment-2247895862, but TL;DR is that we are not blocked on weights for scaling the number of validators and cores further. Resolved questions: - [x] why new benchmarks for westend are doing fewer db IOPS? Is it due polkadot-sdk update (db IOPS diff)? or the bench setup is no longer valid? https://github.com/polkadot-fellows/runtimes/blob/7723274a2c5cbb10213379271094d5180716ca7d/relay/polkadot/src/weights/runtime_parachains_paras_inherent.rs#L131-L196 Answer: see background section of #5270 TODOs: - [x] Rerun benchmarks for Rococo and Westend - [x] PRDoc --------- Co-authored-by: command-bot <>
-