diff --git a/CHANGELOG.md b/CHANGELOG.md index 58899e8f..9da4900f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # Changelog +## v1.21.0 +* Quebec protocol support + ## v1.19.2 * Update Parisnet hash * Update protocol history of ghostnet diff --git a/README.md b/README.md index 92013ba0..613688f2 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,8 @@ TzGo's main focus is on **correctness**, **stability**, and **compliance** with Current Tezos protocol support in TzGo +- Quebec v021 +- ParisC v020 - Paris v019 - Oxford v018 - Nairobi v017 diff --git a/tezos/params.go b/tezos/params.go index ef0cc56d..853a1f62 100644 --- a/tezos/params.go +++ b/tezos/params.go @@ -13,47 +13,32 @@ var ( // either overwrite this default or set custom params per operation using // op.WithParams(). DefaultParams = (&Params{ - MinimalBlockDelay: 10 * time.Second, + MinimalBlockDelay: 8 * time.Second, CostPerByte: 250, OriginationSize: 257, HardGasLimitPerOperation: 1040000, - HardGasLimitPerBlock: 1733333, + HardGasLimitPerBlock: 1386666, HardStorageLimitPerOperation: 60000, MaxOperationDataLength: 32768, - MaxOperationsTTL: 360, + MaxOperationsTTL: 450, }). WithChainId(Mainnet). - WithDeployment(Deployments[Mainnet].AtProtocol(ProtoV019)) + WithDeployment(Deployments[Mainnet].AtProtocol(ProtoV021)) // GhostnetParams defines the blockchain configuration for Ghostnet testnet. // To produce compliant transactions, use these defaults in op.WithParams(). GhostnetParams = (&Params{ - MinimalBlockDelay: 8 * time.Second, + MinimalBlockDelay: 4 * time.Second, CostPerByte: 250, OriginationSize: 257, HardGasLimitPerOperation: 1040000, - HardGasLimitPerBlock: 1733333, + HardGasLimitPerBlock: 1386666, HardStorageLimitPerOperation: 60000, MaxOperationDataLength: 32768, - MaxOperationsTTL: 360, + MaxOperationsTTL: 450, }). WithChainId(Ghostnet). - WithDeployment(Deployments[Ghostnet].AtProtocol(ProtoV019)) - - // ParisnetParams defines the blockchain configuration for Paris testnet. - // To produce compliant transactions, use these defaults in op.WithParams(). - ParisnetParams = (&Params{ - MinimalBlockDelay: 5 * time.Second, - CostPerByte: 250, - OriginationSize: 257, - HardGasLimitPerOperation: 1040000, - HardGasLimitPerBlock: 1733333, - HardStorageLimitPerOperation: 60000, - MaxOperationDataLength: 32768, - MaxOperationsTTL: 360, - }). - WithChainId(Parisnet). - WithDeployment(Deployments[Parisnet].AtProtocol(ProtoV019)) + WithDeployment(Deployments[Ghostnet].AtProtocol(ProtoV021)) ) // Params contains a subset of protocol configuration settings that are relevant @@ -111,10 +96,6 @@ func (p *Params) WithChainId(id ChainIdHash) *Params { p.Network = "Mainnet" case Ghostnet: p.Network = "Ghostnet" - case Parisnet: - p.Network = "Parisnet" - case ParisCnet: - p.Network = "ParisCnet" } } return p diff --git a/tezos/protocols.go b/tezos/protocols.go index 3152c290..a4fe4af5 100644 --- a/tezos/protocols.go +++ b/tezos/protocols.go @@ -27,6 +27,7 @@ var ( ProtoV018 = MustParseProtocolHash("ProxfordYmVfjWnRcgjWH36fW6PArwqykTFzotUxRs6gmTcZDuH") ProtoV019 = MustParseProtocolHash("PtParisBxoLz5gzMmn3d9WBQNoPSZakgnkMC2VNuQ3KXfUtUQeZ") ProtoV020 = MustParseProtocolHash("PsParisCZo7KAh1Z1smVd9ZMZ1HHn5gkzbM94V3PLCpknFWhUAi") + ProtoV021 = MustParseProtocolHash("PsQuebecnLByd3JwTiGadoG4nGWi3HYiLXUjkibeFV8dCFeVMUg") // aliases PtAthens = ProtoV004 @@ -46,11 +47,10 @@ var ( Proxford = ProtoV018 PtParisB = ProtoV019 PsParisC = ProtoV020 + PsQuebec = ProtoV021 - Mainnet = MustParseChainIdHash("NetXdQprcVkpaWU") - Ghostnet = MustParseChainIdHash("NetXnHfVqm9iesp") - Parisnet = MustParseChainIdHash("NetXR64bNAYkP4S") - ParisCnet = MustParseChainIdHash("NetXXWAHLEvre9b") + Mainnet = MustParseChainIdHash("NetXdQprcVkpaWU") + Ghostnet = MustParseChainIdHash("NetXnHfVqm9iesp") Versions = map[ProtocolHash]int{ ProtoGenesis: 0, @@ -75,7 +75,8 @@ var ( ProtoV018: 18, ProtoV019: 19, ProtoV020: 20, - ProtoAlpha: 21, + ProtoV021: 21, + ProtoAlpha: 22, } Deployments = map[ChainIdHash]ProtocolHistory{ @@ -101,32 +102,23 @@ var ( {PtNairobi, 0, 3760129, 5070848, 623, 5, 16384, 1024}, // v17 {Proxford, 0, 5070849, 5726208, 703, 5, 16384, 1024}, // v18 {PtParisB, 0, 5726209, 5898240, 743, 2, 24576, 24576}, // v19 - {PsParisC, 0, 5898241, -1, 750, 2, 24576, 24576}, // v19 + {PsParisC, 0, 5898241, 7692288, 750, 2, 24576, 24576}, // v20 + {PsQuebec, 0, 7692289, -1, 823, 2, 30720, 30720}, // v21 }, Ghostnet: { - {ProtoGenesis, 0, 0, 0, 0, 3, 4096, 256}, // 0 - {ProtoBootstrap, 0, 1, 1, 0, 3, 4096, 256}, // 0 - {PtHangz2, 2, 2, 8191, 0, 3, 4096, 256}, // v11 - {Psithaca, 0, 8192, 765952, 2, 3, 4096, 256}, // v12 - {PtJakart, 0, 765953, 1191936, 187, 3, 4096, 256}, // v13 - {PtKathma, 0, 1191937, 1654784, 291, 3, 4096, 256}, // v14 - {PtLimaPt, 0, 1654785, 2162688, 404, 3, 4096, 256}, // v15 - {PtMumbai, 0, 2162689, 2957312, 528, 3, 8192, 512}, // v16 - {PtNairobi, 0, 2957313, 5316608, 625, 3, 8192, 512}, // v17 - {Proxford, 0, 5316609, 6422528, 913, 3, 8192, 512}, // v18 - {PtParisB, 0, 6422529, 6729728, 1048, 2, 12288, 12288}, // v19 - {PsParisC, 0, 6729729, -1, 1073, 2, 12288, 12288}, // v19 - }, - Parisnet: { - {ProtoGenesis, 0, 0, 0, 0, 3, 8192, 512}, // 0 - {ProtoBootstrap, 0, 1, 1, 0, 3, 8192, 512}, // 0 - {Proxford, 2, 2, 8192, 0, 3, 8192, 512}, // v18 - {PtParisB, 0, 8193, -1, 1, 2, 12288, 12288}, // v19 - }, - ParisCnet: { - {ProtoGenesis, 0, 0, 0, 0, 3, 8192, 512}, // 0 - {ProtoBootstrap, 0, 1, 1, 0, 3, 8192, 512}, // 0 - {PsParisC, 2, 2, -1, 0, 2, 128, 128}, // v19 + {ProtoGenesis, 0, 0, 0, 0, 3, 4096, 256}, // 0 + {ProtoBootstrap, 0, 1, 1, 0, 3, 4096, 256}, // 0 + {PtHangz2, 2, 2, 8191, 0, 3, 4096, 256}, // v11 + {Psithaca, 0, 8192, 765952, 2, 3, 4096, 256}, // v12 + {PtJakart, 0, 765953, 1191936, 187, 3, 4096, 256}, // v13 + {PtKathma, 0, 1191937, 1654784, 291, 3, 4096, 256}, // v14 + {PtLimaPt, 0, 1654785, 2162688, 404, 3, 4096, 256}, // v15 + {PtMumbai, 0, 2162689, 2957312, 528, 3, 8192, 512}, // v16 + {PtNairobi, 0, 2957313, 5316608, 625, 3, 8192, 512}, // v17 + {Proxford, 0, 5316609, 6422528, 913, 3, 8192, 512}, // v18 + {PtParisB, 0, 6422529, 6729728, 1048, 2, 12288, 12288}, // v19 + {PsParisC, 0, 6729729, 10047488, 1073, 2, 12288, 12288}, // v20 + {PsQuebec, 0, 10047489, -1, 1343, 2, 15360, 15360}, // v21 }, } )