feat: support for index-ng canister (in a dedicated module) in ledger-icrc #562
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
Provide support for the
index-ng
canister in@dfinity/ledger-icrc
.Notes
The support was originally introduced as a replacement of the existing
IndexCanister
but, after testing a next release, we figured out it introduced a breaking changes as a variablebalance
was added as a non optional argument in theGetTransactions
results.This lead to following error when the canister was using to query "old-index" canister:
That's why ultimately we decided to introduce support for the
index-ng
canister in a dedicated module.Previous PRs
For tracability:
Changes
index-ng/index-ng.did
as source for the Index-ng canistericrc_balance_of
for Index-ng and ledger canister (we assume in the future there might be other duplicate functions that are shared by both canisters)getTransactions
which accept queries