Skip to content

Conversation

@rajgoesout
Copy link

@rajgoesout rajgoesout commented Nov 25, 2025

Description

Make tx costUnits consistent across block page and transaction signature page (show Not Supported Slot instead of showing 0 value or making the component disappear).

Type of change

  • Bug fix
  • New feature
  • Protocol integration
  • Documentation update
  • Other (please describe):

Screenshots

Screenshot 2025-11-25 at 7 10 57 AM Screenshot 2025-11-25 at 7 10 47 AM

Testing

Related Issues

Fixes #662

Checklist

  • My code follows the project's style guidelines
  • I have added tests that prove my fix/feature works
  • All tests pass locally and in CI
  • I have updated documentation as needed
  • CI/CD checks pass
  • I have included screenshots for protocol screens (if applicable)
  • For security-related features, I have included links to related information

Additional Notes


Important

Fix transaction cost display to show 'Not Supported Slot' for undefined cost units in block and transaction signature pages.

  • Behavior:
    • Display 'Not Supported Slot' for undefined costUnits in BlockHistoryCard.tsx and page-client.tsx instead of 0 or hiding the component.
  • Sorting:
    • Update sorting logic in BlockHistoryCard.tsx to handle undefined costUnits by treating them as 0.
  • UI:
    • Consistent display of transaction cost across block and transaction signature pages.

This description was created by Ellipsis for 2896365. You can customize this summary. It will automatically update as commits are pushed.

@vercel
Copy link

vercel bot commented Nov 25, 2025

@rajgoesout is attempting to deploy a commit to the Solana Foundation Team on Vercel.

A member of the Team first needs to authorize it.

Show `Not Supported Slot` instead of showing 0 value or making the component disappear.

Fixes solana-foundation#662
Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

Important

Looks good to me! 👍

Reviewed everything up to 2896365 in 1 minute and 28 seconds. Click for details.
  • Reviewed 54 lines of code in 2 files
  • Skipped 0 files when reviewing.
  • Skipped posting 4 draft comments. View those below.
  • Modify your settings and rules to customize what types of comments Ellipsis leaves. And don't forget to react with 👍 or 👎 to teach Ellipsis.
1. app/components/block/BlockHistoryCard.tsx:119
  • Draft comment:
    Removing the default fallback (0) for costUnits is intentional. Ensure that a legitimate 0 is displayed as '0' while undefined correctly shows 'Not Supported Slot'.
  • Reason this comment was not posted:
    Comment looked like it was already resolved.
2. app/components/block/BlockHistoryCard.tsx:172
  • Draft comment:
    Sorting now uses '(b.costUnits ?? 0) - (a.costUnits ?? 0)'. Confirm that treating undefined as 0 meets the desired sort order.
  • Reason this comment was not posted:
    Comment looked like it was already resolved.
3. app/components/block/BlockHistoryCard.tsx:345
  • Draft comment:
    The cell now displays 'Not Supported Slot' when costUnits is undefined, ensuring UI consistency.
  • Reason this comment was not posted:
    Comment did not seem useful. Confidence is useful = 0% <= threshold 50% This comment is purely informative, as it simply states what the code does without providing any suggestions or asking for clarifications. It doesn't align with the rules for useful comments.
4. app/tx/[signature]/page-client.tsx:350
  • Draft comment:
    Always rendering the Transaction cost row with a fallback of 'Not Supported Slot' makes the UI consistent with BlockHistoryCard.
  • Reason this comment was not posted:
    Comment did not seem useful. Confidence is useful = 0% <= threshold 50% This comment is purely informative and does not provide any actionable feedback or suggestions for improvement. It simply states that the change is good for consistency, which does not align with the rules for useful comments.

Workflow ID: wflow_klfIv93GePd6YV9D

You can customize Ellipsis by changing your verbosity settings, reacting with 👍 or 👎, replying to comments, or adding code review rules.

@rajgoesout
Copy link
Author

cc @jacobcreech

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.

[Bug] When CU RPC call errors, different behavior is shown on the Block page and the transaction signature page.

1 participant