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

Use gas and input instead of gasLimit and data #5915

Merged
merged 33 commits into from
Mar 23, 2023

Conversation

spacesailor24
Copy link
Contributor

@spacesailor24 spacesailor24 commented Mar 11, 2023

Changed

web3-core

web3-errors

web3-eth

web3-eth-contract

web3-types

Added

web3-eth-contract

Removed

web3-eth-contract

closes #5387

@spacesailor24 spacesailor24 added the 4.x 4.0 related label Mar 11, 2023
@spacesailor24 spacesailor24 self-assigned this Mar 11, 2023
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Mar 11, 2023

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: f443211
Status: ✅  Deploy successful!
Preview URL: https://936fad87.web3-js-docs.pages.dev
Branch Preview URL: https://wyatt-4-x-5387-gaslimit-refa.web3-js-docs.pages.dev

View logs

@github-actions
Copy link

github-actions bot commented Mar 11, 2023

Bundle Stats

Hey there, this message comes from a github action that helps you and reviewers to understand how these changes affect the size of this project's bundle.

As this PR is updated, I'll keep you updated on how the bundle size is impacted.

Total

Asset Old size New size Diff Diff %
Total 1.06 MB 1.06 MB 859 bytes 0.08%
View detailed bundle breakdown

Added

No assets were added

Removed

No assets were removed

Bigger

No assets were bigger

Smaller

No assets were smaller

Unchanged

Asset Old size New size Diff Diff %
web3.min.js 1.05 MB 1.05 MB 859 bytes 0.08%
../lib/accounts.d.ts 3.42 KB 3.42 KB 0 0.00%
../lib/types.d.ts 1.68 KB 1.68 KB 0 0.00%
../lib/types.d.ts.map 1.51 KB 1.51 KB 0 0.00%
../lib/abi.d.ts 999 bytes 999 bytes 0 0.00%
../lib/index.d.ts.map 919 bytes 919 bytes 0 0.00%
../lib/index.d.ts 899 bytes 899 bytes 0 0.00%
../lib/web3.d.ts 842 bytes 842 bytes 0 0.00%
../lib/web3.d.ts.map 694 bytes 694 bytes 0 0.00%
../lib/accounts.d.ts.map 528 bytes 528 bytes 0 0.00%
../lib/eth.exports.d.ts.map 358 bytes 358 bytes 0 0.00%
../lib/eth.exports.d.ts 321 bytes 321 bytes 0 0.00%
../lib/providers.exports.d.ts.map 292 bytes 292 bytes 0 0.00%
../lib/providers.exports.d.ts 238 bytes 238 bytes 0 0.00%
../lib/version.d.ts.map 140 bytes 140 bytes 0 0.00%
../lib/abi.d.ts.map 124 bytes 124 bytes 0 0.00%
../lib/version.d.ts 97 bytes 97 bytes 0 0.00%

@spacesailor24
Copy link
Contributor Author

So there seems to be a side effect from updating formatTransaction to replace gasLimit with gas: TransactionGasMismatchError and MissingGasError use gasLimit for their error messages and in some cases where these errors are used we call formatTransaction before throwing the error, so gasLimit is now undefined when it wasn't before this PR

@codecov
Copy link

codecov bot commented Mar 15, 2023

Codecov Report

Merging #5915 (5cdfd60) into 4.x (e172585) will increase coverage by 0.01%.
The diff coverage is 98.36%.

Additional details and impacted files
@@            Coverage Diff             @@
##              4.x    #5915      +/-   ##
==========================================
+ Coverage   81.84%   81.86%   +0.01%     
==========================================
  Files         137      137              
  Lines        5971     5983      +12     
  Branches     1571     1574       +3     
==========================================
+ Hits         4887     4898      +11     
- Misses       1084     1085       +1     
Flag Coverage Δ
UnitTests 81.86% <98.36%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
web3 ∅ <ø> (∅)
web3-core ∅ <ø> (∅)
web3-errors ∅ <ø> (∅)
web3-eth ∅ <ø> (∅)
web3-eth-abi ∅ <ø> (∅)
web3-eth-accounts ∅ <ø> (∅)
web3-eth-contract ∅ <ø> (∅)
web3-eth-ens ∅ <ø> (∅)
web3-eth-iban ∅ <ø> (∅)
web3-eth-personal ∅ <ø> (∅)
web3-net ∅ <ø> (∅)
web3-providers-http ∅ <ø> (∅)
web3-providers-ipc ∅ <ø> (∅)
web3-providers-ws ∅ <ø> (∅)
web3-rpc-methods ∅ <ø> (∅)
web3-utils ∅ <ø> (∅)
web3-validator ∅ <ø> (∅)

@spacesailor24 spacesailor24 changed the title signTransaction now always returns gas instead of gasLimit Use gas and input instead of gasLimit and data Mar 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4.x 4.0 related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants