Skip to content

Commit

Permalink
build: t0rn dry run deploy preparation (t3rn#625)
Browse files Browse the repository at this point in the history
* build: v1.2.0-rc.5 release preparation

* build: update comment on GHA tag match

Co-authored-by: Don <37594653+AwesomeIbex@users.noreply.github.com>
  • Loading branch information
3h4x and dndll committed Feb 13, 2023
1 parent 42ecdf5 commit c0c602b
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 16 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/release-t0rn.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ name: t0rn Rococo Release
on:
push:
tags:
- "v[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+"
# This is a GLOB not a regex. Don't add escape sequences to me
- "v[0-9]+.[0-9]+.[0-9]+-rc.[0-9]+"

env:
PARACHAIN_NAME: t0rn
Expand Down
6 changes: 2 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
# Changelog
## [1.2.1-rc.1](https://github.com/t3rn/t3rn/compare/v1.2.0-rc.11...v1.2.1-rc.1) (2023-01-31)

## `v1.2.0-rc.5` 2023-02-01
* fix: loosen collators config MaxCandidate and SessionTime
## `v1.2.0-rc.5` 2023-02-06
* fix: t0rn runtime upgrade


### Bug Fixes
Expand Down
22 changes: 11 additions & 11 deletions scripts/upgrade-runtime-unsafe.sh
Original file line number Diff line number Diff line change
Expand Up @@ -108,14 +108,14 @@ fi
echo "🫧 Check WASM artifact..."
wasm_hash_calculated=$(subwasm info --json $used_wasm | jq -r .blake2_256)
wasm_hash_fetched="$(cat ${used_wasm}.blake2_256)"
echo "🔢 calculated WASM hash is $wasm_hash_calculated"
echo "🔢 fetched WASM hash from release is $wasm_hash_fetched"
echo "🔢 calculated WASM blake2_256 hash is $wasm_hash_calculated"
echo "🔢 fetched WASM blake2_256 hash from release is $wasm_hash_fetched"

if [[ "$wasm_hash_calculated" -ne "$wasm_hash_fetched" ]]; then
echo "🔴 WASM artifact hash is not matching"
echo "🔴 WASM artifact blake2_256 hash is not matching"
exit 1
else
echo "✅ WASM artifact hash is matching"
echo "✅ WASM artifact blake2_256 hash is matching"
fi

# Unsafe runtime upgrade script assumes below are checked.
Expand All @@ -141,9 +141,6 @@ echo "🎱 authorizing runtime upgrade... $dryrun"
# TODO: update
npm i @polkadot/api@8.6.2

#TODO: remove when confident
exit 1

if [[ -z $dryrun ]]; then
PROVIDER=$ws_provider SUDO=$sudo_secret HASH=$hash WHEN=$when \
node $root_dir/scripts/schedule-authorize-runtime-upgrade.js
Expand All @@ -161,10 +158,13 @@ echo "🛂 awaiting runtime upgrade authorization..."

head=$(get_finalized_head)

while [[ $head -ne $when ]]; do
sleep 12
head=$(get_finalized_head)
done
# Skip waiting if run with dryrun flag
if [[ -z $dryrun ]]; then
while [[ $head -ne $when ]]; do
sleep 12
head=$(get_finalized_head)
done
fi

echo "⚙️ enacting runtime upgrade... $dryrun"

Expand Down

0 comments on commit c0c602b

Please sign in to comment.