Skip to content

report: lead each scenario card with the lowest total fee - #270

Open
nau wants to merge 1 commit into
IntersectMBO:mainfrom
nau:feat/report-lowest-fee
Open

nau wants to merge 1 commit into
IntersectMBO:mainfrom
nau:feat/report-lowest-fee

Conversation

@nau

@nau nau commented Oct 29, 2026

Copy link
Copy Markdown
Collaborator

The main page awards best CPU, best memory and smallest size. None of them is what a transaction pays. The total fee (execution fee plus reference-script fee) prices all three the way the ledger does, and a row can win one medal while costing more overall.

Example from current main, ecd: the CPU and memory medals go to Plinth 1.64/1.65 (18.75M CPU), whose 502-byte script costs 13,002 lovelace in total. Plinth 1.61/1.67/1.71 cost 7,886.

Every metrics.json already records total_fee_lovelace, so find_winners picks its minimum, with ties handled like the other metrics. The index shows that winner first in each card, as "Lowest Fee". The other three medals are unchanged.

Checked by generating the full report with cape submission report --all: all 8 cards show the new item.

The main page awards best CPU, best memory and smallest size, but none
of them is what a transaction pays. The total fee, execution plus
reference-script fee, prices all three the way the ledger does: a row
can win CPU with a script whose size fee outweighs the saving. Every
metrics.json already records total_fee_lovelace, so the index now shows
its winner first, and the other three medals follow unchanged.

This branch has not been deployed

No deployments
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.

1 participant