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

fork6 nodev0.4.1 #45

Merged
merged 252 commits into from
Dec 18, 2023
Merged

fork6 nodev0.4.1 #45

merged 252 commits into from
Dec 18, 2023

Conversation

scf0220
Copy link

@scf0220 scf0220 commented Dec 13, 2023

Closes #.

What does this PR do?

Reviewers

Main reviewers:

Codeowner reviewers:

  • @-Alice
  • @-Bob

Psykepro and others added 30 commits July 19, 2023 13:34
…sing it on the websocket connection.

Signed-off-by: Nikolay Nedkov <[email protected]>
…lygonHermez#2312)

Bumps [github.com/jackc/pgconn](https://github.com/jackc/pgconn) from 1.14.0 to 1.14.1.
- [Changelog](https://github.com/jackc/pgconn/blob/master/CHANGELOG.md)
- [Commits](jackc/pgconn@v1.14.0...v1.14.1)

---
updated-dependencies:
- dependency-name: github.com/jackc/pgconn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…xPolygonHermez#2313)

Bumps [github.com/rubenv/sql-migrate](https://github.com/rubenv/sql-migrate) from 1.5.1 to 1.5.2.
- [Commits](rubenv/sql-migrate@v1.5.1...v1.5.2)

---
updated-dependencies:
- dependency-name: github.com/rubenv/sql-migrate
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…PolygonHermez#2332)

Bumps [github.com/go-git/go-git/v5](https://github.com/go-git/go-git) from 5.7.0 to 5.8.1.
- [Release notes](https://github.com/go-git/go-git/releases)
- [Commits](go-git/go-git@v5.7.0...v5.8.1)

---
updated-dependencies:
- dependency-name: github.com/go-git/go-git/v5
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…ygonHermez#2331)

Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.56.2 to 1.57.0.
- [Release notes](https://github.com/grpc/grpc-go/releases)
- [Commits](grpc/grpc-go@v1.56.2...v1.57.0)

---
updated-dependencies:
- dependency-name: google.golang.org/grpc
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Signed-off-by: Nikolay Nedkov <[email protected]>
Signed-off-by: Nikolay Nedkov <[email protected]>
* do not add tx to the pool in case err != nil

* do not add tx into the pool if a fatal error in the executor happens during pre execution
Signed-off-by: Nikolay Nedkov <[email protected]>
* fix null effective_percentage

* fix forkID calculation

* fix script

* generate json-schema + docs for node config file and network_custom

* fix unittest

* Hotfixv0.1.4 to v0.2.0 (0xPolygonHermez#2255)

* Hotfix v0.1.4 to main (0xPolygonHermez#2250)

* fix concurrent web socket writes

* fix eth_syncing

* fix custom trace internal tx call error handling and update prover

* add test to custom tracer depth issue; fix internal call error and gas used

* fix custom tracer for internal tx with error and no more steps after it

* remove debug code

* Make max grpc message size configurable  (0xPolygonHermez#2179)

* make max grpc message size configurable

* fix state tests

* fix tests

* fix tests

* get SequencerNodeURI from SC if empty and not IsTrustedSequencer

* Optimize trace (0xPolygonHermez#2183)

* optimize trace

* fix memory reading

* update docker image

* update prover image

* fix converter

* fix memory

* fix step memory

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* update prover image

* fix struclogs

* fix memory size

* fix memory size

* fix memory size

* refactor memory resize

* refactor memory resize

* move log for the best fitting tx (0xPolygonHermez#2192)

* fix load zkCounters from pool

* remove unnecessary log.info

* add custom tracer support to CREATES opcode without depth increase (0xPolygonHermez#2213)

* logs

* fix getting stateroot from previous batch (GetWIPBatch)

* logs

* Fix GetWipBatch when previous last batch is a forced batch

* fix forcedBatch trusted state

* Revert "fix getting stateroot from previous batch (GetWIPBatch)"

This reverts commit 860f0e7.

* force GHA

* add pool limits (0xPolygonHermez#2189)

* Hotfix/batch l2 data (0xPolygonHermez#2223)

* Fix BatchL2Data

* Force GHA

* remove failed txs from the pool limit check (0xPolygonHermez#2233)

* debug trace by batch number via external rpc requests (0xPolygonHermez#2235)

* fix trace batch remote requests in parallel limitation (0xPolygonHermez#2244)

* Added RPC.TraceBatchUseHTTPS config parameter

* fix executor version

---------

Co-authored-by: tclemos <[email protected]>
Co-authored-by: tclemos <[email protected]>
Co-authored-by: Toni Ramírez <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: Thiago Coimbra Lemos <[email protected]>

* fix test

* fix test

---------

Co-authored-by: tclemos <[email protected]>
Co-authored-by: tclemos <[email protected]>
Co-authored-by: Toni Ramírez <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: Thiago Coimbra Lemos <[email protected]>

* Effective GasPrice refactor+fixes (0xPolygonHermez#2247)

* effective GasPrice refactor

* bugs fixes and finalizer tests fixes

* fix typo

* fix calculate effective gasprice percentage

* fix test gas price

* Fix/0xPolygonHermez#2257 effective gas price receipt (0xPolygonHermez#2258)

* effective gas price returned by the rpc in the receipt

* linter

* bugfix: fixing l2blocks timestamp for the fist batch (0xPolygonHermez#2260)

* bugfix: fixing l2blocks timestamp for the fist batch

Signed-off-by: Nikolay Nedkov <[email protected]>

* fix finalizer unit test

---------

Signed-off-by: Nikolay Nedkov <[email protected]>

* add more comments, and removed fields PrivateKeyPath and PrivateKeyPassword from etherman.Config that are not in use

* add info to git action

* add info to git action

* fix github action

* updated comments

* updated comments

* Fix/0xPolygonHermez#2263 gas used (0xPolygonHermez#2264)

* fix fea2scalar and gas used

* suggestion

* fix fea2scalar

* suggestion

* Fix pending tx when duplicate nonce (0xPolygonHermez#2270)

* fix pending tx when duplicate nonce

* set pool.transaction.failed_reason to NULL when updating an existing tx

* add more log details when adding tx to AddrQueue

* fix query to add tx to the pool. Fix lint errors

* change failed_reason for tx discarded due duplicate nonce

* Only return a tx from the pool if tx is in pending status (0xPolygonHermez#2273)

* Return a tx from the pool only if it is

* fix TestGetTransactionByHash

---------

Co-authored-by: agnusmor <[email protected]>

* fix documentation with  config file

* improve: adding check to skip appending effectivePercentage if current forkId is under 5.

Signed-off-by: Nikolay Nedkov <[email protected]>

* Fiex effectiveGasprice unsigned txs with forkId lower than 5 (0xPolygonHermez#2278)

* feat: adding functionality to stop sequencer on specific batch num from config param.

Signed-off-by: Nikolay Nedkov <[email protected]>

* patch: adding print for X-Real-IP in JSON-RPC

Signed-off-by: Nikolay Nedkov <[email protected]>

* Fix checkIfSynced (0xPolygonHermez#2289)

* [Rehashing] Check logs order and fix blockhash and blockNumber in the log conversion (0xPolygonHermez#2280)

* fix and check order

* linter

* flushID synchronizer (0xPolygonHermez#2287)

* FlushID in synchronizer

* linter

* fix logs

* commnets

* executor error refactor (0xPolygonHermez#2299)

* handle invalid rlp ROM error (0xPolygonHermez#2297)

* add maxL2GasPrice (0xPolygonHermez#2294)

* add maxL2GasPrice

* fix

* fix

* add test

* document parameter

* update description

* Error refactor (0xPolygonHermez#2302)

* error refactor

* refactor

* Fix replaced tx as failed when duplicated nonce (0xPolygonHermez#2308)

* Fix UpdateTxStatus for replacedTx

* Fix adding tx with same nonce on AddrQueue

* log reprocess need (0xPolygonHermez#2309)

* log reprocess need

* Update finalizer.go

* Feature/2300 synchronizer detect if executor restart (0xPolygonHermez#2306)

* detect if executor restarts and stop synchonizer

* Update prover images (0xPolygonHermez#2311)

* update prover image

* update prover images

* change executor param

* Update testnet.prover.config.json

* Update test.permissionless.prover.config.json

* Update test.prover.config.json

* Update public.prover.config.json

* prover params

* prover params

* prover params

* update prover images

* add doc, and fix dockers to be able to use snap/restore feature (0xPolygonHermez#2315)

* add doc, and fix dockers to be able to use snap/restore feature

* add doc for snap/restore feature

---------

Co-authored-by: Toni Ramírez <[email protected]>

* Update docker-compose.yml

* Update docker-compose.yml

* do not add tx to the pool in case err != nil

* do not add tx into the pool if a fatal error in the executor happens during pre execution

* fix dbMultiWriteSinglePosition config value

* workarround for the error error closing batch

* workarround for the error error closing batch

* workarround for the error error closing batch

* workaround for the error of closing batch, another case

* `Worker`'s `AddTxTracker` Bug Fix (0xPolygonHermez#2343)

* bugfix: Resolve  Function Bug in Worker Module

Signed-off-by: Nikolay Nedkov <[email protected]>

* improve: improving the wait for pending txs to be for only the txs for the current address.

Signed-off-by: Nikolay Nedkov <[email protected]>

---------

Signed-off-by: Nikolay Nedkov <[email protected]>

* rename config files (0xPolygonHermez#2349)

* fix closing batch + logs (0xPolygonHermez#2348)

* fix closing batch + logs

* fix

* log description

* typo errors

* fix error: failed to store transactions for batch due to duplicate key

* test

* typo

* Update README.md

* Update release.yml

* fix conflict

---------

Signed-off-by: Nikolay Nedkov <[email protected]>
Co-authored-by: joanestebanr <[email protected]>
Co-authored-by: Alonso Rodriguez <[email protected]>
Co-authored-by: tclemos <[email protected]>
Co-authored-by: tclemos <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: Thiago Coimbra Lemos <[email protected]>
Co-authored-by: joanestebanr <[email protected]>
Co-authored-by: Nikolay Nedkov <[email protected]>
…rmez#2354)

Bumps [golang.org/x/net](https://github.com/golang/net) from 0.12.0 to 0.13.0.
- [Commits](golang/net@v0.12.0...v0.13.0)

---
updated-dependencies:
- dependency-name: golang.org/x/net
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…mez#2361)

Bumps [go.uber.org/zap](https://github.com/uber-go/zap) from 1.24.0 to 1.25.0.
- [Release notes](https://github.com/uber-go/zap/releases)
- [Changelog](https://github.com/uber-go/zap/blob/master/CHANGELOG.md)
- [Commits](uber-go/zap@v1.24.0...v1.25.0)

---
updated-dependencies:
- dependency-name: go.uber.org/zap
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* fix null effective_percentage

* fix forkID calculation

* fix script

* generate json-schema + docs for node config file and network_custom

* fix unittest

* Hotfixv0.1.4 to v0.2.0 (0xPolygonHermez#2255)

* Hotfix v0.1.4 to main (0xPolygonHermez#2250)

* fix concurrent web socket writes

* fix eth_syncing

* fix custom trace internal tx call error handling and update prover

* add test to custom tracer depth issue; fix internal call error and gas used

* fix custom tracer for internal tx with error and no more steps after it

* remove debug code

* Make max grpc message size configurable  (0xPolygonHermez#2179)

* make max grpc message size configurable

* fix state tests

* fix tests

* fix tests

* get SequencerNodeURI from SC if empty and not IsTrustedSequencer

* Optimize trace (0xPolygonHermez#2183)

* optimize trace

* fix memory reading

* update docker image

* update prover image

* fix converter

* fix memory

* fix step memory

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* fix structlogs

* update prover image

* fix struclogs

* fix memory size

* fix memory size

* fix memory size

* refactor memory resize

* refactor memory resize

* move log for the best fitting tx (0xPolygonHermez#2192)

* fix load zkCounters from pool

* remove unnecessary log.info

* add custom tracer support to CREATES opcode without depth increase (0xPolygonHermez#2213)

* logs

* fix getting stateroot from previous batch (GetWIPBatch)

* logs

* Fix GetWipBatch when previous last batch is a forced batch

* fix forcedBatch trusted state

* Revert "fix getting stateroot from previous batch (GetWIPBatch)"

This reverts commit 860f0e7.

* force GHA

* add pool limits (0xPolygonHermez#2189)

* Hotfix/batch l2 data (0xPolygonHermez#2223)

* Fix BatchL2Data

* Force GHA

* remove failed txs from the pool limit check (0xPolygonHermez#2233)

* debug trace by batch number via external rpc requests (0xPolygonHermez#2235)

* fix trace batch remote requests in parallel limitation (0xPolygonHermez#2244)

* Added RPC.TraceBatchUseHTTPS config parameter

* fix executor version

---------

Co-authored-by: tclemos <[email protected]>
Co-authored-by: tclemos <[email protected]>
Co-authored-by: Toni Ramírez <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: Thiago Coimbra Lemos <[email protected]>

* fix test

* fix test

---------

Co-authored-by: tclemos <[email protected]>
Co-authored-by: tclemos <[email protected]>
Co-authored-by: Toni Ramírez <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: Thiago Coimbra Lemos <[email protected]>

* Effective GasPrice refactor+fixes (0xPolygonHermez#2247)

* effective GasPrice refactor

* bugs fixes and finalizer tests fixes

* fix typo

* fix calculate effective gasprice percentage

* fix test gas price

* Fix/0xPolygonHermez#2257 effective gas price receipt (0xPolygonHermez#2258)

* effective gas price returned by the rpc in the receipt

* linter

* bugfix: fixing l2blocks timestamp for the fist batch (0xPolygonHermez#2260)

* bugfix: fixing l2blocks timestamp for the fist batch

Signed-off-by: Nikolay Nedkov <[email protected]>

* fix finalizer unit test

---------

Signed-off-by: Nikolay Nedkov <[email protected]>

* add more comments, and removed fields PrivateKeyPath and PrivateKeyPassword from etherman.Config that are not in use

* add info to git action

* add info to git action

* fix github action

* updated comments

* updated comments

* Fix/0xPolygonHermez#2263 gas used (0xPolygonHermez#2264)

* fix fea2scalar and gas used

* suggestion

* fix fea2scalar

* suggestion

* Fix pending tx when duplicate nonce (0xPolygonHermez#2270)

* fix pending tx when duplicate nonce

* set pool.transaction.failed_reason to NULL when updating an existing tx

* add more log details when adding tx to AddrQueue

* fix query to add tx to the pool. Fix lint errors

* change failed_reason for tx discarded due duplicate nonce

* Only return a tx from the pool if tx is in pending status (0xPolygonHermez#2273)

* Return a tx from the pool only if it is

* fix TestGetTransactionByHash

---------

Co-authored-by: agnusmor <[email protected]>

* fix documentation with  config file

* improve: adding check to skip appending effectivePercentage if current forkId is under 5.

Signed-off-by: Nikolay Nedkov <[email protected]>

* Fiex effectiveGasprice unsigned txs with forkId lower than 5 (0xPolygonHermez#2278)

* feat: adding functionality to stop sequencer on specific batch num from config param.

Signed-off-by: Nikolay Nedkov <[email protected]>

* patch: adding print for X-Real-IP in JSON-RPC

Signed-off-by: Nikolay Nedkov <[email protected]>

* Fix checkIfSynced (0xPolygonHermez#2289)

* [Rehashing] Check logs order and fix blockhash and blockNumber in the log conversion (0xPolygonHermez#2280)

* fix and check order

* linter

* flushID synchronizer (0xPolygonHermez#2287)

* FlushID in synchronizer

* linter

* fix logs

* commnets

* executor error refactor (0xPolygonHermez#2299)

* handle invalid rlp ROM error (0xPolygonHermez#2297)

* add maxL2GasPrice (0xPolygonHermez#2294)

* add maxL2GasPrice

* fix

* fix

* add test

* document parameter

* update description

* Error refactor (0xPolygonHermez#2302)

* error refactor

* refactor

* Fix replaced tx as failed when duplicated nonce (0xPolygonHermez#2308)

* Fix UpdateTxStatus for replacedTx

* Fix adding tx with same nonce on AddrQueue

* log reprocess need (0xPolygonHermez#2309)

* log reprocess need

* Update finalizer.go

* Feature/2300 synchronizer detect if executor restart (0xPolygonHermez#2306)

* detect if executor restarts and stop synchonizer

* Update prover images (0xPolygonHermez#2311)

* update prover image

* update prover images

* change executor param

* Update testnet.prover.config.json

* Update test.permissionless.prover.config.json

* Update test.prover.config.json

* Update public.prover.config.json

* prover params

* prover params

* prover params

* update prover images

* add doc, and fix dockers to be able to use snap/restore feature (0xPolygonHermez#2315)

* add doc, and fix dockers to be able to use snap/restore feature

* add doc for snap/restore feature

---------

Co-authored-by: Toni Ramírez <[email protected]>

* Update docker-compose.yml

* Update docker-compose.yml

* do not add tx to the pool in case err != nil

* do not add tx into the pool if a fatal error in the executor happens during pre execution

* fix dbMultiWriteSinglePosition config value

* workarround for the error error closing batch

* workarround for the error error closing batch

* workarround for the error error closing batch

* workaround for the error of closing batch, another case

* `Worker`'s `AddTxTracker` Bug Fix (0xPolygonHermez#2343)

* bugfix: Resolve  Function Bug in Worker Module

Signed-off-by: Nikolay Nedkov <[email protected]>

* improve: improving the wait for pending txs to be for only the txs for the current address.

Signed-off-by: Nikolay Nedkov <[email protected]>

---------

Signed-off-by: Nikolay Nedkov <[email protected]>

* rename config files (0xPolygonHermez#2349)

* fix closing batch + logs (0xPolygonHermez#2348)

* fix closing batch + logs

* fix

* log description

* typo errors

* fix error: failed to store transactions for batch due to duplicate key

* test

* typo

* Update README.md

* Update release.yml

* bugfix: fixing place where we need to increment the wg per address for pending txs

Signed-off-by: Nikolay Nedkov <[email protected]>

* Store batchL2Data when the batch is opened (0xPolygonHermez#2358)

* add GasPriceMarginFactor and MaxGasPrice to eth-tx-manager (0xPolygonHermez#2360)

* add GasPriceMarginFactor and MaxGasPrice to eth-tx-manager

* add logs, fix config

* update config file documentation

---------

Co-authored-by: joanestebanr <[email protected]>

* bugfix: attaching missing TxTracker.From to pending txs to store for forced batches. (0xPolygonHermez#2365)

Signed-off-by: Nikolay Nedkov <[email protected]>

* Update README.md

* improve: adding logs (0xPolygonHermez#2373)

* improve: adding logs

Signed-off-by: Nikolay Nedkov <[email protected]>

* adding more logs

Signed-off-by: Nikolay Nedkov <[email protected]>

* adding more logs #2

Signed-off-by: Nikolay Nedkov <[email protected]>

---------

Signed-off-by: Nikolay Nedkov <[email protected]>

* bugfix: fixing finalizer's  handling. (0xPolygonHermez#2375)

Signed-off-by: Nikolay Nedkov <[email protected]>

* Update README.md

---------

Signed-off-by: Nikolay Nedkov <[email protected]>
Co-authored-by: joanestebanr <[email protected]>
Co-authored-by: Alonso Rodriguez <[email protected]>
Co-authored-by: tclemos <[email protected]>
Co-authored-by: tclemos <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: agnusmor <[email protected]>
Co-authored-by: Thiago Coimbra Lemos <[email protected]>
Co-authored-by: joanestebanr <[email protected]>
Co-authored-by: Nikolay Nedkov <[email protected]>
* change hashdb go package

* new hashdb interface

* aggregator pb refactor

* new prover image

* change prover config

* update prover image

* update to latest proto and prover image
…rmez#2380)

Bumps [golang.org/x/net](https://github.com/golang/net) from 0.13.0 to 0.14.0.
- [Commits](golang/net@v0.13.0...v0.14.0)

---
updated-dependencies:
- dependency-name: golang.org/x/net
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
….1 (0xPolygonHermez#2402)

Bumps [github.com/ethereum/go-ethereum](https://github.com/ethereum/go-ethereum) from 1.12.0 to 1.12.1.
- [Release notes](https://github.com/ethereum/go-ethereum/releases)
- [Commits](ethereum/go-ethereum@v1.12.0...v1.12.1)

---
updated-dependencies:
- dependency-name: github.com/ethereum/go-ethereum
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
@scf0220 scf0220 changed the title draft fork6 nodev0.4.1 Dec 15, 2023
@KamiD KamiD merged commit 91c6491 into release/v0.1.1 Dec 18, 2023
29 of 30 checks passed
@zjg555543 zjg555543 deleted the scf-v041-pr-fix-test branch December 28, 2023 03:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.