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 reference scripts size in min fee calculation #3983

Merged
merged 8 commits into from
Feb 1, 2024

Conversation

teodanciu
Copy link
Contributor

@teodanciu teodanciu commented Jan 10, 2024

Description

Resolves #3952

Checklist

  • Commit sequence broadly makes sense and commits have useful messages
  • New tests are added if needed and existing tests are updated
  • When applicable, versions are updated in .cabal and CHANGELOG.md files according to the
    versioning process.
  • The version bounds in .cabal files for all affected packages are updated. If you change the bounds in a cabal file, that package itself must have a version increase. (See RELEASING.md)
  • All visible changes are prepended to the latest section of a CHANGELOG.md for the affected packages. New section is never added with the code changes. (See RELEASING.md)
  • Code is formatted with fourmolu (use scripts/fourmolize.sh)
  • Cabal files are formatted (use scripts/cabal-format.sh)
  • hie.yaml has been updated (use scripts/gen-hie.sh)
  • Self-reviewed the diff

@teodanciu teodanciu changed the title Include reference scripts size in min fee calculation [WIP] Include reference scripts size in min fee calculation Jan 10, 2024
@teodanciu teodanciu force-pushed the td/ref-scripts-size-in-fee-calculation branch 7 times, most recently from 5a7b75a to c185b33 Compare January 11, 2024 22:34
@teodanciu teodanciu force-pushed the td/ref-scripts-size-in-fee-calculation branch 5 times, most recently from 9920dde to 59b8424 Compare January 29, 2024 13:57
@teodanciu teodanciu changed the title [WIP] Include reference scripts size in min fee calculation Include reference scripts size in min fee calculation Jan 29, 2024
@teodanciu teodanciu marked this pull request as ready for review January 29, 2024 14:04
@teodanciu teodanciu force-pushed the td/ref-scripts-size-in-fee-calculation branch from 59b8424 to 87a08a6 Compare January 30, 2024 05:37
Copy link
Collaborator

@lehins lehins left a comment

Choose a reason for hiding this comment

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

This is great. Few suggestions, but nothing critical.

libs/cardano-ledger-core/src/Cardano/Ledger/Tools.hs Outdated Show resolved Hide resolved
eras/babbage/impl/src/Cardano/Ledger/Babbage/UTxO.hs Outdated Show resolved Hide resolved
eras/shelley/impl/src/Cardano/Ledger/Shelley/API/Wallet.hs Outdated Show resolved Hide resolved
eras/conway/impl/src/Cardano/Ledger/Conway/Tx.hs Outdated Show resolved Hide resolved
@teodanciu teodanciu force-pushed the td/ref-scripts-size-in-fee-calculation branch 4 times, most recently from 5d4caee to 757ef78 Compare January 31, 2024 20:07
@teodanciu teodanciu force-pushed the td/ref-scripts-size-in-fee-calculation branch 2 times, most recently from d803c76 to f83e998 Compare February 1, 2024 08:14
@teodanciu teodanciu force-pushed the td/ref-scripts-size-in-fee-calculation branch 4 times, most recently from b5ecf84 to 1300da5 Compare February 1, 2024 15:21
@teodanciu teodanciu force-pushed the td/ref-scripts-size-in-fee-calculation branch from 1300da5 to dff1911 Compare February 1, 2024 17:37
This will add the cost for the reference scripts to the computation,
starting with Conway.
in order to make tests less fragile.
For this, instead of storing only `rootTxId` in `ImpTestState`, we need
to store the whole TxIn as `rootTxIn`.
@teodanciu teodanciu force-pushed the td/ref-scripts-size-in-fee-calculation branch from dff1911 to 0ffe957 Compare February 1, 2024 17:39
@teodanciu teodanciu merged commit c158b42 into master Feb 1, 2024
10 of 29 checks passed
lehins added a commit that referenced this pull request Feb 2, 2024
lehins added a commit that referenced this pull request Feb 2, 2024
lehins added a commit that referenced this pull request Feb 2, 2024
lehins added a commit that referenced this pull request Feb 2, 2024
@neilmayhew neilmayhew deleted the td/ref-scripts-size-in-fee-calculation branch March 8, 2024 21:07
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.

Addition of new minFeeRefScriptCoinsPerByte protocol parameter
2 participants