Skip to content

Commit ef3b2da

Browse files
committed
Import Polkadot
Signed-off-by: alvicsam <[email protected]>
2 parents a37e3f2 + 3cdfde8 commit ef3b2da

File tree

1,179 files changed

+354108
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,179 files changed

+354108
-0
lines changed

polkadot/.cargo/config.toml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
#
2+
# An auto defined `clippy` feature was introduced,
3+
# but it was found to clash with user defined features,
4+
# so was renamed to `cargo-clippy`.
5+
#
6+
# If you want standard clippy run:
7+
# RUSTFLAGS= cargo clippy
8+
[target.'cfg(feature = "cargo-clippy")']
9+
rustflags = [
10+
"-Aclippy::all",
11+
"-Dclippy::correctness",
12+
"-Aclippy::if-same-then-else",
13+
"-Aclippy::clone-double-ref",
14+
"-Dclippy::complexity",
15+
"-Aclippy::zero-prefixed-literal", # 00_1000_000
16+
"-Aclippy::type_complexity", # raison d'etre
17+
"-Aclippy::nonminimal-bool", # maybe
18+
"-Aclippy::borrowed-box", # Reasonable to fix this one
19+
"-Aclippy::too-many-arguments", # (Turning this on would lead to)
20+
"-Aclippy::unnecessary_cast", # Types may change
21+
"-Aclippy::identity-op", # One case where we do 0 +
22+
"-Aclippy::useless_conversion", # Types may change
23+
"-Aclippy::unit_arg", # styalistic.
24+
"-Aclippy::option-map-unit-fn", # styalistic
25+
"-Aclippy::bind_instead_of_map", # styalistic
26+
"-Aclippy::erasing_op", # E.g. 0 * DOLLARS
27+
"-Aclippy::eq_op", # In tests we test equality.
28+
"-Aclippy::while_immutable_condition", # false positives
29+
"-Aclippy::needless_option_as_deref", # false positives
30+
"-Aclippy::derivable_impls", # false positives
31+
"-Aclippy::stable_sort_primitive", # prefer stable sort
32+
"-Aclippy::extra-unused-type-parameters", # stylistic
33+
]

polkadot/.dockerignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
doc
2+
**/target

polkadot/.editorconfig

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
root = true
2+
3+
[*.rs]
4+
indent_style=tab
5+
indent_size=tab
6+
tab_width=4
7+
max_line_length=120
8+
end_of_line=lf
9+
charset=utf-8
10+
trim_trailing_whitespace=true
11+
insert_final_newline=true
12+
13+
[*.yml]
14+
indent_style=space
15+
indent_size=2
16+
tab_width=8
17+
end_of_line=lf
18+
charset=utf-8
19+
trim_trailing_whitespace=true
20+
insert_final_newline=true
21+
22+
[*.sh]
23+
indent_style=space
24+
indent_size=2
25+
tab_width=8
26+
end_of_line=lf

polkadot/.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/.gitlab-ci.yml filter=ci-prettier
2+
/scripts/ci/gitlab/pipeline/*.yml filter=ci-prettier

polkadot/.github/CODEOWNERS

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# CI
2+
/.github/ @paritytech/ci @chevdor
3+
/scripts/ci/ @paritytech/ci @chevdor
4+
/.gitlab-ci.yml @paritytech/ci
5+
# lingua.dic is not managed by CI team
6+
/scripts/ci/gitlab/lingua.dic
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: ''
6+
assignees: ''
7+
8+
---
9+
10+
- It would help if you submit info about the system you are running, e.g.: operating system, kernel version, amount of available memory and swap, etc.
11+
- Logs could be very helpful. If possible, submit the whole log. Please format it as ```code blocks```.
12+
- Describe the role your node plays, e.g. validator, full node or light client.
13+
- Any command-line options were passed?
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
---
2+
name: Release issue template
3+
about: Tracking issue for new releases
4+
title: Polkadot {{ env.VERSION }} Release checklist
5+
---
6+
# Release Checklist
7+
8+
This is the release checklist for Polkadot {{ env.VERSION }}. **All** following
9+
checks should be completed before publishing a new release of the
10+
Polkadot/Kusama/Westend/Rococo runtime or client. The current release candidate can be
11+
checked out with `git checkout release-{{ env.VERSION }}`
12+
13+
### Runtime Releases
14+
15+
These checks should be performed on the codebase prior to forking to a release-
16+
candidate branch.
17+
18+
- [ ] Verify [`spec_version`](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#spec-version) has been incremented since the
19+
last release for any native runtimes from any existing use on public
20+
(non-private) networks. If the runtime was published (release or pre-release), either
21+
the `spec_version` or `impl` must be bumped.
22+
- [ ] Verify previously [completed migrations](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#old-migrations-removed) are
23+
removed for any public (non-private/test) networks.
24+
- [ ] Verify pallet and [extrinsic ordering](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#extrinsic-ordering) has stayed
25+
the same. Bump `transaction_version` if not.
26+
- [ ] Verify new extrinsics have been correctly whitelisted/blacklisted for
27+
[proxy filters](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#proxy-filtering).
28+
- [ ] Verify [benchmarks](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#benchmarks) have been updated for any modified
29+
runtime logic.
30+
31+
The following checks can be performed after we have forked off to the release-
32+
candidate branch or started an additional release candidate branch (rc-2, rc-3, etc)
33+
34+
- [ ] Verify [new migrations](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#new-migrations) complete successfully, and the
35+
runtime state is correctly updated for any public (non-private/test)
36+
networks.
37+
- [ ] Verify [Polkadot JS API](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#polkadot-js) are up to date with the latest
38+
runtime changes.
39+
- [ ] Check with the Signer's team to make sure metadata update QR are lined up
40+
- [ ] Push runtime upgrade to Westend and verify network stability.
41+
42+
### All Releases
43+
44+
- [ ] Check that the new client versions have [run on the network](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#burn-in)
45+
without issue for 12+ hours on >75% of our validator nodes.
46+
- [ ] Check that a draft release has been created at
47+
https://github.com/paritytech/polkadot/releases with relevant [release
48+
notes](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#release-notes)
49+
- [ ] Check that [build artifacts](https://github.com/paritytech/polkadot/blob/master/doc/release-checklist.md#build-artifacts) have been added to the
50+
draft-release
51+
- [ ] Check that all items listed in the [milestone](https://github.com/paritytech/polkadot/milestones) are included in the release.
52+
- [ ] Ensure that no `freenotes` were added into the release branch after the latest generated RC

polkadot/.github/dependabot.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "cargo"
4+
directory: "/"
5+
labels: ["A2-insubstantial", "B0-silent", "C1-low", "E2-dependencies"]
6+
# Handle updates for crates from github.com/paritytech/substrate manually.
7+
ignore:
8+
- dependency-name: "substrate-*"
9+
- dependency-name: "sc-*"
10+
- dependency-name: "sp-*"
11+
- dependency-name: "frame-*"
12+
- dependency-name: "fork-tree"
13+
- dependency-name: "frame-remote-externalities"
14+
- dependency-name: "pallet-*"
15+
- dependency-name: "beefy-*"
16+
- dependency-name: "try-runtime-*"
17+
- dependency-name: "test-runner"
18+
- dependency-name: "generate-bags"
19+
- dependency-name: "sub-tokens"
20+
schedule:
21+
interval: "daily"
22+
- package-ecosystem: github-actions
23+
directory: '/'
24+
labels: ["A2-insubstantial", "B0-silent", "C1-low", "E2-dependencies"]
25+
schedule:
26+
interval: daily
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# 🔒 PROTECTED: Changes to locks-review-team should be approved by the current locks-review-team
2+
locks-review-team: locks-review
3+
team-leads-team: polkadot-review
4+
action-review-team: ci
5+
6+
rules:
7+
- name: Runtime files
8+
check_type: changed_files
9+
condition:
10+
include: ^runtime\/(kusama|polkadot)\/src\/.+\.rs$
11+
exclude: ^runtime\/(kusama|polkadot)\/src\/weights\/.+\.rs$
12+
all_distinct:
13+
- min_approvals: 1
14+
teams:
15+
- locks-review
16+
- min_approvals: 1
17+
teams:
18+
- polkadot-review
19+
20+
- name: Core developers
21+
check_type: changed_files
22+
condition:
23+
include: .*
24+
# excluding files from 'Runtime files' and 'CI files' rules
25+
exclude: ^runtime/(kusama|polkadot)/src/[^/]+\.rs$|^\.gitlab-ci\.yml|^(?!.*\.dic$|.*spellcheck\.toml$)scripts/ci/.*|^\.github/.*
26+
min_approvals: 3
27+
teams:
28+
- core-devs
29+
30+
- name: CI files
31+
check_type: changed_files
32+
condition:
33+
# dictionary files are excluded
34+
include: ^\.gitlab-ci\.yml|^(?!.*\.dic$|.*spellcheck\.toml$)scripts/ci/.*|^\.github/.*
35+
min_approvals: 2
36+
teams:
37+
- ci
38+
- release-engineering
39+
40+
prevent-review-request:
41+
teams:
42+
- core-devs
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Notify devops when burn-in label applied
2+
on:
3+
pull_request:
4+
types: [labeled]
5+
6+
jobs:
7+
notify-devops:
8+
runs-on: ubuntu-latest
9+
strategy:
10+
matrix:
11+
channel:
12+
- name: 'Team: DevOps'
13+
room: '!lUslSijLMgNcEKcAiE:parity.io'
14+
15+
steps:
16+
- name: Send Matrix message to ${{ matrix.channel.name }}
17+
if: startsWith(github.event.label.name, 'A1-')
18+
uses: s3krit/matrix-message-action@70ad3fb812ee0e45ff8999d6af11cafad11a6ecf # v0.0.3
19+
with:
20+
room_id: ${{ matrix.channel.room }}
21+
access_token: ${{ secrets.RELEASENOTES_MATRIX_V2_ACCESS_TOKEN }}
22+
server: m.parity.io
23+
message: |
24+
@room Burn-in request received for the following PR: ${{ github.event.pull_request.html_url }}

0 commit comments

Comments
 (0)