Skip to content

feat: add batch compress tokens#1718

Merged
ananas-block merged 18 commits into
mainfrom
jorrit/feat-batch-compress-tokens-rebased
May 5, 2025
Merged

feat: add batch compress tokens#1718
ananas-block merged 18 commits into
mainfrom
jorrit/feat-batch-compress-tokens-rebased

Conversation

@ananas-block
Copy link
Copy Markdown
Contributor

@ananas-block ananas-block commented Apr 30, 2025

Feat - add batch compress tokens changes:

Changes:

  1. add const generic IS_MINT_TO to process_mint_to
  2. use IS_MINT_TO to either mint_spl_to_pool_pda or transfer spl tokens to a token pool
  3. introduce PubkeyTrait to enable zero copy instruction data for the batch compress instruction
  4. introduce ZeroCopyNumTrait to enable zero copy instruction data for the batch compress instruction and backward compatibility of mint_spl_to_pool_pda, and create_output_compressed_accounts.
  5. refactor spl_token_transfer to manually match the token program id for CU savings
  6. rename add_token_data_to_input_compressed_accounts -> add_data_hash_to_input_compressed_accounts

Test Coverage:

  1. Functional compress 1 to 26 recipients
  2. Failing unequal recipients amounts len
  3. Failing insufficient balance
  4. Failing sender account and token pool account with different mint
  5. Failing invalid derived token pool pda
  6. Failing invalid token pool pda derived from different index
  7. Failing no sender token account

Performance Optimizations

  1. remove unnecessary anchor seed check
    The cpi authority is implicitly validated when it signs the cpi.
  2. replace system program cpi with manual cpi to new invoke_cpi_with_readonly instruction
    2.1. refactor add_data_hash_to_input_compressed_accounts to use InAccount instead of PackedCompressedAccountWithMerkleContext
  3. add with_transaction_hash to transaction instruction data
    3.1. extend instruction data by 5 bytes for backwards compatibility since borsh ignores trailing bytes deserialization will not fail in case complete instruction data is provided

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress
@ananas-block ananas-block force-pushed the jorrit/feat-batch-compress-tokens-rebased branch from 3ecbe62 to 59bdfe0 Compare April 30, 2025 21:55
@ananas-block ananas-block force-pushed the jorrit/feat-batch-compress-tokens-rebased branch from 59bdfe0 to eab804a Compare April 30, 2025 23:30
@ananas-block ananas-block force-pushed the jorrit/feat-batch-compress-tokens-rebased branch from 08b2e6e to dda0cef Compare May 1, 2025 19:19
@ananas-block ananas-block marked this pull request as draft May 1, 2025 23:48
@ananas-block ananas-block marked this pull request as ready for review May 4, 2025 20:49
Comment thread programs/compressed-token/src/instructions/create_token_pool.rs Outdated
Comment thread programs/compressed-token/src/instructions/create_token_pool.rs Outdated
index: u8,
bump: Option<u8>,
) -> Result<()> {
msg!("bump {:?}", bump);
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Suggested change
msg!("bump {:?}", bump);

@ananas-block ananas-block merged commit 8ff9974 into main May 5, 2025
31 of 42 checks passed
@ananas-block ananas-block deleted the jorrit/feat-batch-compress-tokens-rebased branch May 5, 2025 16:34
SwenSchaeferjohann pushed a commit that referenced this pull request May 29, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main
SwenSchaeferjohann pushed a commit that referenced this pull request May 29, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 1, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 2, 2025
Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 2, 2025
Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 2, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 2, 2025
Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 3, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 3, 2025
Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 3, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 3, 2025
Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 11, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 11, 2025
Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 11, 2025
Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip

rev. transfersdk

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

aadd lengthbuffer to cpi

wuip
SwenSchaeferjohann added a commit that referenced this pull request Jun 11, 2025
Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](google/zerocopy@v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](pnpm/action-setup@v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](typicode/husky@v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](chaijs/chai@v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](piotrwitek/ts-mocha@v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](rust-lang/log@0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](serde-rs/json@v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](JamieMason/syncpack@13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](jonasbb/serde_with@v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip

rev. transfersdk

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

aadd lengthbuffer to cpi

wuip

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 11, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

Configure Docker image with proper proving keys (#1766) (#1764)

Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip

rev. transfersdk

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

aadd lengthbuffer to cpi

wuip

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 17, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

Configure Docker image with proper proving keys (#1766) (#1764)

Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip

rev. transfersdk

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

aadd lengthbuffer to cpi

wuip

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 17, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

Configure Docker image with proper proving keys (#1766) (#1764)

Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip

rev. transfersdk

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

aadd lengthbuffer to cpi

wuip

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 17, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

Configure Docker image with proper proving keys (#1766) (#1764)

Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip

rev. transfersdk

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

aadd lengthbuffer to cpi

wuip

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

wip
SwenSchaeferjohann pushed a commit that referenced this pull request Jun 17, 2025
* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

Configure Docker image with proper proving keys (#1766) (#1764)

Add proving key files to Docker image instead of using empty directory.
Change run mode to RPC and update documentation for Docker usage.

fix: indexer get_compressed_account return type (#1765)

* fix: rpc return types

* fix: discriminator serialization is le bytes in photon

* fix: pr feedback

chore: bump versions, add batched Merkle tree placeholder bytes (#1767)

* chore: bump light-batched-merkle-tree -> 0.2.0, light-merkle-tree-metadata -> 0.2.0, light-concurrent-merkle-tree -> 2.0.0, light-merkle-tree-reference 2.0.0

* chore: add batched-merkle-tree placeholder bytes

* regenerate accounts

* fix: make concurrent mt *mut fields private

* chore: bump light-hash-set version -> 2.0.0

* bump: light-bloom-filter version -> 0.2.0

* fix: light-test-utils usage of concurrent-merkle-tree

* chore: bump concurrent-merkle-tree version -> 2.0.1

* chore: bump light-indexed-merkle-tree version -> 2.0.0

feat: add next nullifier index (#1604)

* feat: add next_nullifier_index

* chore: regenerated accounts

* fix: tests

refactor: nullifiers in BatchPublicTransactionEvent (#1606)

* refactor: nullifiers in BatchPublicTransactionEvent

* fix: e2e test

fix: precision in js rpc client (#1588)

* fix precision in js rpc client when  coercing tokenData responses

* fix lint

* fix toCamelCase for nested objects + BN conversion for BiggNumbers

* exclude winston from rollup

* simplify stringification

* add for u64::max

* rename coercer

* fix lint

* release to npm

* bump, rm winston

* bump

* switch toCamelCas

* add tests for safe-conversion

* rm comments

* rm logger

feat: add selection helpers and idempotent variants (#1600)

* fix precision in js rpc client when  coercing tokenData responses

fix lint

fix toCamelCase for nested objects + BN conversion for BiggNumbers

exclude winston from rollup

simplify stringification

add for u64::max

rename coercer

fix lint

release to npm

bump, rm winston

bump

switch toCamelCas

add tests for safe-conversion

rm comments

add selection helpers, idempotent, meaningfful error messages. add tests

add tests to ci

fmt

bump CHANGELOG.md

* rm logger

* better error messages

* bump to 0.20.5

* add docstring

* bump CHANGELOG.md

* bump and update expected error message in tests

chore: rename token selectors in js (#1612)

* rename

* bump

Update verify.rs (#1605)

fix: parse event from transaction (#1614)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

fix: proof by index by fixing get_num_inserted_elements() (#1611)

* wip

* cleanup and refactor into event dir

* fix: ci

* chore: add photon test data generation for 4 cpi events

* fix: proof by index by fixing get_num_inserted_elements()

* fix: run program ci tests on program libs changes

* remove legacy comment

* fix: system test

* fix: sytem test

fix: add registered program ownership check

fix: add signer check for batched address tree

fix: migrate state output queue signer check

build(deps): bump tabled from 0.17.0 to 0.18.0 (#1607)

Bumps [tabled](https://github.com/zhiburt/tabled) from 0.17.0 to 0.18.0.
- [Changelog](https://github.com/zhiburt/tabled/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zhiburt/tabled/commits)

---
updated-dependencies:
- dependency-name: tabled
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump nx from 20.3.0 to 20.4.6 (#1610)

Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 20.3.0 to 20.4.6.
- [Release notes](https://github.com/nrwl/nx/releases)
- [Commits](https://github.com/nrwl/nx/commits/20.4.6/packages/nx)

---
updated-dependencies:
- dependency-name: nx
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint from 9.19.0 to 9.21.0 (#1609)

Bumps [eslint](https://github.com/eslint/eslint) from 9.19.0 to 9.21.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.19.0...v9.21.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump zerocopy from 0.8.14 to 0.8.20 (#1608)

Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.14 to 0.8.20.
- [Release notes](https://github.com/google/zerocopy/releases)
- [Changelog](https://github.com/google/zerocopy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google/zerocopy/compare/v0.8.14...v0.8.20)

---
updated-dependencies:
- dependency-name: zerocopy
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump pnpm/action-setup from 4.0.0 to 4.1.0 (#1565)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v4.0.0...v4.1.0)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump husky from 9.1.5 to 9.1.7 (#1574)

Bumps [husky](https://github.com/typicode/husky) from 9.1.5 to 9.1.7.
- [Release notes](https://github.com/typicode/husky/releases)
- [Commits](https://github.com/typicode/husky/compare/v9.1.5...v9.1.7)

---
updated-dependencies:
- dependency-name: husky
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

test: e2e forester (#1615)

build(deps-dev): bump chai from 5.1.2 to 5.2.0 (#1620)

Bumps [chai](https://github.com/chaijs/chai) from 5.1.2 to 5.2.0.
- [Release notes](https://github.com/chaijs/chai/releases)
- [Changelog](https://github.com/chaijs/chai/blob/main/History.md)
- [Commits](https://github.com/chaijs/chai/compare/v5.1.2...v5.2.0)

---
updated-dependencies:
- dependency-name: chai
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump @types/react-dom from 19.0.3 to 19.0.4 (#1623)

Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 19.0.3 to 19.0.4.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

fix: install rust 1.83 via install.sh (#1628)

build(deps-dev): bump ts-mocha from 10.0.0 to 11.1.0 (#1621)

Bumps [ts-mocha](https://github.com/piotrwitek/ts-mocha) from 10.0.0 to 11.1.0.
- [Release notes](https://github.com/piotrwitek/ts-mocha/releases)
- [Commits](https://github.com/piotrwitek/ts-mocha/compare/v10.0.0...v11.1.0)

---
updated-dependencies:
- dependency-name: ts-mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump thiserror from 2.0.11 to 2.0.12 (#1622)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 2.0.11 to 2.0.12.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.11...2.0.12)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump log from 0.4.25 to 0.4.26 (#1624)

Bumps [log](https://github.com/rust-lang/log) from 0.4.25 to 0.4.26.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.25...0.4.26)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump syn from 2.0.96 to 2.0.99 (#1625)

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.96 to 2.0.99.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.96...2.0.99)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester(send_transaction): add timeout checks (#1631)

feat: add testnet init xtask command (#1632)

* feat: add testnet init xtask command

* fix tests

* fix lint

* fix: registry program test

perf: indexed array remove next index (#1629)

* created separate indexed array crate, updated MockBatchedAddressForester, created indexed tree in test mt

* refactor: remove next_index from non-inclusion circuit

* chore: debugged tests: batched merkle tree, light-prover-client, added new reference indexed array and Merkle tree

* stash, empty_address_queue_test v1 wip

* more fixes, e2e tests work

* fix: e2e, registry tests

* fix: concurrent tree tests

* chore: clean up light-indexed-array

* cleanup and regenerate batched address tree account

* chore: updated proving keys download url

* Update GitHub Actions to use 8vCPU runner for prover tests

* remove warnings

* Update prover/server/prover/proving_keys_utils.go

* chore: add comma for ,input

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

* chore: remove leftover

* remove unwrap

* remove legacy tests

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

chore: update photon api (#1634)

* chore: update photon api

* fix: context

* fix: install script

* Update sdk-libs/client/src/indexer/photon_indexer.rs

* chore: trigger forester ci on program and photon api changes

* switch to warp-vms for forester ci workflow

* add retry logic for `get_validity_proof_v2`

---------

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

feat: optimize forester by parallelizing zkp proof generation for batch append and nullify (#1633)

* wip

* parallel batch proof gen

* Remove debug logs

* remove unnecessary init_logger calls from tests

* cleanup

* cleanup

* Add delays to stabilize async indexer batch tests

* test_indexer: get_queue_elements with 0 offset

* fix

* Group transactions into chunks for batch processing.

* Remove sleep delay in transaction processing.

* Refactor chunking logic with a constant for chunk size.

* add batch_ixs_per_tx configuration for transaction batching

Replaces the fixed CHUNK_SIZE with a configurable batch_ixs_per_tx parameter, allowing dynamic control over instructions per transaction.

* Change batch_ixs_per_tx to 1 in test configurations

* format

* switch to warp-ubuntu-latest-x64-4x for forester ci workflow

chore: fix and rename sdk test to anchor sdk test (#1645)

* chore: fix and rename sdk test to anchor sdk test

* fix: pnpm lockfile

* chore: renamed anchor-sdk-test -> sdk-anchor-test

* fix: pnpm lock

* remove warnings

* cleanup sdk-anchor-test

fix: allow export for batch* circuits (#1653)

fix: hashing be for batched trees for TokenData and CompressedAccount… (#1652)

* fix: hashing be for batched trees for TokenData and CompressedAccount amount

* refactor: indexed element hashing to use 32 byte inputs

* test: add more tests CompressedAccount hash

* test: randomized legacy, hash vs z hash test

* test: token data legacy random test

* test: circuit account hash and token data hash equivalence

refactor: LightHasher and AsByteVec -> ToByteArray (#1650)

refactor: hasher and ToByteArray -> ToByteArray

refactor: hash_to_bn254_field_size_be return Option<[u8;32]> -> [u8;32]

rename: Truncate -> HashToFieldSize

refactor: move bigint -> light-hasher, hash to field size return Result

refactor: data hasher into file, add macros to implement data hasher and to bytes for arrays

refactor: rename bytes.rs -> to_byte_array.rs

refactor: replace light_merkle_tree_metadata::TreeType with light_compressed_account::TreeType (#1655)

refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber (#1660)

* refactor: add queue_pubkey & tree_type to MerkleTreeSequenceNumber

* format

* fix: update photon to sergey/merkle-tree-seq-plus

* update program layout in typescript bindings, fix tests

* cleanup

* fix test

* fix: update photon dependency to latest commit

refactor: light-sdk, Light Account and LightAccountInfo (#1662)

* refactor: sdk verify

* refactor: LightAccount, LightAccountInfo and tests

* fixed: sdk test

feat: Formal Verification for updated circuits (#1644)

* bump lean version

* update circuits with input hashing

* checkpoint on rangetrees

* no indices

* remove next index

* progress on address tree

* extract all circuits

* checkpoint

* bring back some tests

* catch-up old mains

* batch append circuit

* add proofs for BatchUpdate

* soundness and completeness for address append

* clean up sorries

* state main props for address append

* fix change

* fix tags

* correct tree depths

refactor: light-sdk file structure (#1663)

fix: rent exemption check (#1668)

* fix: relax rent exemption check from strict equal to greater than

* remove dead code

* Update program-libs/account-checks/src/checks.rs

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

fix: queue type usage in from account info (#1669)

* fix: use queue type consistently in from_account_info

* chore: fix lint

chore: unify queue and tree types (#1670)

* fix: use queue type consistently in from_account_info

* chore: fix lint

* chore: unify queue and tree type constants in light-compressed-account

chore: add metadata length and current index checks to vec and cyclic vec from_bytes_at (#1671)

chore: feature gate try_into_array, to_vec behind std feature, make std non default (#1672)

chore: light-batched-merkle-tree feature gate test-utils test-only (#1673)

* chore: light-batched-merkle-tree feature gate test-utils test-only

chore: update github workflow to test with test-only feature

* fix: account compression program test imports

refactor: system program anchor -> pinocchio (#1664)

* feat: created anchor system program

feat: account checks with pinoccio and anchor
feat: program_check, signer_check, pda_check

* fix: cli, replace light_system_program with light_system_program_pinocchio

* fix: rust tests

feat: batch address updates support (#1651)

* feat: batch address updates support

* refactor: remove debug prints and improve PhotonIndexer initialization

* add light-concurrent-merkle-tree dep to sdk-libs/program-test

* refactor: reduce batch size for transaction configuration in e2e forester test

chore: bump groth16 solana v0.1.0 (#1680)

feat: feat: add queue_index to NewAddress and implement handling logic (#1683)

feat: extend PackedAccounts with pre and system accounts (#1679)

* feat: extend PackedAccounts with pre and system accounts

* Update sdk-libs/sdk/src/instruction/pack_accounts.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* format

* feat: return offsets from packed accounts

* Update sdk-libs/sdk/Cargo.toml

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: light hasher, add fuzzing (#1684)

* chore: remove flatten attribute, rename truncate code -> hash_to_field_size_code

refactor: into hasher dir

refactor: field processor

refactor: input validation

remove reconstructed struct

refactor: add context struct

refactor: move context struct into field_processor

format

feat: add basic fuzzing

move tests

refined fuzzing strategy

implemented review feedback

removed to_bytes_arrays

fix LightHasher unit tests

cleanup

fix: tests

* test: add Pubkey and borsh #[hash] tests, add debug print to DataHasher::hash

* Update program-libs/hasher/src/hash_to_field_size.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

* Update program-libs/hasher/src/errors.rs

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: discriminator sdk macro, light-hasher remove Discriminator, light-account-checks remove constant from Discriminator (#1685)

refactor: sdk use compressed account info from light-compressed-account (#1686)

* refactor: sdk use compressed account info from light-compressed-account

* chore: resolve merge conflict

refactore: rename tree and queue types with v1, v2 suffixes (#1687)

refactor: MerkleContext nullifier_queue_pubkey -> queue_pubkey (#1688)

refactor: counter example (#1690)

* fixed counter test program

* feat: counter program added close instruction

* add to ci tests, format

* refactor: rename CBorshAccount -> LightAccount

feat: cli: update commands for checking compressed SOL and token balances (#1694)

* feat: cli: update commands for checking compressed SOL and token balances

* fix: update token balance command to handle multiple accounts

feat: assign addresses (#1695)

* feat: assign addresses to compressed accounts

* feat: make tx hash optional

* chore: bump photon commit hash

perf: extend registered program pda account (#1698)

* perf: replaced signer derivation check with comparison

* feat: add resize instruction with tests

* regenerated accounts

chore: rename instruction data traits (#1699)

fix: add account is zeroed check to init cpi context account (#1700)

* fix: add account is zeroed check to init cpi context account

refactor: improve epoch_manager error handling and logging (#1697)

1. Increases log verbosity for key operations in `process_queue` (finding slots, waiting, sending txs) by changing several `trace!` calls to `info!`.
2. Modifies error handling within the main loop:
- Errors encountered during the rollover check (`check_for_epoch_rollover`) are now logged as errors but no longer cause the `process_queue` function to return immediately.
- Failures during `send_batched_transactions` are also logged as errors, but the function now continues processing the epoch instead of returning the error. This makes the forester more resilient to transient transaction send issues.
3. Removes a redundant `TODO` comment.

test: add new instruction integration test (#1703)

* test: add rnd test for zero copy ix data & traits, restore cpi tests, add account checks unit tests

add tests for invoke_cpi_with_account_info

bump anchor to 0.31.0, and solana versions to 2.2.1

chore: added tests, refactored cpi context validation

* update ci setup and build

* fix setup and build

* chore: bump RPC methods to solana v2 (#1704)

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

refactor: instruction data field is_decompress -> is_compress

refactor: use check_data_is_zeroed set_discriminator

test: restore verify signer test

test: restore cpi context unit tests

fix: typos in filenames

chore: remove obsolete combine logic and tests

refactor: use account_info_init instead of manually setting the discriminator

feat: add xtask to create serialized protocol config update instruction

feat: address v2 test with multiple addresses, add async yields (#1719)

* feat: address v2 test with multiple addresses, add async yields

* enhance address creation logic to support multiple addresses
* add `tokio::task::yield_now()` in async loops to improve responsiveness

* refactor: remove commented debug print statements from test_indexer

chore: included `pkgconf` and `libssl-dev` to support building with OpenSSL (#1721)

fix: forester do not retry failing tx (#1724)

* fix: forester do not retry failing tx

* cleanup

feat: add retry mechanism to rate-limited requests in Photon indexer (#1722)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* format

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: simplify retry logic in get_validity_proof_v2 request

fix: check_account_balance_is_rent_exempt return rent_exemption (#1715)

* fix: check_account_balance_is_rent_exempt return rent_exemption

* test: test rollover fee is correct

* Update program-tests/account-compression-test/tests/batched_merkle_tree_test.rs

feat: add batch compress tokens (#1718)

* feat: add batch compress tokens

fix ctoken js test: mint-to with wrong authority now throws inside spl program

test and optimize batch compress

test: add failing tests and fix mint to failing tests

fix: token22 compression

feat: add single amount to batch compress

* fix: comments

* perf: remove unnecessary seed check

* perf: remove unused input data

* perf: switch ctoken system program cpi to with_readonly

* feat: add with tx hash to transfer ix

* chore: add transfer2 to ensure transfer backwards compatibility

* stash pre claude

* feat: stateless.js add decodeInstructionDataInvokeCpiWithReadOnly

* stash

* stash

* remove transaction2

* cleanup

* chore: review 1718 (#1725)

* chore: expect index in batch compress

* chore: is_valid_token_pool_pda return Result

* test: add randomized test for BatchCompressInstructionData

* fix: mint lookup

---------

Co-authored-by: Swen Schäferjohann <42959314+SwenSchaeferjohann@users.noreply.github.com>

chore: fix token escrow idl (#1729)

build(deps-dev): bump eslint from 9.21.0 to 9.26.0 (#1726)

Bumps [eslint](https://github.com/eslint/eslint) from 9.21.0 to 9.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.21.0...v9.26.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.26.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

CI: migrate workflows to cache v4 (#1716)

Co-authored-by: David Klank <hol1337hol@gmail.com>

build(deps): bump serde_json from 1.0.139 to 1.0.140 (#1639)

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump syncpack from 13.0.1 to 13.0.4 (#1713)

Bumps [syncpack](https://github.com/JamieMason/syncpack) from 13.0.1 to 13.0.4.
- [Release notes](https://github.com/JamieMason/syncpack/releases)
- [Changelog](https://github.com/JamieMason/syncpack/blob/13.0.4/CHANGELOG.md)
- [Commits](https://github.com/JamieMason/syncpack/compare/13.0.1...13.0.4)

---
updated-dependencies:
- dependency-name: syncpack
  dependency-version: 13.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump serde_with from 2.3.3 to 3.12.0 (#1649)

Bumps [serde_with](https://github.com/jonasbb/serde_with) from 2.3.3 to 3.12.0.
- [Release notes](https://github.com/jonasbb/serde_with/releases)
- [Commits](https://github.com/jonasbb/serde_with/compare/v2.3.3...v3.12.0)

---
updated-dependencies:
- dependency-name: serde_with
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps): bump react and @types/react (#1738)

Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react)

Updates `@types/react` from 19.0.8 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: react
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

refactor: forester improvements (#1723)

* feat: add retry mechanism to rate-limited requests in Photon indexer

Replaced `rate_limited_request` with `rate_limited_request_with_retry` to include a retry mechanism for handling transient errors.

* Reduced initial retry delay to 100ms and capped exponential backoff at 4000ms to improve responsiveness and mitigate excessive delays.

* refactor: enhance error handling and return types in tree scheduling functions

* update transaction batching configuration for improved performance

* refactor: update light slot calculation and add tests for phase start scenarios

* refactor: implement rate-limited request for get_indexer_slot method

* refactor: adjust indexer wait logic and enhance error handling in transaction processing

* refactor: add hash cache into transaction processing

* Replace `debug` logs with `trace` and remove unused dependencies

* Increase sleep duration in utils.rs from 400ms to 500ms

* Add `#[serial]` attribute to test_transfer_with_transaction_hash

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

build(deps): bump react-dom and @types/react-dom (#1737)

Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) and [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom). These dependencies needed to be updated together.

Updates `react-dom` from 19.0.0 to 19.1.0
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.1.0/packages/react-dom)

Updates `@types/react-dom` from 19.0.4 to 19.1.3
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: "@types/react-dom"
  dependency-version: 19.1.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

build(deps-dev): bump eslint-config-next from 15.1.4 to 15.3.2 (#1739)

Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 15.1.4 to 15.3.2.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/commits/v15.3.2/packages/eslint-config-next)

---
updated-dependencies:
- dependency-name: eslint-config-next
  dependency-version: 15.3.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Refactor Dockerfile and update README for key management (#1743)

chore: pnpm update (#1744)

chore: cleanup light client and light-program-test (#1720)

* refactored dependencies in light-client

* refactor program-test

* chore: split up system-cpi-test into v1 and v2

* fix test_state_indexer_async_batched

* ignore flaky forester test

refactor: counter program 2 (#1710)

fix: zero copy num traits (#1750)

* chore: feature flag num traits

* chore: removed redundant light verifier tests

refactor: RPC pool configuration and connection handling (#1745)

* Refactor RPC pool configuration and connection handling

- Introduced `RpcPoolConfig` struct for better organization of RPC pool settings.
- Updated CLI arguments to include new RPC pool parameters: connection timeout, idle timeout, max retries, and retry delays.
- Replaced direct usage of `SolanaRpcPool` with a builder pattern for improved configurability.
- Enhanced connection retrieval with retry logic and exponential backoff.
- Removed unused `log` dependency from `sdk-libs/client/Cargo.toml`.

* rebase

* fix after rebase

feat: regenerate photon-api crate & v2 proof handling (#1753)

* feat: regenerate photon-api crate

* refactor: remove debug print statement from get_validity_proof_v2

* feat: enable indexer in LightValidatorConfig for address tree initialization

* refactor: disable adjust address root index calculation in types.rs

* feat: update photon dependency to a newer commit

* rename AddressSeq to AddressQueueIndex and update related references

* refactor: implement Display trait for AccountState and update formatting

* rename: change AddressSeq to AddressQueueIndex and update module references

* refactor: change nullifier_queue_index and tree_type to u16 in AccountContext

chore: update rust to 1.86 (#1759)

* chore: update rust to 1.86

* chore: simplify get_output_account (#1760)

---------

Co-authored-by: ananas-block <58553958+ananas-block@users.noreply.github.com>

add light-compressed-token-sdk crate

lint

add tree and queue

add account_info

rename to decompress

proof option

fix lint

rebased to main

add c-token rust client helpers

wip

wip

wip

add test dir

wip

rev. transfersdk

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

wip

aadd lengthbuffer to cpi

wuip

Co-authored-by: Sergey Timoshin <sergeytimoshin@proton.me>

wip
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.

2 participants