Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set Protocol Upgrade heights for CERES #4333

Merged
merged 2 commits into from Apr 18, 2024
Merged

Set Protocol Upgrade heights for CERES #4333

merged 2 commits into from Apr 18, 2024

Conversation

hanssv
Copy link
Member

@hanssv hanssv commented Apr 17, 2024

TESTNET

Starting point: 10/4 at 9:30 CEST: 933010
Hard Fork: 24/4 at 10:30 CEST: 933010 + 14 * 20 * 24 + 20 = 939750

MAINNET

Starting point: 10/4 at 9:30 CEST: 928760
Hard Fork: 7/5 at 11:00 CEST: 928760 + 27 * 20 * 24 + 30 = 941750

This PR is supported by the Æternity Foundation

Mainnet: 941750
Testnet: 939750
@dincho
Copy link
Member

dincho commented Apr 18, 2024

Could you also add estimated dates please

@dincho
Copy link
Member

dincho commented Apr 18, 2024

Testnet:

#!/bin/bash

BASE_BLOCK=933010
BASE_TS=$(($(curl -s https://testnet.aeternity.io/v3/key-blocks/height/$BASE_BLOCK | jq '.time')/1000))
echo "Base block datetime:" $(date -jur $BASE_TS)

TARGET_TS=$(date -ju -f "%Y-%m-%d %H:%M:%S" '2024-04-24 08:30:00' +%s)
echo "Target timestamp:" $TARGET_TS

OFFSET_TS=$(($TARGET_TS-$BASE_TS))
BLOCKTIME_TS=180
OFFSET_BLOCKS=$(($OFFSET_TS/$BLOCKTIME_TS))
echo "Offset blocks:" $OFFSET_BLOCKS
echo "Target block:" $(($BASE_BLOCK + $OFFSET_BLOCKS))

Output:

Base block datetime: Wed Apr 10 07:35:27 UTC 2024
Target timestamp: 1713947400
Offset blocks: 6738
Target block: 939748

Mainnet:

#!/bin/bash

BASE_BLOCK=928760
BASE_TS=$(($(curl -s https://mainnet.aeternity.io/v3/key-blocks/height/$BASE_BLOCK | jq '.time')/1000))
echo "Base block datetime:" $(date -jur $BASE_TS)

TARGET_TS=$(date -ju -f "%Y-%m-%d %H:%M:%S" '2024-05-07 09:00:00' +%s)
echo "Target timestamp:" $TARGET_TS

OFFSET_TS=$(($TARGET_TS-$BASE_TS))
BLOCKTIME_TS=180
OFFSET_BLOCKS=$(($OFFSET_TS/$BLOCKTIME_TS))
echo "Offset blocks:" $OFFSET_BLOCKS
echo "Target block:" $(($BASE_BLOCK + $OFFSET_BLOCKS))

Output:

Base block datetime: Wed Apr 10 07:32:12 UTC 2024
Target timestamp: 1715072400
Offset blocks: 12989
Target block: 941749

@dincho
Copy link
Member

dincho commented Apr 18, 2024

Mainnet from current block is 41 blocks off already (2h), maybe we should tune a bit.

Base block datetime: Thu Apr 18 11:18:41 UTC 2024
Target timestamp: 1715072400
Offset blocks: 9073
Target block: 941708

But testnet is fine:

Base block datetime: Thu Apr 18 11:34:57 UTC 2024
Target timestamp: 1713949200
Offset blocks: 2828
Target block: 939751

dincho
dincho previously approved these changes Apr 18, 2024
@hanssv
Copy link
Member Author

hanssv commented Apr 18, 2024

Let me adjust to 941700 for mainnet?

@hanssv hanssv merged commit 387efb5 into master Apr 18, 2024
38 checks passed
@hanssv hanssv deleted the ceres_hf_heights branch April 18, 2024 12:45
@dincho dincho added the breaking/consensus Consensus breaking change label Apr 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking/consensus Consensus breaking change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants