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

fix(connector-besu): set contract bytecode field's max length to 49154 #3637

Merged
merged 1 commit into from
Nov 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -1041,8 +1041,10 @@ components:
$ref: '#/components/schemas/Web3SigningCredential'
bytecode:
description: See https://ethereum.stackexchange.com/a/47556 regarding the
maximum length of the bytecode
maxLength: 24576
maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex
stores each byte in 2 characters and that there is a 0x prefix (2 characters)
which does not count towards the EVM 24576 bytecode limit.
maxLength: 49154
minLength: 1
nullable: false
type: string
Expand Down Expand Up @@ -1117,8 +1119,10 @@ components:
$ref: '#/components/schemas/Web3SigningCredential'
bytecode:
description: See https://ethereum.stackexchange.com/a/47556 regarding the
maximum length of the bytecode
maxLength: 24576
maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex
stores each byte in 2 characters and that there is a 0x prefix (2 characters)
which does not count towards the EVM 24576 bytecode limit.
maxLength: 49154
minLength: 1
nullable: false
type: string
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -731,8 +731,8 @@
"type": "string",
"nullable": false,
"minLength": 1,
"maxLength": 24576,
"description": "See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode"
"maxLength": 49154,
"description": "See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex stores each byte in 2 characters and that there is a 0x prefix (2 characters) which does not count towards the EVM 24576 bytecode limit."
},
"keychainId": {
"type": "string",
Expand Down Expand Up @@ -798,8 +798,8 @@
"type": "string",
"nullable": false,
"minLength": 1,
"maxLength": 24576,
"description": "See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode"
"maxLength": 49154,
"description": "See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex stores each byte in 2 characters and that there is a 0x prefix (2 characters) which does not count towards the EVM 24576 bytecode limit."
},
"gas": {
"type": "number",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -731,8 +731,8 @@
"type": "string",
"nullable": false,
"minLength": 1,
"maxLength": 24576,
"description": "See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode"
"maxLength": 49154,
"description": "See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex stores each byte in 2 characters and that there is a 0x prefix (2 characters) which does not count towards the EVM 24576 bytecode limit."
},
"keychainId": {
"type": "string",
Expand Down Expand Up @@ -798,8 +798,8 @@
"type": "string",
"nullable": false,
"minLength": 1,
"maxLength": 24576,
"description": "See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode"
"maxLength": 49154,
"description": "See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex stores each byte in 2 characters and that there is a 0x prefix (2 characters) which does not count towards the EVM 24576 bytecode limit."
},
"gas": {
"type": "number",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ message DeployContractSolidityBytecodeNoKeychainV1RequestPB {

Web3SigningCredentialPB web3SigningCredential = 451211679;

// See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode
// See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex stores each byte in 2 characters and that there is a 0x prefix (2 characters) which does not count towards the EVM 24576 bytecode limit.
string bytecode = 256554254;

float gas = 102105;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ message DeployContractSolidityBytecodeV1RequestPB {

Web3SigningCredentialPB web3SigningCredential = 451211679;

// See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode
// See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex stores each byte in 2 characters and that there is a 0x prefix (2 characters) which does not count towards the EVM 24576 bytecode limit.
string bytecode = 256554254;

// The keychainId for retrieve the contracts json.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ export interface DeployContractSolidityBytecodeNoKeychainV1Request {
*/
'web3SigningCredential': Web3SigningCredential;
/**
* See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode
* See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex stores each byte in 2 characters and that there is a 0x prefix (2 characters) which does not count towards the EVM 24576 bytecode limit.
* @type {string}
* @memberof DeployContractSolidityBytecodeNoKeychainV1Request
*/
Expand Down Expand Up @@ -237,7 +237,7 @@ export interface DeployContractSolidityBytecodeV1Request {
*/
'web3SigningCredential': Web3SigningCredential;
/**
* See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode
* See https://ethereum.stackexchange.com/a/47556 regarding the maximum length of the bytecode. 2 + (24576 * 2) = 49154 meaning that hex stores each byte in 2 characters and that there is a 0x prefix (2 characters) which does not count towards the EVM 24576 bytecode limit.
* @type {string}
* @memberof DeployContractSolidityBytecodeV1Request
*/
Expand Down
Loading