Add simd 553 fee comparison to transaction page - #1249
Conversation
|
@Woody4618 is attempting to deploy a commit to the Solana Foundation Team on Vercel. A member of the Team first needs to authorize it. |
Greptile SummaryThe PR adds an environment-gated SIMD-0553 fee comparison to transaction summaries.
Confidence Score: 4/5The PR is not yet safe to merge because explicit compute limits can still be replaced by fallback reserves, producing materially incorrect SIMD-0553 projections. The requested-cost fix depends on a parsed instruction estimator whose string-only extraction does not match the byte-shaped partially decoded instructions used by the transaction path, leaving the previously reported underestimation reachable. Files Needing Attention: app/features/transaction/ui/SummaryCard.tsx and app/entities/compute-unit/lib/compute-units-schedule.ts Important Files Changed
Reviews (3): Last reviewed commit: "Update transaction.ts" | Re-trigger Greptile |
| // quantity the scheduler packs blocks with. | ||
| const feeProjections = | ||
| isSimd0553FeeEnabled() && costUnits !== undefined && priorityFeeLamports !== undefined | ||
| ? projectResourceAndInclusionFees({ priorityFeeLamports, requestedCostUnits: costUnits }) |
There was a problem hiding this comment.
When a transaction requests substantially more compute or loaded-account data than it consumes, this passes the RPC's executed/actual costUnits as SIMD-0553's requested-cost charge base, causing the displayed projection to understate the proposed fee and potentially misclassify the transaction as cheaper.
Knowledge Base Used: Transaction inspection and execution analysis
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
| const transactionWithMeta = details?.data?.transactionWithMeta; | ||
| const fee = transactionWithMeta?.meta?.fee; | ||
| const costUnits = transactionWithMeta?.meta?.costUnits; | ||
| const computeUnitsConsumed = transactionWithMeta?.meta?.computeUnitsConsumed; |
There was a problem hiding this comment.
The fee row in Summary displays the actual fee, including priority fees, not the price for a single signature.
Here is the Tx with priority fees: https://explorer.solana.com/tx/2Vr1o2mL4531v9DuYtkGdTnC9f7DpJZP3N2jwkBm7huGkopfNoYXPQ1c2nz4P1nvtzXW52dfycJoGKjWUo6hMqoX
The fee under SIMD uses costModel and does not account for priority fees. That might produce wrong percentages
| priorityFeeLamports, | ||
| requestedCostUnits: estimateRequestedCostUnits({ | ||
| computeUnitsConsumed, | ||
| executedCostUnits: costUnits, |
There was a problem hiding this comment.
Explicit compute limits ignored
When a legacy or v0 transaction contains SetComputeUnitLimit, the parsed estimator's string-only data check skips the byte-shaped instruction and supplies a fallback reserve here instead of the requested limit, causing the SIMD-0553 projection to understate the fee or classify the transaction incorrectly.
Description
Added a comparison fo fees under SIMD 0553