Skip to content

Commit

Permalink
client: update c-kzg and use the offical trusted setup (#3107)
Browse files Browse the repository at this point in the history
* client: update c-kzg and use the offical trusted setup

* update sims
  • Loading branch information
g11tech authored Oct 20, 2023
1 parent 7b4c229 commit a8ac9bb
Show file tree
Hide file tree
Showing 11 changed files with 4,181 additions and 18 deletions.
18 changes: 9 additions & 9 deletions package-lock.json

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

2 changes: 1 addition & 1 deletion packages/block/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
"ethereum-cryptography": "^2.1.2"
},
"devDependencies": {
"c-kzg": "^2.1.0"
"c-kzg": "^2.1.2"
},
"engines": {
"node": ">=18"
Expand Down
2 changes: 1 addition & 1 deletion packages/client/bin/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -741,7 +741,7 @@ async function run() {

// TODO sharding: Just initialize kzg library now, in future it can be optimized to be
// loaded and initialized on the sharding hardfork activation
initKZG(kzg, args.trustedSetup ?? __dirname + '/../src/trustedSetups/devnet6.txt')
initKZG(kzg, args.trustedSetup ?? __dirname + '/../src/trustedSetups/official.txt')
// Give network id precedence over network name
const chain = args.networkId ?? args.network ?? Chain.Mainnet

Expand Down
2 changes: 1 addition & 1 deletion packages/client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
"@ethereumjs/vm": "7.0.0",
"abstract-level": "^1.0.3",
"body-parser": "^1.19.2",
"c-kzg": "^2.1.0",
"c-kzg": "^2.1.2",
"chalk": "^4.1.2",
"connect": "^3.7.0",
"cors": "^2.8.5",
Expand Down
4,163 changes: 4,163 additions & 0 deletions packages/client/src/trustedSetups/official.txt

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion packages/client/test/sim/simutils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export function stringifyQuery(query: unknown): string {
}

// Initialize the kzg object with the kzg library
initKZG(kzg, __dirname + '/../../src/trustedSetups/devnet6.txt')
initKZG(kzg, __dirname + '/../../src/trustedSetups/official.txt')

export async function waitForELOnline(client: Client): Promise<string> {
for (let i = 0; i < 15; i++) {
Expand Down
2 changes: 1 addition & 1 deletion packages/client/test/sim/txGenerator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const MAX_BLOBS_PER_TX = 2
const MAX_USEFUL_BYTES_PER_TX = USEFUL_BYTES_PER_BLOB * MAX_BLOBS_PER_TX - 1
const BLOB_SIZE = BYTES_PER_FIELD_ELEMENT * FIELD_ELEMENTS_PER_BLOB

initKZG(kzg, __dirname + '/../../src/trustedSetup/devnet4.txt')
initKZG(kzg, __dirname + '/../../src/trustedSetups/official.txt')
const pkey = hexToBytes('0x45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8')
const sender = Address.fromPrivateKey(pkey)

Expand Down
2 changes: 1 addition & 1 deletion packages/evm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
"@types/minimist": "^1.2.2",
"@types/node-dir": "^0.0.34",
"benchmark": "^2.1.4",
"c-kzg": "^2.1.0",
"c-kzg": "^2.1.2",
"level": "^8.0.0",
"memory-level": "^1.0.0",
"minimist": "^1.2.5",
Expand Down
2 changes: 1 addition & 1 deletion packages/tx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
"ethereum-cryptography": "^2.1.2"
},
"peerDependencies": {
"c-kzg": "^2.1.0"
"c-kzg": "^2.1.2"
},
"peerDependenciesMeta": {
"c-kzg": {
Expand Down
2 changes: 1 addition & 1 deletion packages/util/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@
},
"devDependencies": {},
"peerDependencies": {
"c-kzg": "^2.1.0"
"c-kzg": "^2.1.2"
},
"peerDependenciesMeta": {
"c-kzg": {
Expand Down
2 changes: 1 addition & 1 deletion packages/vm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@
"@types/minimist": "^1.2.2",
"@types/node-dir": "^0.0.34",
"benchmark": "^2.1.4",
"c-kzg": "^2.1.0",
"c-kzg": "^2.1.2",
"minimist": "^1.2.5",
"node-dir": "^0.1.17",
"nyc": "^15.1.0",
Expand Down

0 comments on commit a8ac9bb

Please sign in to comment.