Skip to content
Snippets Groups Projects
  1. Jan 07, 2025
    • Iulian Barbu's avatar
      workflows: add debug input for sync templates act (#7057) · 1059be75
      Iulian Barbu authored
      
      # Description
      
      Introduce a workflow `debug` input for `misc-sync-templates.yml` and use
      it instead of the `runner.debug` context variable, which is set to '1'
      when `ACTIONS_RUNNER_DEBUG` env/secret is set
      (https://docs.github.com/en/actions/monitoring-and-troubleshooting-workflows/troubleshooting-workflows/enabling-debug-logging#enabling-runner-diagnostic-logging).
      This is useful for controlling when to show debug prints.
      
      ## Integration
      
      N/A
      
      ## Review Notes
      
      Using `runner.debug` requires setting the `ACTIONS_RUNNER_DEBUG` env
      variable, but setting it to false/true is doable through an input, or by
      importing a variable from the github env file (which requires a code
      change). This input alone can replace the entire `runner.debug` +
      `ACTIONS_RUNNER_DEBUG` setup, which simplifies debug printing, but it
      doesn't look as standard as `runner.debug`. I don't think it is a big
      deal overall, for this action alone, but happy to account for other
      opinions.
      
      Note: setting the `ACTIONS_RUNNER_DEBUG` whenever we want in a separate
      branch wouldn't be useful because we can not run the
      `misc-sync-templates.yml` action from other branch than `master` (due to
      branch protection rules), so we need to expose this input to be
      controllable from `master`.
      
      ---------
      
      Signed-off-by: default avatarIulian Barbu <iulian.barbu@parity.io>
    • Jeeyong Um's avatar
      Remove usage of `sp-std` from Substrate (#7043) · c1397398
      Jeeyong Um authored
      
      # Description
      
      This PR removes usage of deprecated `sp-std` from Substrate. (following
      PR of #5010)
      
      ## Integration
      
      This PR doesn't remove re-exported `sp_std` from any crates yet, so
      downstream projects using re-exported `sp_std` will not be affected.
      
      ## Review Notes
      
      The existing code using `sp-std` is refactored to use `alloc` and `core`
      directly. The key-value maps are instantiated from a vector of tuples
      directly instead of using `sp_std::map!` macro.
      
      `sp_std::Writer` is a helper type to use `Vec<u8>` with
      `core::fmt::Write` trait. This PR copied it into `sp-runtime`, because
      all crates using `sp_std::Writer` (including `sp-runtime` itself,
      `frame-support`, etc.) depend on `sp-runtime`.
      
      If this PR is merged, I would write following PRs to remove remaining
      usage of `sp-std` from `bridges` and `cumulus`.
      
      ---------
      
      Co-authored-by: command-bot <>
      Co-authored-by: default avatarGuillaume Thiolliere <guillaume.thiolliere@parity.io>
      Co-authored-by: default avatarBastian Köcher <info@kchr.de>
      Co-authored-by: default avatarBastian Köcher <git@kchr.de>
  2. Jan 06, 2025
    • jasmy's avatar
      Fix typos (#7027) · 6b6c70b0
      jasmy authored
      
      Co-authored-by: default avatarDónal Murray <donal.murray@parity.io>
    • Oliver Tale-Yazdi's avatar
      [core-fellowship] Add permissionless import_member (#7030) · 568231a9
      Oliver Tale-Yazdi authored
      
      Changes:
      - Add call `import_member` to the core-fellowship pallet.
      - Move common logic between `import` and `import_member` into
      `do_import`.
      
      ## `import_member`
      
      Can be used to induct an arbitrary collective member and is callable by
      any signed origin. Pays no fees upon success.
      This is useful in the case that members did not induct themselves and
      are idling on their rank.
      
      ---------
      
      Signed-off-by: default avatarOliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
      Co-authored-by: default avatarBastian Köcher <git@kchr.de>
      Co-authored-by: command-bot <>
    • Sebastian Kunert's avatar
      Avoid incomplete block import pipeline with full verifying import queue (#7050) · 1dcff3df
      Sebastian Kunert authored
      ## Problem
      In the parachain template we use the [fully verifying import queue
      
      ](https://github.com/paritytech/polkadot-sdk/blob/3d9eddbe/cumulus/client/consensus/aura/src/equivocation_import_queue.rs#L224-L224)
      which does extra equivocation checks.
      
      However, when we import a warp synced block with state, we don't set a
      fork choice, leading to an incomplete block import pipeline and error
      here:
      https://github.com/paritytech/polkadot-sdk/blob/3d9eddbe/substrate/client/service/src/client/client.rs#L488-L488
      
      This renders warp sync useless for chains using this import queue.
      
      ## Fix
      The fix is to always import a block with state as best block, as we
      already do in the normal Aura Verifier.
      In a follow up we should also take another look into unifying the usage
      of the different import queues.
      
      fixes https://github.com/paritytech/project-mythical/issues/256
      
      ---------
      
      Co-authored-by: command-bot <>
    • Alin Dima's avatar
      fix chunk fetching network compatibility zombienet test (#6988) · ffa90d0f
      Alin Dima authored
      Fix this zombienet test
      
      It was failing because in
      https://github.com/paritytech/polkadot-sdk/pull/6452 I enabled the v2
      receipts for testnet genesis,
      so the collators started sending v2 receipts with zeroed collator
      signatures to old validators that were still checking those signatures
      (which lead to disputes, since new validators considered the candidates
      valid).
      
      The fix is to also use an old image for collators, so that we don't
      create v2 receipts.
      
      We cannot remove this test yet because collators also perform chunk
      recovery, so until all collators are upgraded, we need to maintain this
      compatibility with the old protocol version (which is also why
      systematic recovery was not yet enabled)
    • taozui472's avatar
      chore: delete repeat words (#7034) · 6eca7647
      taozui472 authored
      
      Co-authored-by: default avatarDónal Murray <donal.murray@parity.io>
    • thiolliere's avatar
      Print taplo version in CI (#7041) · 8d2130cc
      thiolliere authored
      I can't find taplo version in the log, and current version is
      incompatible with latest version.
  3. Jan 05, 2025
    • thiolliere's avatar
      Implement cumulus StorageWeightReclaim as wrapping transaction extension +... · 63c73bf6
      thiolliere authored
      Implement cumulus StorageWeightReclaim as wrapping transaction extension + frame system ReclaimWeight (#6140)
      
      (rebasing of https://github.com/paritytech/polkadot-sdk/pull/5234)
      
      ## Issues:
      
      * Transaction extensions have weights and refund weight. So the
      reclaiming of unused weight must happen last in the transaction
      extension pipeline. Currently it is inside `CheckWeight`.
      * cumulus storage weight reclaim transaction extension misses the proof
      size of logic happening prior to itself.
      
      ## Done:
      
      * a new storage `ExtrinsicWeightReclaimed` in frame-system. Any logic
      which attempts to do some reclaim must use this storage to avoid double
      reclaim.
      * a new function `reclaim_weight` in frame-system pallet: info and post
      info in arguments, read the already reclaimed weight, calculate the new
      unused weight from info and post info. do the more accurate reclaim if
      higher.
      * `CheckWeight` is unchanged and still reclaim the weight in post
      dispatch
      * `ReclaimWeight` is a new transaction extension in frame system. For
      solo chains it must be used last in the transactino extension pipeline.
      It does the final most accurate reclaim
      * `StorageWeightReclaim` is moved from cumulus primitives into its own
      pallet (in order to define benchmark) and is changed into a wrapping
      transaction extension.
      It does the recording of proof size and does the reclaim using this
      recording and the info and post info. So parachains don't need to use
      `ReclaimWeight`. But also if they use it, there is no bug.
      
          ```rust
        /// The TransactionExtension to the basic transaction logic.
      pub type TxExtension =
      cumulus_pallet_weight_reclaim::StorageWeightReclaim<
               Runtime,
               (
                       frame_system::CheckNonZeroSender<Runtime>,
                       frame_system::CheckSpecVersion<Runtime>,
                       frame_system::CheckTxVersion<Runtime>,
                       frame_system::CheckGenesis<Runtime>,
                       frame_system::CheckEra<Runtime>,
                       frame_system::CheckNonce<Runtime>,
                       frame_system::CheckWeight<Runtime>,
      pallet_transaction_payment::ChargeTransactionPayment<Runtime>,
                       BridgeRejectObsoleteHeadersAndMessages,
      
      (bridge_to_rococo_config::OnBridgeHubWestendRefundBridgeHubRococoMessages,),
      frame_metadata_hash_extension::CheckMetadataHash<Runtime>,
               ),
        >;
        ```
      
      ---------
      
      Co-authored-by: default avatarGitHub Action <action@github.com>
      Co-authored-by: default avatargeorgepisaltu <52418509+georgepisaltu@users.noreply.github.com>
      Co-authored-by: default avatarOliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
      Co-authored-by: default avatarSebastian Kunert <skunert49@gmail.com>
      Co-authored-by: command-bot <>
  4. Jan 04, 2025
    • thiolliere's avatar
      Make `TransactionExtension` tuple of tuple transparent for implication (#7028) · b5a5ac44
      thiolliere authored
      
      Currently `(A, B, C)` and `((A, B), C)` change the order of implications
      in the transaction extension pipeline. This order is not accessible in
      the metadata, because the metadata is just a vector of transaction
      extension, the nested structure is not visible.
      
      This PR make the implementation for tuple of `TransactionExtension`
      better for tuple of tuple. `(A, B, C)` and `((A, B), C)` don't change
      the implication for the validation A.
      
      This is a breaking change but only when using the trait
      `TransactionExtension` the code implementing the trait is not breaking
      (surprising rust behavior but fine).
      
      ---------
      
      Co-authored-by: command-bot <>
      Co-authored-by: default avatarBastian Köcher <git@kchr.de>
  5. Jan 03, 2025
  6. Jan 02, 2025
  7. Dec 30, 2024
  8. Dec 29, 2024
  9. Dec 27, 2024
  10. Dec 23, 2024
  11. Dec 22, 2024
  12. Dec 21, 2024
    • Dónal Murray's avatar
      [pallet-broker] add extrinsic to reserve a system core without having to wait... · f9cdf41a
      Dónal Murray authored
      [pallet-broker] add extrinsic to reserve a system core without having to wait two sale boundaries (#4273)
      
      When calling the reserve extrinsic after sales have started, the
      assignment will be reserved, but two sale period boundaries must pass
      before the core is actually assigned.
      
      Since this can take between 28 and 56 days on production networks, a new
      extrinsic is introduced to shorten the timeline.
      
      This essentially performs three actions:
      1. Reserve it (applies after two sale boundaries)
      2. Add it to the Workplan for the next sale period
      3. Add it to the Workplan for the rest of the current sale period from
      the next timeslice to be commmitted.
      
      The caller must ensure that a core is first added, with most relay chain
      implementations having a delay of two session boundaries until it comes
      into effect.
      
      Alternatively the extrinsic can be called on a core whose workload can
      be clobbered from now until the reservation kicks in (the sale period
      after the next). Any workplan entries for that core at other timeslices
      should be first removed by the caller.
      
      ---------
      
      Co-authored-by: command-bot <>
  13. Dec 20, 2024
  14. Dec 19, 2024