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

chore(protocol): update Alpha-3 protocol configurations #13806

Merged
merged 7 commits into from
May 26, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions packages/protocol/contracts/L1/TaikoConfig.sol
Original file line number Diff line number Diff line change
Expand Up @@ -11,23 +11,23 @@ import {TaikoData} from "../L1/TaikoData.sol";
library TaikoConfig {
function getConfig() internal pure returns (TaikoData.Config memory) {
return TaikoData.Config({
chainId: 167,
// Two weeks if avg block time is 10 seconds
maxNumProposedBlocks: 120960,
ringBufferSize: 120960 + 10,
chainId: 167005,
// Two weeks if avg block time is 3 seconds (is it reasonable?)
dantaik marked this conversation as resolved.
Show resolved Hide resolved
maxNumProposedBlocks: 403200,
ringBufferSize: 403200 + 10,
// Each time one more block is verified, there will be ~20k
// more gas cost.
maxVerificationsPerTx: 10,
// Set it to 6M, since its the upper limit of the Alpha-2
// Set it to 6M, since its the upper limit of the Alpha-3
// testnet's circuits.
blockMaxGasLimit: 6000000,
// Set it to 79 (+1 TaikoL2.anchor transaction = 80),
// and 80 is the upper limit of the Alpha-2 testnet's circuits.
// and 80 is the upper limit of the Alpha-3 testnet's circuits.
maxTransactionsPerBlock: 79,
minEthDepositsPerBlock: 8,
maxEthDepositsPerBlock: 32,
maxEthDepositAmount: 10000 ether,
minEthDepositAmount: 1 ether,
minEthDepositAmount: 0.1 ether,
// Set it to 120KB, since 128KB is the upper size limit
// of a geth transaction, so using 120KB for the proposed
// transactions list calldata, 8K for the remaining tx fields.
Expand Down
4 changes: 2 additions & 2 deletions packages/protocol/script/DeployOnL1.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ contract DeployOnL1 is Script {

address public sharedSignalService = vm.envAddress("SHARED_SIGNAL_SERVICE");

address public treasury = vm.envAddress("TREASURY");
address public treasury = vm.envAddress("TREASURY"); // Q: which address will we use?
davidtaikocha marked this conversation as resolved.
Show resolved Hide resolved

address public taikoTokenPremintRecipient = vm.envAddress("TAIKO_TOKEN_PREMINT_RECIPIENT");

Expand All @@ -49,7 +49,7 @@ contract DeployOnL1 is Script {
// For testnet it could be somewhere 85-100s
// For mainnet it could be around 1800 s (30mins)
// Can be adjusted later with setters
uint64 public INITIAL_PROOF_TIME_TARGET = uint64(vm.envUint("INITIAL_PROOF_TIME_TARGET"));
uint64 public INITIAL_PROOF_TIME_TARGET = uint64(vm.envUint("INITIAL_PROOF_TIME_TARGET")); // Q: INITIAL_PROOF_TIME_TARGET=`120s`? => initProofTimeIssued will be `49883`
dantaik marked this conversation as resolved.
Show resolved Hide resolved

TaikoL1 taikoL1;
address public addressManagerProxy;
Expand Down
2 changes: 1 addition & 1 deletion packages/protocol/script/DetermineNewProofTimeIssued.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import "forge-std/Script.sol";
import "forge-std/console2.sol";
import {LibLn} from "../test/LibLn.sol";

uint16 constant DESIRED_PROOF_TIME_TARGET = 500;
uint16 constant DESIRED_PROOF_TIME_TARGET = 120;
uint8 constant ADJUSTMENT_QUOTIENT = 16;

contract DetermineProofTimeIssued is Script {
Expand Down
8 changes: 4 additions & 4 deletions packages/protocol/test/genesis/test_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,10 @@
"SignalServiceProxy": "0x1000777700000000000000000000000000000007"
},
"param1559": {
"yscale": "358298803609133338137582400989",
"xscale": "1488514844",
"gasIssuedPerSecond": "12500000",
"gasExcess": "45450000000"
"yscale": "358298803609133338137582400989", // Q: do we need to change this?
dantaik marked this conversation as resolved.
Show resolved Hide resolved
"xscale": "1488514844", // Q: do we need to change this?
"gasIssuedPerSecond": "2000000", // If we assume the avg block time is 3s (is it reasonable?) , and each block is full (block.gasLimit=6m)
"gasExcess": "45450000000" // Q: do we need to change this?
dantaik marked this conversation as resolved.
Show resolved Hide resolved
},
"predeployERC20": true
}