Repository navigation
Fixes #952, Fixes #955, Fixes #956, Fixes #957 - #1027
Closed
thatElisha wants to merge 3 commits into
Closed
thatElisha wants to merge 3 commits into
thatElisha wants to merge 3 commits into
Conversation
…t#957 feat: implement transaction preflighting, fluent builder API, group builder, and batch account queries - Fixes Sorokit#952: Add transaction preflighting (src/transaction/preflighting.ts) to validate sequence numbers, estimate fees, and check sufficient account balance with low balance warnings. - Fixes Sorokit#955: Add transaction builder fluent API (src/transaction/transactionBuilder.ts, src/transaction/compose.ts) with chainable setter methods returning this. - Fixes Sorokit#956: Add transaction group builder (src/transaction/groupBuilder.ts) to group multiple transactions and manage consecutive sequence numbers. - Fixes Sorokit#957: Add batch account operations (src/account/batchQueries.ts) to fetch multiple accounts and balances in parallel without caching and with graceful error handling. - Re-export new modules and types in src/transaction/index.ts, src/account/index.ts, and src/index.ts. - Add comprehensive test suites for preflighting, fluent builders, group builders, and batch queries.
|
@thatElisha Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #952, Fixes #955, Fixes #956, Fixes #957
Summary of Changes
1. #952 Add transaction preflighting — estimate fees and check account sequence
preflightTransaction(tx, publicKey, options):currentSequence + 1).SorokitResult<PreflightData>.2. #955 Add transaction builder fluent API — chainable setter methods
this/builder:.setSourceAccount(source).setFee(fee).setMemo(memo, type).setTimeout(seconds).setNetwork(network).setSequenceNumber(seq).build()3. #956 Add transaction group builder — combine multiple transactions atomically
TransactionGroupBuilderandcreateTransactionGroupBuilder():.addTransaction(tx)and.addTransactions(txs)to add transactions to the group..setBaseSequence(seq)to define group base sequence.baseSequence + i) for sequential submissions..build()returningSorokitResult<Transaction[]>.4. #957 Add batch account operations — fetch multiple accounts in one request
getAccountsBatch(publicKeys, options)andgetBalancesBatch(publicKeys, options):Promise.allSettledto minimize roundtrips.SorokitResult<AccountInfo[]>andSorokitResult<AssetBalance[][]>.