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

Update subgraph endpoints #1394

Merged
merged 18 commits into from
May 21, 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
12 changes: 0 additions & 12 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -206,17 +206,6 @@ jobs:
test_folder: "eth-l2"
- report-integration-tests

integration-tests-avalanche:
executor: intergration-tests-executor
parallelism: 4
steps:
- download-solidity-compilers
- run-integration-tests:
docker_compose_file: "docker-compose-avalanche.yml"
docker_compose_side_file: "docker-compose-avalanche-side.yml"
test_folder: "alt-l2"
- report-integration-tests

integration-tests-bnb:
executor: intergration-tests-executor
parallelism: 4
Expand All @@ -232,7 +221,6 @@ workflows:
main:
jobs:
- integration-tests
#- integration-tests-avalanche
- integration-tests-bnb
- go-lint-test-build:
name: proxyd-tests
Expand Down
9 changes: 1 addition & 8 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,6 @@
---
2-reviewers:
- '.github/**/*'
- 'l2geth/**/*'
- 'ops/**/*'
- 'packages/batch-submitter/**/*'
- 'packages/contracts/**/*'
- 'packages/data-transport-layer/**/*'
- 'packages/message-relayer/**/*'
- 'patches/**/*'
- any: ['.github/**/*', 'l2geth/**/*', 'ops/**/*', 'packages/batch-submitter/**/*', 'packages/contracts/**/*', 'packages/data-transport-layer/**/*', 'packages/message-relayer/**/*', 'patches/**/*']

M-ci:
- any: ['.github/**/*']
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@ jobs:
- name: golangci-lint gas-oracle
uses: golangci/golangci-lint-action@v3
with:
version: v1.51.0
version: v1.56.1
working-directory: go/gas-oracle
- name: golangci-lint batch-submitter
uses: golangci/golangci-lint-action@v3
with:
version: v1.51.0
version: v1.56.1
working-directory: go/batch-submitter
- name: golangci-lint bss-core
uses: golangci/golangci-lint-action@v3
with:
version: v1.51.0
version: v1.56.1
working-directory: go/bss-core
4 changes: 2 additions & 2 deletions .github/workflows/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
pr-labeler:
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@main
- uses: actions/labeler@v3
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
repo-token: "${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}"
configuration-path: .github/labeler.yml
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,9 @@ packages/boba/gateway/public/env.js
/packages/boba/subgraph/L2/build
/packages/boba/subgraph/L1/generated
/packages/boba/subgraph/L2/generated
/packages/boba/subgraph/L1/rollup/generated
/packages/boba/subgraph/L1/rollup/subgraph.yaml
/packages/boba/subgraph/L1/rollup/yarn.lock

# api
env-mainnet.yml
Expand All @@ -81,3 +84,4 @@ packages/boba/contracts/coverage/

packages/boba/account-abstraction/deployments/hardhat/
packages/boba/bundler_sdk/coverage/

4 changes: 2 additions & 2 deletions go/batch-submitter/drivers/proposer/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ func (d *Driver) CraftBatchTx(
// so in the event their API is unreachable we can fallback to a degraded
// mode of operation. This also applies to our test environments, as hardhat
// doesn't support the query either.
case drivers.IsMaxPriorityFeePerGasNotFoundError(err):
case drivers.IsMaxPriorityFeePerGasNotFoundError(err) || drivers.IsMaxPriorityFeePerGasNotSupportedError(err):
log.Warn(d.cfg.Name + " eth_maxPriorityFeePerGas is unsupported " +
"by current backend, using fallback gasTipCap")
opts.GasTipCap = drivers.FallbackGasTipCap
Expand Down Expand Up @@ -265,7 +265,7 @@ func (d *Driver) SubmitBatchTx(
// so in the event their API is unreachable we can fallback to a degraded
// mode of operation. This also applies to our test environments, as hardhat
// doesn't support the query either.
case drivers.IsMaxPriorityFeePerGasNotFoundError(err):
case drivers.IsMaxPriorityFeePerGasNotFoundError(err) || drivers.IsMaxPriorityFeePerGasNotSupportedError(err):
log.Warn(d.cfg.Name + " eth_maxPriorityFeePerGas is unsupported " +
"by current backend, using fallback gasTipCap")
opts.GasTipCap = drivers.FallbackGasTipCap
Expand Down
4 changes: 2 additions & 2 deletions go/batch-submitter/drivers/sequencer/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ func (d *Driver) CraftBatchTx(
// method, so in the event their API is unreachable we can fallback to a
// degraded mode of operation. This also applies to our test
// environments, as hardhat doesn't support the query either.
case drivers.IsMaxPriorityFeePerGasNotFoundError(err):
case drivers.IsMaxPriorityFeePerGasNotFoundError(err) || drivers.IsMaxPriorityFeePerGasNotSupportedError(err):
log.Warn(d.cfg.Name + " eth_maxPriorityFeePerGas is unsupported " +
"by current backend, using fallback gasTipCap")
opts.GasTipCap = drivers.FallbackGasTipCap
Expand Down Expand Up @@ -295,7 +295,7 @@ func (d *Driver) SubmitBatchTx(
// so in the event their API is unreachable we can fallback to a degraded
// mode of operation. This also applies to our test environments, as hardhat
// doesn't support the query either.
case drivers.IsMaxPriorityFeePerGasNotFoundError(err):
case drivers.IsMaxPriorityFeePerGasNotFoundError(err) || drivers.IsMaxPriorityFeePerGasNotSupportedError(err):
log.Warn(d.cfg.Name + " eth_maxPriorityFeePerGas is unsupported " +
"by current backend, using fallback gasTipCap")
opts.GasTipCap = drivers.FallbackGasTipCap
Expand Down
2 changes: 1 addition & 1 deletion go/bss-core/drivers/clear_pending_tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ func SignClearingTx(

gasTipCap, err := l1Client.SuggestGasTipCap(ctx)
if err != nil {
if !IsMaxPriorityFeePerGasNotFoundError(err) {
if !IsMaxPriorityFeePerGasNotFoundError(err) && !IsMaxPriorityFeePerGasNotSupportedError(err) {
return nil, err
}

Expand Down
13 changes: 13 additions & 0 deletions go/bss-core/drivers/max_priority_fee_fallback.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ var (
"Method eth_maxPriorityFeePerGas not found",
)

errMaxPriorityFeePerGasNotSupported = errors.New(
"Method eth_maxPriorityFeePerGas is not supported",
)

// FallbackGasTipCap is the default fallback gasTipCap used when we are
// unable to query an L1 backend for a suggested gasTipCap.
FallbackGasTipCap = big.NewInt(1500000000)
Expand All @@ -24,3 +28,12 @@ func IsMaxPriorityFeePerGasNotFoundError(err error) bool {
err.Error(), errMaxPriorityFeePerGasNotFound.Error(),
)
}

// IsMaxPriorityFeePerGasNotSupportedError returns true if the provided error
// signals that the backend does not support the eth_maxPrirorityFeePerGas
// method. In this case, the caller should fallback to using the constant above.
func IsMaxPriorityFeePerGasNotSupportedError(err error) bool {
return strings.Contains(
err.Error(), errMaxPriorityFeePerGasNotSupported.Error(),
)
}
Loading
Loading