Skip to content

Commit

Permalink
Merge branch 'master' into dev-accounts
Browse files Browse the repository at this point in the history
  • Loading branch information
runcomet authored Jan 20, 2025
2 parents 9b03b46 + 2c4cecc commit cf8e875
Show file tree
Hide file tree
Showing 169 changed files with 8,821 additions and 2,257 deletions.
4 changes: 2 additions & 2 deletions .github/scripts/generate-prdoc.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,10 @@ def create_prdoc(pr, audience, title, description, patch, bump, force):
if p == '/':
exit(1)
p = os.path.dirname(p)

with open(os.path.join(p, "Cargo.toml")) as f:
manifest = toml.load(f)

if not "package" in manifest:
continue

Expand Down
47 changes: 24 additions & 23 deletions .github/workflows/build-publish-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
- name: pack artifacts
run: |
mkdir -p ./artifacts
VERSION="${{ needs.preflight.outputs.SOURCE_REF_NAME }}" # will be tag or branch name
VERSION="${{ needs.preflight.outputs.SOURCE_REF_SLUG }}" # will be tag or branch name
mv ./target/testnet/polkadot ./artifacts/.
mv ./target/testnet/polkadot-prepare-worker ./artifacts/.
mv ./target/testnet/polkadot-execute-worker ./artifacts/.
Expand All @@ -62,7 +62,7 @@ jobs:
sha256sum polkadot | tee polkadot.sha256
shasum -c polkadot.sha256
cd ../
EXTRATAG="${{ needs.preflight.outputs.SOURCE_REF_NAME }}-${COMMIT_SHA}"
EXTRATAG="${{ needs.preflight.outputs.SOURCE_REF_SLUG }}-${COMMIT_SHA}"
echo "Polkadot version = ${VERSION} (EXTRATAG = ${EXTRATAG})"
echo -n ${VERSION} > ./artifacts/VERSION
echo -n ${EXTRATAG} > ./artifacts/EXTRATAG
Expand All @@ -77,7 +77,7 @@ jobs:
- name: upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
path: artifacts.tar
retention-days: 1

Expand All @@ -103,15 +103,15 @@ jobs:
mkdir -p ./artifacts
mv ./target/release/polkadot-parachain ./artifacts/.
echo "___The VERSION is either a tag name or the curent branch if triggered not by a tag___"
echo ${{ needs.preflight.outputs.SOURCE_REF_NAME }} | tee ./artifacts/VERSION
echo ${{ needs.preflight.outputs.SOURCE_REF_SLUG }} | tee ./artifacts/VERSION
- name: tar
run: tar -cvf artifacts.tar artifacts

- name: upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
path: artifacts.tar
retention-days: 1

Expand Down Expand Up @@ -147,7 +147,7 @@ jobs:
- name: upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
path: artifacts.tar
retention-days: 1

Expand All @@ -172,8 +172,8 @@ jobs:
mkdir -p ./artifacts
mv ./target/testnet/adder-collator ./artifacts/.
mv ./target/testnet/undying-collator ./artifacts/.
echo -n "${{ needs.preflight.outputs.SOURCE_REF_NAME }}" > ./artifacts/VERSION
echo -n "${{ needs.preflight.outputs.SOURCE_REF_NAME }}-${COMMIT_SHA}" > ./artifacts/EXTRATAG
echo -n "${{ needs.preflight.outputs.SOURCE_REF_SLUG }}" > ./artifacts/VERSION
echo -n "${{ needs.preflight.outputs.SOURCE_REF_SLUG }}-${COMMIT_SHA}" > ./artifacts/EXTRATAG
echo "adder-collator version = $(cat ./artifacts/VERSION) (EXTRATAG = $(cat ./artifacts/EXTRATAG))"
echo "undying-collator version = $(cat ./artifacts/VERSION) (EXTRATAG = $(cat ./artifacts/EXTRATAG))"
cp -r ./docker/* ./artifacts
Expand All @@ -184,7 +184,7 @@ jobs:
- name: upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
path: artifacts.tar
retention-days: 1

Expand All @@ -209,8 +209,8 @@ jobs:
mv ./target/testnet/malus ./artifacts/.
mv ./target/testnet/polkadot-execute-worker ./artifacts/.
mv ./target/testnet/polkadot-prepare-worker ./artifacts/.
echo -n "${{ needs.preflight.outputs.SOURCE_REF_NAME }}" > ./artifacts/VERSION
echo -n "${{ needs.preflight.outputs.SOURCE_REF_NAME }}-${COMMIT_SHA}" > ./artifacts/EXTRATAG
echo -n "${{ needs.preflight.outputs.SOURCE_REF_SLUG }}" > ./artifacts/VERSION
echo -n "${{ needs.preflight.outputs.SOURCE_REF_SLUG }}-${COMMIT_SHA}" > ./artifacts/EXTRATAG
echo "polkadot-test-malus = $(cat ./artifacts/VERSION) (EXTRATAG = $(cat ./artifacts/EXTRATAG))"
cp -r ./docker/* ./artifacts
Expand All @@ -220,7 +220,7 @@ jobs:
- name: upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
path: artifacts.tar
retention-days: 1

Expand All @@ -246,6 +246,7 @@ jobs:
WASM_BUILD_NO_COLOR=1 forklift cargo build --locked --release -p staging-node-cli
ls -la target/release/
- name: pack artifacts
shell: bash
run: |
mv target/release/substrate-node ./artifacts/substrate/substrate
echo -n "Substrate version = "
Expand All @@ -264,7 +265,7 @@ jobs:
- name: upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
path: artifacts.tar
retention-days: 1

Expand Down Expand Up @@ -294,7 +295,7 @@ jobs:
- name: upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: ${{ github.job }}-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
path: artifacts.tar
retention-days: 1

Expand All @@ -313,7 +314,7 @@ jobs:

- uses: actions/[email protected]
with:
name: build-test-parachain-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: build-test-parachain-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}

- name: tar
run: tar -xvf artifacts.tar
Expand All @@ -337,7 +338,7 @@ jobs:

- uses: actions/[email protected]
with:
name: build-linux-stable-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: build-linux-stable-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}

- name: tar
run: tar -xvf artifacts.tar
Expand All @@ -361,7 +362,7 @@ jobs:

- uses: actions/[email protected]
with:
name: build-test-collators-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: build-test-collators-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}

- name: tar
run: tar -xvf artifacts.tar
Expand All @@ -385,7 +386,7 @@ jobs:

- uses: actions/[email protected]
with:
name: build-malus-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: build-malus-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}

- name: tar
run: tar -xvf artifacts.tar
Expand All @@ -409,7 +410,7 @@ jobs:

- uses: actions/[email protected]
with:
name: build-linux-substrate-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: build-linux-substrate-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}

- name: tar
run: tar -xvf artifacts.tar
Expand Down Expand Up @@ -441,23 +442,23 @@ jobs:

- uses: actions/[email protected]
with:
name: build-linux-stable-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: build-linux-stable-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
- name: tar
run: |
tar -xvf artifacts.tar
rm artifacts.tar
- uses: actions/[email protected]
with:
name: build-linux-stable-cumulus-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: build-linux-stable-cumulus-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
- name: tar
run: |
tar -xvf artifacts.tar
rm artifacts.tar
- uses: actions/[email protected]
with:
name: prepare-bridges-zombienet-artifacts-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: prepare-bridges-zombienet-artifacts-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}
- name: tar
run: |
tar -xvf artifacts.tar
Expand All @@ -482,7 +483,7 @@ jobs:

- uses: actions/[email protected]
with:
name: build-linux-stable-cumulus-${{ needs.preflight.outputs.SOURCE_REF_NAME }}
name: build-linux-stable-cumulus-${{ needs.preflight.outputs.SOURCE_REF_SLUG }}

- name: tar
run: tar -xvf artifacts.tar
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/check-semver.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ jobs:
- name: install parity-publish
if: ${{ !contains(github.event.pull_request.labels.*.name, 'R0-silent') }}
# Set the target dir to cache the build.
run: CARGO_TARGET_DIR=./target/ cargo install [email protected].3 --locked -q
run: CARGO_TARGET_DIR=./target/ cargo install [email protected].4 --locked -q

- name: check semver
if: ${{ !contains(github.event.pull_request.labels.*.name, 'R0-silent') }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/command-inform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
comment:
runs-on: ubuntu-latest
# Temporary disable the bot until the new command bot works properly
if: github.event.issue.pull_request && startsWith(github.event.comment.body, 'bot ') && false # disabled for now, until tested
if: github.event.issue.pull_request && startsWith(github.event.comment.body, 'bot ')
steps:
- name: Inform that the new command exist
uses: actions/github-script@v7
Expand All @@ -18,5 +18,5 @@ jobs:
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: 'We have migrated the command bot to GHA<br/><br/>Please, see the new usage instructions <a href="https://github.com/paritytech/polkadot-sdk/blob/master/docs/contributor/commands-readme.md">here</a>. Soon the old commands will be disabled.'
})
body: 'We have migrated the command bot to GHA<br/><br/>Please, see the new usage instructions <a href="https://github.com/paritytech/polkadot-sdk/blob/master/docs/contributor/commands-readme.md">here</a> or <a href="https://forum.parity.io/t/streamlining-weight-generation-and-more-the-new-cmd-bot/2411">here</a>. Soon the old commands will be disabled.'
})
6 changes: 6 additions & 0 deletions .github/workflows/misc-sync-templates.yml
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,12 @@ jobs:
- name: Copy over the new changes
run: |
cp -r polkadot-sdk/templates/${{ matrix.template }}/* "${{ env.template-path }}/"
- name: Remove unnecessary files from parachain template
if: ${{ matrix.template == 'parachain' }}
run: |
rm -f "${{ env.template-path }}/README.docify.md"
rm -f "${{ env.template-path }}/Cargo.toml"
rm -f "${{ env.template-path }}/src/lib.rs"
- name: Run psvm on monorepo workspace dependencies
run: psvm -o -v ${{ github.event.inputs.stable_release_branch }} -p ./Cargo.toml
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/publish-check-compile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,14 @@ jobs:
- uses: actions/checkout@6d193bf28034eafb982f37bd894289fe649468fc # v4.1.7

- name: Rust Cache
uses: Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab # v2.7.5
uses: Swatinem/rust-cache@f0deed1e0edfc6a9be95417288c0e1099b1eeec3 # v2.7.7
with:
cache-on-failure: true

- name: install parity-publish
run: cargo install [email protected] --locked -q
run: |
rustup override set 1.82.0
cargo install [email protected] --locked -q
- name: parity-publish update plan
run: parity-publish --color always plan --skip-check --prdoc prdoc/
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish-check-crates.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ jobs:
- uses: actions/checkout@6d193bf28034eafb982f37bd894289fe649468fc # v4.1.7

- name: Rust Cache
uses: Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab # v2.7.5
uses: Swatinem/rust-cache@f0deed1e0edfc6a9be95417288c0e1099b1eeec3 # v2.7.7
with:
cache-on-failure: true

- name: install parity-publish
run: cargo install [email protected].3 --locked -q
run: cargo install [email protected].4 --locked -q

- name: parity-publish check
run: parity-publish --color always check --allow-unpublished
4 changes: 2 additions & 2 deletions .github/workflows/publish-claim-crates.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ jobs:
- uses: actions/checkout@6d193bf28034eafb982f37bd894289fe649468fc # v4.1.7

- name: Rust Cache
uses: Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab # v2.7.5
uses: Swatinem/rust-cache@f0deed1e0edfc6a9be95417288c0e1099b1eeec3 # v2.7.7
with:
cache-on-failure: true

- name: install parity-publish
run: cargo install [email protected].3 --locked -q
run: cargo install [email protected].4 --locked -q

- name: parity-publish claim
env:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/review-bot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
with:
artifact-name: pr_number
- name: "Evaluates PR reviews and assigns reviewers"
uses: paritytech/review-bot@v2.6.0
uses: paritytech/review-bot@v2.7.0
with:
repo-token: ${{ steps.app_token.outputs.token }}
team-token: ${{ steps.app_token.outputs.token }}
Expand Down
Loading

0 comments on commit cf8e875

Please sign in to comment.