Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App deprecation #310

Merged
merged 8 commits into from
Sep 4, 2024
Merged

App deprecation #310

merged 8 commits into from
Sep 4, 2024

Conversation

robdmoore
Copy link
Contributor

@robdmoore robdmoore commented Sep 1, 2024

Follows on from #291

Breaking changes:

  • Renamed clearProgram to clearStateProgram and extraPages to extraProgramPages in AlgoKitComposer to match algod api

Deprecations:

  • createApp -> algorand.send.appCreate() / algorand.transactions.appCreate() / algorand.send.appCreateMethodCall() / algorand.transactions.appCreateMethodCall()
  • updateApp -> algorand.send.appUpdate() / algorand.transactions.appUpdate() / algorand.send.appUpdateMethodCall() / algorand.transactions.appUpdateMethodCall()
  • callApp -> algorand.send.appUpdate() / algorand.transactions.appUpdate() / algorand.send.appUpdateMethodCall() / algorand.transactions.appUpdateMethodCall()
  • deployApp -> algorand.appDeployer.deploy
  • getCreatorAppsByName -> algorand.appDeployer.getCreatorAppsByName
  • getABIReturn -> AppManager.getABIReturn
  • getAppGlobalState -> (await appManager.getById(appId)).globalState
  • getAppLocalState -> algorand.app.getLocalState
  • getAppBoxNames -> algorand.app.getBoxNames
  • getAppBoxValue -> algorand.app.getBoxValue
  • getAppBoxValues -> algorand.app.getBoxValues
  • getAppBoxValueFromABIType -> algorand.app.getAppBoxValueFromABIType
  • getBoxValueFromABIType -> algorand.app.getAppBoxValuesFromABIType
  • decodeAppState -> AppManager.decodeAppState
  • getBoxReference -> AppManager.getBoxReference
  • getAppById -> algorand.app.getById
  • compileTeal -> algorand.app.compileTeal
  • performTemplateSubstitutionAndCompile -> algorand.appManager.compileTealTemplate
  • replaceDeployTimeControlParams -> AppManager.replaceTealTemplateDeployTimeControlParams
  • performTemplateSubstitution -> AppManager.replaceTealTemplateParams
  • stripTealComments -> AppManager.stripTealComments
  • getAppOnCompleteAction -> algosdk.OnApplicationComplete
  • getABIMethodSignature -> abiMethod.getSignature() / new ABIMethod(abiMethodParams).getSignature()
  • getAppArgsForTransaction
  • getAppArgsForABICall
  • isSchemaIsBroken
  • getAppDeploymentTransactionNote

Updates:

  • Fixed numerous bugs in AlgoKitComposer related to handling app call transactions
  • build on AlgoKitComposer now returns ABI method call objects for transactions that had them so you can resolve ABI return values

New functionality:

  • AppManager class and algorand.app
  • AppDeployer class and algorand.appDeployer
  • AlgoKitComposer.arc2Note to allow constructing an ARC-2 transaction note
  • count method in AlgoKitComposer to support retrieving current number of transactions
  • buildTransactions method in AlgoKitComposer to support building transactions without needing a signer present and switched to using that from algorand.transactions
  • Added support for populateAppCallResources to AlgoKitComposer
  • algorand.client.indexerIfPresent so you can optionally retrieve indexer if it's present
  • algorand.send/transactions.{appMethods} for the following methods: appCreate, appCreateMethodCall, appUpdate, appUpdateMethodCall, appDelete, appDeleteMethodCall, appCall, appCallMethodCall and corresponding addX methods in AlgoKitComposer / algorand.newGroup()
  • TEAL compilation caching (within AppManager instance)
  • AppLookup caching (within AppDeployer instance)

chore: Updated tests to remove calls to deprecated functions
docs/capabilities/app.md Outdated Show resolved Hide resolved
docs/capabilities/app.md Outdated Show resolved Hide resolved
docs/capabilities/app.md Outdated Show resolved Hide resolved
src/app-deploy.ts Outdated Show resolved Hide resolved
src/app-deploy.ts Outdated Show resolved Hide resolved
src/types/client-manager.ts Show resolved Hide resolved
src/types/composer.ts Outdated Show resolved Hide resolved
@robdmoore robdmoore merged commit 41d8df1 into main Sep 4, 2024
2 checks passed
@robdmoore robdmoore deleted the app-deprecation branch September 4, 2024 16:08
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