Skip to content
  1. Oct 30, 2023
  2. Oct 28, 2023
  3. Oct 27, 2023
  4. Oct 26, 2023
  5. Oct 16, 2023
  6. Oct 04, 2023
  7. Sep 29, 2023
    • eskimor's avatar
      Finish migration code so far. · 3ea247d4
      eskimor authored
      3ea247d4
    • eskimor's avatar
      Merge branch 'master' into rk-core-time-prep · e5ca4c68
      eskimor authored
      e5ca4c68
    • eskimor's avatar
      Storage migration for `Option` removal. · c7df19f3
      eskimor authored
      c7df19f3
    • Bastian Köcher's avatar
      Remove kusama and polkadot runtime crates (#1731) · bf90cb0b
      Bastian Köcher authored
      This pull request is removing the Kusama and Polkadot runtime crates. As
      still some crates dependent on the runtime crates, this pull request is
      doing some more changes.
      
      - It removes the `hostperfcheck` CLI command. This CLI command could
      compare the current node against the standard hardware by doing some
      checks. Later we added the hardware benchmark feature to Substrate. This
      hardware benchmark is running on every node startup and prints a warning
      if the current node is too slow. This makes this CLI command a duplicate
      that was also depending on the kusama runtime.
      
      - The pull request is removing the emulated integration tests that were
      requiring the Kusama or Polkadot runtime crates.
      bf90cb0b
    • Sebastian Kunert's avatar
      Use `Extensions` to register offchain worker custom extensions (#1719) · 4902db21
      Sebastian Kunert authored
      
      
      Closes #1671 
      
      Adds a `type_id` function to the `Extension` trait, allowing to properly store an retrieve
      boxed `Extensions`.
      
      ---------
      
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      4902db21
    • Tadeo Hepperle's avatar
      [RPC-Spec-V2] chainHead: use integer for block index and adjust RuntimeVersion JSON format (#1666) · 379be3d7
      Tadeo Hepperle authored
      This PR adjusts the serialized format of the the returned RuntimeVersion
      in the rpc-spec-v2 methods. This is done to match the format defined
      here:
      https://paritytech.github.io/json-rpc-interface-spec/api/chainHead_unstable_follow.html#about-the-runtime
      
      - ##### `apis` field as object
      `apis` field of `RuntimeVersion` is now returned as an object, e.g. 
      ```
      "apis": {
            "0xdf6acb689907609b": 3,
            "0x37e397fc7c91f5e4": 1,
      }
      ```
      instead of 
      ```
      "apis": [
            ["0xdf6acb689907609b", 3],
            ["0x37e397fc7c91f5e4", 1],
      ]
      ```
      - ##### removed `stateVersion` and `authoringVersion`
      `stateVersion` and `authoringVersion` are no longer returned in the
      `RuntimeVersion` JSON Object.
      
      - ##### block index in chain head events as integer
      
      ### Related Issues
      
      Closes: #1507
      Closes: #1146
      
      ### Testing Done
      Adjusted existing tests to make sure data is returned in the correct
      format.
      379be3d7
  8. Sep 28, 2023
    • Mira Ressel's avatar
    • btwiuse's avatar
      Fix `subkey inspect` output text padding (#1744) · 7b9861a2
      btwiuse authored
      
      
      This pull request is to fix the output text misalignment of `subkey
      inspect` command:
      
      (the `Network ID` line has an extra space at the end, and the `Secret
      seed` line lacks a leading space)
      
      ```
      [btwiuse@railway ~]$ subkey inspect '' | cat -A
      Secret Key URI `` is account:$
        Network ID:        substrate $
       Secret seed:       0xfac7959dbfe72f052e5a0c3c8d6530f202b02fd8f9f5ca3580ec8deb7797479e$
        Public key (hex):  0x46ebddef8cd9bb167dc30878d7113b7e168e6f0646beffd77d69d39bad76b47a$
        Account ID:        0x46ebddef8cd9bb167dc30878d7113b7e168e6f0646beffd77d69d39bad76b47a$
        Public key (SS58): 5DfhGyQdFobKM8NsWvEeAKk5EQQgYe9AydgJ7rMB6E1EqRzV$
        SS58 Address:      5DfhGyQdFobKM8NsWvEeAKk5EQQgYe9AydgJ7rMB6E1EqRzV$
      ```
      
      The output should be in the same YAML-like format as `subkey generate`:
      
      ```
      [btwiuse@railway ~]$ subkey generate  | cat -A
      Secret phrase:       awkward eagle survey resemble novel resist modify memory pistol shed flower run$
        Network ID:        substrate$
        Secret seed:       0x20502f79366325b7dc7620664e8844ae69d441baf6e5b571a57d3b3ff28e9586$
        Public key (hex):  0x468874b9e5b6b77333fa702b9201b924d6834bf956e33e2bbe37d131134ca830$
        Account ID:        0x468874b9e5b6b77333fa702b9201b924d6834bf956e33e2bbe37d131134ca830$
        Public key (SS58): 5DfBkAMg5xQmsePFr3BWLZm99smiNyy9axWSgembvFgDKh9v$
        SS58 Address:      5DfBkAMg5xQmsePFr3BWLZm99smiNyy9axWSgembvFgDKh9v$
      ```
      
      This change will fix `subkey` as well as all binaries that embed it as
      the `key` subcommand, for example: `substrate key`, `polkadot key`, etc.
      
      ---------
      
      Co-authored-by: default avatarLiam Aharon <[email protected]>
      7b9861a2
    • Alexandru Vasile's avatar
      archive: Implement height, hashByHeight and call (#1582) · 945ebbbc
      Alexandru Vasile authored
      
      
      This PR implements:
      - `archive_unstable_finalized_height`: Get the height of the most recent
      finalized block
      - `archive_unstable_hash_by_height`: Get the hashes (possible empty) of
      blocks from the given height
      - `archive_unstable_call`: Call into the runtime of a block
      
      Builds on top of: https://github.com/paritytech/polkadot-sdk/pull/1560
      
      ### Testing Done
      - unit tests for the methods with custom block tree for different
      heights / forks
      
      Closes: https://github.com/paritytech/polkadot-sdk/issues/1510
      Closes: https://github.com/paritytech/polkadot-sdk/issues/1513
      Closes: https://github.com/paritytech/polkadot-sdk/issues/1511
      
      @paritytech/subxt-team
      
      ---------
      
      Signed-off-by: default avatarAlexandru Vasile <[email protected]>
      Co-authored-by: default avatarSebastian Kunert <[email protected]>
      945ebbbc
    • Alexandru Vasile's avatar
      rpc/client: Propagate `rpc_methods` method to reported methods (#1713) · b5a0708f
      Alexandru Vasile authored
      
      
      The PR exposes the `rpc_methods` name in the `rpc_methods` response.
      This feature is useful for servers that only forward requests to methods
      that are reported by the `rpc_methods`.
      
      Jsonrpsee exposes the available methods registered so far. Registering
      the `rpc_methods` requires a closure that already stores the result. As
      such, the `rpc_methods` method name is manually added to the available
      methods.
      
      Closes: https://github.com/paritytech/polkadot-sdk/issues/1627
      
      ### Testing Done
      
      ```
      $> curl -H "Content-Type: application/json" -d '{"id":1, "jsonrpc":"2.0", "method": "rpc_methods", "params":[]}' http://localhost:9944
      
      {"jsonrpc":"2.0","result":{"methods":["account_nextIndex",... "rpc_methods",..."unsubscribe_newHead"]},"id":1}⏎
      ```
      
      @paritytech/subxt-team
      
      ---------
      
      Signed-off-by: default avatarAlexandru Vasile <[email protected]>
      b5a0708f
    • Michal Kucharczyk's avatar
      rococo-runtime: `RococoGenesisExt` removed (#1490) · 50242a61
      Michal Kucharczyk authored
      [`RococoGenesisExt`](https://github.com/paritytech/polkadot-sdk/blob/a414ea75
      
      /polkadot/node/service/src/chain_spec.rs#L152-L171)
      is removed. It was the hack to allow overwriting
      `EpochDurationInBlocks`. Removal of `RococGenesisExt` prevents from
      manipulating the state to change the runtime constants.
      
      Changes:
      - Environment variable which controls the `time::EpochDurationInBlocks`
      value was added: `ROCOCO_EPOCH_DURATION` (epoch duration will be set to
      the value of env),
      - `10,100,600` versions of rococo-runtime are built in CI and put into `polkadot-debug` docker image.
      
      `rococo-runtime` building examples:
      - to build runtime for `versi_staging_testnet` which had
      EpochDurationInBlocks set to 100:
        ```
      ROCOCO_EPOCH_DURATION=100 cargo build --features=fast-runtime -p
      rococo-runtime
        ```
      - to build runtime for `wococo_development`
        ```
      ROCOCO_EPOCH_DURATION=10 cargo build --features=fast-runtime -p
      rococo-runtime
        ```
      - to build `versi-staging` chain spec:
        ```
      ROCOCO_EPOCH_DURATION=100 cargo run -p polkadot --features=fast-runtime
      -- build-spec --chain versi-staging --raw
        ```
      - to build `wococo-dev` chain spec:
        ```
      ROCOCO_EPOCH_DURATION=10 cargo run -p polkadot --features=fast-runtime
      -- build-spec --chain wococo-dev --raw
        ```
      
      It is also possible to change the epoch duration by replacing the `code` field in the chain spec with the hex dump of pre-built runtime wasm blob (because the epoch duration is hard-coded into wasm blob).
      
      ---------
      
      Co-authored-by: default avatarBastian Köcher <[email protected]>
      50242a61
    • Marcin S.'s avatar
      PVF: more filesystem sandboxing (#1373) · c1eb342b
      Marcin S. authored
      c1eb342b
    • Xavier Lau's avatar
      Add `MaxTipAmount` for pallet-tips (#1709) · de71fecc
      Xavier Lau authored
      Last week we experienced a governance attack.
      Surprisingly, there was no upper limit on the tip amount.
      
      Due to the mechanism of pallet-fragment-election, the council members
      will be refreshed immediately. Attacker is easy to control the council
      and give a large tip amount.
      de71fecc
    • Xiliang Chen's avatar
      add some events for pallet-bounties (#1706) · b50d8e6f
      Xiliang Chen authored
      Add missing events for pallet-bounties
      b50d8e6f
    • Javyer's avatar
      Added `review-bot` to fine tune review requirements (#1673) · 4384c613
      Javyer authored
      Created a Github Action that uses the [Review-Bot
      app](https://github.com/paritytech/review-bot) to require more fine
      tuned requirements to review pull requests before allowing the PR to be
      merged.
      
      This uses
      [`pull_request_target`](https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#pull_request_target)
      for the event, not `pull_request`. This is a security measure so that an
      attacker doesn’t have access to the secrets.
      
      All the rules have been copied from the original
      `.github/pr-custom-review.yml` file.
      
      I want to clarify, this particular commit is **not intended to replace
      PRCR yet**.
      
      # Advantages it brings over `PRCR`
      
      Most of the features available in `PRCR` have been duplicated and
      enhanced. For a complete detailed write up, please see:
      - paritytech/pr-custom-review#114 -> Proposal for the rewrite
      - [Review Bot
      Documentation](https://github.com/paritytech/review-bot/blob/main/README.md)
      
      The most important features are:
      - `include` and `exclude` fields now accept an array, making it easier
      to read the regular expressions.
      - Ability to skip a rule
      - We can set that PRs coming from a particular user or team will cause
      the rule to be skipped.
      - This is used in the `Audit rule`, which was requested by
      @the-right-joyce.
        - This resolves paritytech/pr-custom-review#136
      - Ability to request fellows instead of teams
      - As requested in polkadot-fellows/runtimes#7, this bot has the ability
      to request fellows by rank instead of users.
      - We currently have polkadot-fellows/runtimes#31 which is using that
      feature.
      
      Aside from all the rules available in `PRCR` I have added a particular
      rule to lock the review-bot files and require a review from the
      `locks-review` team, the @paritytech/ci team and the
      @paritytech/opstooling team to ensure that the file has been written
      correctly.
      
      ## Next steps
      
      The next steps will consist on paritytech/review-bot#53, once this issue
      has been resolved, and `review-bot` has worked without any issues on
      this repository for a while, we will upgrade it to be able to fully
      replace `PRCR`.
      4384c613
    • Dónal Murray's avatar
      Add event field names to HRMP Event variants (#1695) · 4bc97e48
      Dónal Murray authored
      Update the HRMP pallet to use field names for Event variants to improve
      metadata for a better client experience.
      Event variants are now structs instead of unnamed tuples.
      
      Partially implements Substrate issue
      [9903](https://github.com/paritytech/substrate/issues/9903) which
      doesn't appear to have been moved to the monorepo.
      4bc97e48
    • eskimor's avatar
      Fix #1417 · b7324041
      eskimor authored
      b7324041
    • eskimor's avatar
      Typechecks. · 5fdb52ff
      eskimor authored
      5fdb52ff
  9. Sep 27, 2023