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

process, integrationTests, testscommon: fix total gas provided with scheduled SC calls #3743

Conversation

AdoAdoAdo
Copy link
Contributor

No description provided.

@codecov
Copy link

codecov bot commented Feb 2, 2022

Codecov Report

Merging #3743 (fb530c4) into fix-edge-case-of-set-scheduled-scrs-at-bootstrap (cb0d613) will increase coverage by 0.00%.
The diff coverage is 57.89%.

❗ Current head fb530c4 differs from pull request most recent head 0c82a8e. Consider uploading reports for the commit 0c82a8e to get more accurate results
Impacted file tree graph

@@                                Coverage Diff                                @@
##           fix-edge-case-of-set-scheduled-scrs-at-bootstrap    #3743   +/-   ##
=================================================================================
  Coverage                                             73.66%   73.66%           
=================================================================================
  Files                                                   599      599           
  Lines                                                 79167    79162    -5     
=================================================================================
  Hits                                                  58315    58315           
+ Misses                                                16266    16260    -6     
- Partials                                               4586     4587    +1     
Impacted Files Coverage Δ
process/block/baseProcess.go 60.47% <0.00%> (ø)
process/block/metablock.go 55.37% <0.00%> (ø)
process/block/preprocess/gasComputation.go 94.32% <0.00%> (-1.68%) ⬇️
process/block/preprocess/transactions.go 57.60% <83.33%> (+0.96%) ⬆️
process/block/shardblock.go 64.33% <100.00%> (ø)
epochStart/bootstrap/startInEpochScheduled.go 73.54% <0.00%> (-1.58%) ⬇️
p2p/libp2p/netMessenger.go 74.72% <0.00%> (-0.28%) ⬇️
process/block/preprocess/scheduledTxsExecution.go 27.50% <0.00%> (+0.50%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cb0d613...0c82a8e. Read the comment docs.

SebastianMarian
SebastianMarian previously approved these changes Feb 2, 2022
@AdoAdoAdo AdoAdoAdo changed the base branch from development to fix-edge-case-of-set-scheduled-scrs-at-bootstrap February 2, 2022 13:14
@@ -906,11 +906,21 @@ func (txs *transactions) getAllTxsFromMiniBlock(
}

func (txs *transactions) getRemainingGasPerBlock() uint64 {
gasConsumed := txs.getTotalGasConsumed()
gasProvided := txs.getTotalGasConsumed()
Copy link
Contributor

Choose a reason for hiding this comment

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

Actually this is really consumed as in getTotalGasConsumed method, from total gas provided is subtracted gas penalized and gas refunded if they exist

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@AdoAdoAdo AdoAdoAdo force-pushed the fix-total-gas-provided-with-scheduled branch from 01da2f9 to 0c82a8e Compare February 2, 2022 14:04
@AdoAdoAdo AdoAdoAdo merged commit 21f46c8 into fix-edge-case-of-set-scheduled-scrs-at-bootstrap Feb 2, 2022
@AdoAdoAdo AdoAdoAdo deleted the fix-total-gas-provided-with-scheduled branch February 2, 2022 14:12
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.

None yet

3 participants