Skip to content

fix: return all transactions when start is None in index get_account_…#10733

Draft
Rachit2323 wants to merge 3 commits into
dfinity:masterfrom
Rachit2323:fix/index-get-transactions-start-none
Draft

fix: return all transactions when start is None in index get_account_…#10733
Rachit2323 wants to merge 3 commits into
dfinity:masterfrom
Rachit2323:fix/index-get-transactions-start-none

Conversation

@Rachit2323

Copy link
Copy Markdown
Contributor

Bug

Calling get_account_transactions without a start value always returns empty results, even when the account has transactions.

Why

The code was using u64::MAX as a default for start. Then it filtered for blocks less than u64::MAX — but since the search started at u64::MAX, nothing was ever returned.

Fix

When start is not given, return all transactions instead of filtering.

Changes

  • Fixed rs/ledger_suite/icrc1/index-ng/src/main.rs
  • Fixed rs/ledger_suite/icp/index/src/main.rs
  • Added tests to both test files

@github-actions github-actions Bot added the fix label Jul 10, 2026
@basvandijk basvandijk added the security-review-passed IDX or InfraSec have concluded it's safe to run CI on the external PR. label Jul 10, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Comment thread rs/ledger_suite/icrc1/index-ng/tests/tests.rs Outdated
@github-actions

Copy link
Copy Markdown
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

external-contributor fix security-review-passed IDX or InfraSec have concluded it's safe to run CI on the external PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants