altimate-code icon indicating copy to clipboard operation
altimate-code copied to clipboard

feat: add --page convenience option for trace list CLI

Open anandgupta42 opened this issue 7 months ago • 1 comments

Found during v0.5.20 release review. Deferred because: new feature, not a fix.

The pagination UX requires users to manually calculate offsets: --offset 20 --limit 20, then --offset 40 --limit 20. A --page N option (where page 2 = offset 20 with default limit 20) would be more natural for the target audience. The footer already prints the exact next command, which mitigates this.

Flagged by: End User.

anandgupta42 avatar Apr 09 '26 06:04 anandgupta42

I'd like to pick this up — I built the original pagination infrastructure in PR #596 (--offset, --limit, listTracesPaginated(), "Showing X-Y of N" footer with next-page hint), so this is a natural follow-up.

The implementation should be straightforward: add --page N as a convenience option that computes offset = (page - 1) * limit before passing to the existing listTracesPaginated(). Will make --page and --offset mutually exclusive so users don't get confused, and update the footer hint to use --page syntax when the page flag was used.

@anandgupta42 can you assign this to me?

VJ-yadav avatar Apr 09 '26 15:04 VJ-yadav