Skip to content

Conversation

aorumbayev
Copy link
Collaborator

@aorumbayev aorumbayev commented Aug 19, 2025

Proposed Changes

App Client implementation

Further notes

App Factory PR is to follow shortly against this branch to simplify review

@aorumbayev aorumbayev force-pushed the feat/application-client branch 12 times, most recently from 50eb3d9 to 7defe32 Compare September 2, 2025 10:57
@aorumbayev aorumbayev marked this pull request as ready for review September 2, 2025 11:26
@Copilot Copilot AI review requested due to automatic review settings September 2, 2025 11:26
@aorumbayev aorumbayev requested a review from a team as a code owner September 2, 2025 11:26
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR implements the AppClient for Algorand smart contract applications, providing a comprehensive client interface for interacting with ARC-56 compliant apps. The AppClient offers fluent APIs for transactions, state access, and app lifecycle management.

  • Implements a full-featured AppClient with support for ARC-56 specifications
  • Provides fluent APIs for transaction building, sending, and state access
  • Adds configuration system with event emission capabilities for debugging and tracing
  • Extends composer functionality with simulation support

Reviewed Changes

Copilot reviewed 27 out of 27 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
crates/algokit_utils/src/applications/app_client/mod.rs Core AppClient implementation with network resolution and basic operations
crates/algokit_utils/src/applications/app_client/sender.rs Transaction sending functionality with debugging support
crates/algokit_utils/src/applications/app_client/transaction_builder.rs Transaction building utilities for various app operations
crates/algokit_utils/src/applications/app_client/params_builder.rs Parameter building with ABI method resolution and default value handling
crates/algokit_utils/src/applications/app_client/state_accessor.rs Structured state access for global, local, and box storage
crates/algokit_utils/src/applications/app_client/types.rs Type definitions for AppClient parameters and configurations
crates/algokit_utils/src/config.rs Global configuration system with async event emission
crates/algokit_utils/src/transactions/composer.rs Extended composer with simulation capabilities
crates/algokit_utils/tests/applications/app_client.rs Comprehensive test suite for AppClient functionality

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@aorumbayev aorumbayev force-pushed the feat/application-client branch 2 times, most recently from 6a166c7 to 6d27d07 Compare September 3, 2025 21:57
@aorumbayev aorumbayev force-pushed the feat/application-client branch from 1be959c to fb7ee7f Compare September 4, 2025 16:20
@aorumbayev
Copy link
Collaborator Author

@PatrickDinh i used your pr algorandfoundation/algokit-utils-ts#430 as a reference and added similar native struct support to abi crate which allowed removal of various helpers in the app client implementation, the abi handling should be more refined at this point feel free to take another look also pushed additional tests into app factory implementation as well -> #248, there is a few nested struct tests that i still need to add but ill do it after app factory pr is merged as using the factory as a fixture could simplify directly reusing existing nested struct tests from ts and py utils repos

@joe-p joe-p self-requested a review September 5, 2025 13:37
@aorumbayev
Copy link
Collaborator Author

For context here, Pat's PR with further refinements merged, final steps missing is merge conflicts against main branch + final batch of tests

@aorumbayev
Copy link
Collaborator Author

@PatrickDinh @joe-p pushed additional batch of tests and added tweaks for more explicit lifetime names along with use of async trait for state accessor. Feel free to check again, i think at this point it will be simpler to merge this first then get the app factory merged as a follow up to this PR. I will rebase the app factory tomorrow and update factory related tests to ensure its not duplicating tests from this pr

@aorumbayev aorumbayev requested a review from joe-p September 15, 2025 16:13
@PatrickDinh
Copy link
Collaborator

@aorumbayev I noticed that compared to the TS version, we are missing the methods to get the app client from the client manager, maybe it's worth to keep track and do it in another PR.

  • getAppClientByCreatorAndName
  • getAppClientById
  • getAppClientByNetwork

@aorumbayev
Copy link
Collaborator Author

@aorumbayev I noticed that compared to the TS version, we are missing the methods to get the app client from the client manager, maybe it's worth to keep track and do it in another PR.

  • getAppClientByCreatorAndName
  • getAppClientById
  • getAppClientByNetwork

those are in the app factory PR

@aorumbayev aorumbayev force-pushed the feat/application-client branch from 1f36156 to 6ccfab0 Compare September 16, 2025 16:28
@aorumbayev aorumbayev force-pushed the feat/application-client branch from 6ccfab0 to 17887bd Compare September 16, 2025 16:40
Copy link
Collaborator

@joe-p joe-p left a comment

Choose a reason for hiding this comment

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

Some areas that we can reduce duplication, but other than that LGTM

@aorumbayev aorumbayev requested a review from joe-p September 16, 2025 21:59
@aorumbayev aorumbayev merged commit e30a482 into main Sep 17, 2025
14 checks passed
@aorumbayev aorumbayev deleted the feat/application-client branch September 17, 2025 16:19
@engineering-ci
Copy link
Contributor

🎉 This PR is included in version 1.0.0-alpha.65 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

3 participants