Skip to content

Conversation

@faisal-chainlink
Copy link
Collaborator

@faisal-chainlink faisal-chainlink commented Sep 18, 2025

This PR introduces some refactoring and misc enhancements to CR:

  1. Added a PackageResolver construct to abstract binding and unbinding which will later also be used to cache latest package IDs (with a reasonable timeout).
  2. Added a cache to the PTBClient to allow for quick access to state ref object IDs (e.g. offramp state object ID) without refetching it from the RPC. This is safe because those IDs do not change with upgrades.
  3. Refactoring the logic of getting pointer object field values into GetValuesFromPackageOwnedObjectField so it can be re-used between CR and offramp execution flow.
  4. Refactor and simplify the GetAddressMappings method in offramp execution flow. Also use the client cache to reduce RPC calls.
  5. Other minor misc. edits

@faisal-chainlink faisal-chainlink marked this pull request as ready for review September 19, 2025 14:46
@faisal-chainlink faisal-chainlink requested a review from a team as a code owner September 19, 2025 14:46
@faisal-chainlink faisal-chainlink merged commit 80cac99 into develop Sep 19, 2025
18 checks passed
@faisal-chainlink faisal-chainlink deleted the feature/cache-state-object-ids branch September 19, 2025 16:17
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