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

Refactor transaction builder #92

Merged
merged 1 commit into from
Dec 1, 2023

Conversation

ian-shim
Copy link
Contributor

@ian-shim ian-shim commented Nov 30, 2023

Why are these changes needed?

Checks

  • I've made sure the lint is passing in this PR.
  • I've made sure the tests are passing. Note that there might be a few flaky tests, in that case, please comment that they are not relevant.
  • Testing Strategy
    • Unit tests
    • Integration tests
    • This PR is not tested :(

@ian-shim ian-shim changed the title refactor txn builder Refactor transaction builder Nov 30, 2023
@ian-shim ian-shim marked this pull request as ready for review November 30, 2023 07:02
Copy link
Collaborator

@mooselumph mooselumph left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lg, just one question

@@ -154,10 +153,8 @@ func (c *EthClient) EstimateGasPriceAndLimitAndSendTx(
return nil, err
}

opts, err := bind.NewKeyedTransactorWithChainID(c.privateKey, tx.ChainId())
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't we still need this in EstimateGasPriceAndLimitAndSendTx?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we're reusing c.NoSentTransactOpts which already loads the private key and the chain id

@ian-shim ian-shim merged commit 588e0b2 into Layr-Labs:master Dec 1, 2023
5 checks passed
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.

2 participants