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

Include gas fee in ContractCreate and ContractCall record transactionFee fields #9774

Merged
merged 6 commits into from Nov 9, 2023

Conversation

tinker-michaelj
Copy link
Collaborator

@tinker-michaelj tinker-michaelj commented Nov 8, 2023

Description:

1️⃣ In contract-service-impl:

  • Defines a GasFeeRecordBuilder for the contract operations that directly deduct the gas cost from the payer account (⚠️ even if it is a superuser like 0.0.2---leave this for mono-service parity).
  • Extends CallOutcome with the gasPrice used for the contract operation; and then updates records with total assessed gas fees in ContractCallHandler and ContractCreateHandler.

2️⃣ In test-clients:

  • Deletes unused SnapshotMode/SnapshotMatchMode files in old package (incomplete merge).
  • Removes duplicate appearance of "alias" in FIELDS_TO_SKIP_IN_FUZZY_MATCH.
  • Removes /HAPI Test/ path segment from @HapiTest record stream loc.
  • Adds some useful logs in SnapshotModeOp.

Signed-off-by: Michael Tinker <michael.tinker@swirldslabs.com>
Signed-off-by: Michael Tinker <michael.tinker@swirldslabs.com>
Signed-off-by: Michael Tinker <michael.tinker@swirldslabs.com>
Copy link

github-actions bot commented Nov 8, 2023

Node: Unit Test Results

    2 277 files  +1      2 277 suites  +1   1h 32m 11s ⏱️ - 1m 16s
118 367 tests ±0  118 333 ✔️ ±0  34 💤 ±0  0 ±0 
126 628 runs  ±0  126 594 ✔️ ±0  34 💤 ±0  0 ±0 

Results for commit dd7619d. ± Comparison against base commit 6f0c423.

♻️ This comment has been updated with latest results.

Copy link

codecov bot commented Nov 8, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

❗ No coverage uploaded for pull request base (develop@6f0c423). Click here to learn what that means.

Additional details and impacted files
@@            Coverage Diff             @@
##             develop    #9774   +/-   ##
==========================================
  Coverage           ?   65.44%           
  Complexity         ?    29987           
==========================================
  Files              ?     3297           
  Lines              ?   125585           
  Branches           ?    13027           
==========================================
  Hits               ?    82186           
  Misses             ?    40266           
  Partials           ?     3133           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link

github-actions bot commented Nov 8, 2023

Node: E2E Test Results

    1 files      1 suites   22m 15s ⏱️
310 tests 310 ✔️ 0 💤 0
332 runs  332 ✔️ 0 💤 0

Results for commit dd7619d.

♻️ This comment has been updated with latest results.

Signed-off-by: Michael Tinker <michael.tinker@swirldslabs.com>
Copy link

github-actions bot commented Nov 8, 2023

Node: Integration Test Results

280 tests  ±0   280 ✔️ ±0   28m 45s ⏱️ -1s
    5 suites ±0       0 💤 ±0 
    5 files   ±0       0 ±0 

Results for commit dd7619d. ± Comparison against base commit 6f0c423.

Copy link
Member

@david-bakin-sl david-bakin-sl left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

github-actions bot commented Nov 8, 2023

Node: HAPI Test Results

1 246 tests  +1   853 ✔️ ±0   1h 22m 54s ⏱️ +26s
   166 suites ±0   393 💤 +1 
   166 files   ±0       0 ±0 

Results for commit dd7619d. ± Comparison against base commit 6f0c423.

Copy link
Member

@Neeharika-Sompalli Neeharika-Sompalli left a comment

Choose a reason for hiding this comment

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

LGTM ! Thanks @tinker-michaelj

@tinker-michaelj tinker-michaelj merged commit acd4ef8 into develop Nov 9, 2023
16 of 17 checks passed
@tinker-michaelj tinker-michaelj deleted the 09663-inc-gas-in-txn-fee branch November 9, 2023 14:36
ilko-iliev-lime pushed a commit that referenced this pull request Nov 10, 2023
…ctionFee` fields (#9774)

Signed-off-by: Michael Tinker <michael.tinker@swirldslabs.com>
nickpoorman pushed a commit that referenced this pull request Nov 22, 2023
…ctionFee` fields (#9774)

Signed-off-by: Michael Tinker <michael.tinker@swirldslabs.com>
Signed-off-by: Nick Poorman <nick@swirldslabs.com>
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.

Let contract operations report direct gas charges as fees for mod-service record construction
3 participants