Skip to content
This repository was archived by the owner on Jul 23, 2024. It is now read-only.

Conversation

@aeharvlee
Copy link
Contributor

Proposed changes

  • DefaultGasProvider now implements ContractGasProvider instead of extending StaticGasProvider to provide dynamic gas price value based on network.
  • Users should not use default constructor of DefaultGasProvider to get dynamic gas price from network.
    • I added @Depreated tag additionally to emphasize "user should not use this constructor".
    • I updated test codes to not use the default constructor of DefaultGasProvider
  • It because Klaytn is now planning to apply dynamic gas price policy.
    • If that policy is activated and we does not change this behavior, there is a high probability that the transactions created using the SDK cannot be processed.

Types of changes

Please put an x in the boxes related to your change.

  • Bugfix
  • New feature or enhancement
  • Others

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have read the CONTRIBUTING GUIDELINES doc
  • I have signed the CLA
  • Lint and unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)
  • Any dependent changes have been merged and published in downstream modules

Related issues

  • Please leave the issue numbers or links related to this PR here.

Further comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...

DefaultGasProvider now implements ContractGasProvider instead of extends StaticGasProvider to provide dynamic gas price value based on network.
Because Klaytn is now planning to apply dynamic gas price policy.

If that policy is activated and we does not change this behavior,
there is a high probability that the transactions created using the SDK cannot be processed.
Change Gas Price variable name.
Remove un-necessary deprecated tag which is duplicate (already tagged at Class).
Klaytn node in the klaytn:build docker image returns protocol version as 0x41.
It should be return 0x40(=64)
protocol versions can be different. So it should not be checked with specific value in the test code.
jimni1222
jimni1222 previously approved these changes Jun 27, 2022
Copy link
Contributor

@jimni1222 jimni1222 left a comment

Choose a reason for hiding this comment

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

LGTM ~~~

@aeharvlee aeharvlee merged commit 2ca14d9 into klaytn:dev Jun 28, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants