feat: add change-server support for ripple, tezos, and tron#1041
Open
bobbythelobster wants to merge 5 commits into
Open
feat: add change-server support for ripple, tezos, and tron#1041bobbythelobster wants to merge 5 commits into
bobbythelobster wants to merge 5 commits into
Conversation
Author
Update: Polling Loops Now Gated Behind usesChangeServerCommit: The implementation has been refined to fully disable polling loops when change-server is active, matching the Ethereum pattern. This eliminates any redundant network calls. Why block height polling is omitted:For Ripple, Tezos, and Tron:
When
When
Tests: ✅ 431 passing |
Author
Update: Change-server integration tests addedCommit: Added 35 tests in
All 35 tests passing. The 2 pre-existing failures are unrelated (Ripple blockHeight test times out because it depends on the polling loop which is now correctly gated; FTM fee test has a missing fixture). |
Enable change-server protocol integration for XRP, Tezos, and Tron engines following the contract defined in edge-core-js PR EdgeApp#718. Each engine now: - Sets usesChangeServer: true in currencyInfo - Implements syncNetwork() for change-server wakeups - Calls onSubscribeAddresses() on startup - Retains existing polling as fallback
When change-server is active, syncNetwork drives all sync work including block height, account balance, and transaction checks. Polling loops are only needed as fallback when change-server is off. Block height polling is omitted even in syncNetwork for a specific reason: requiredConfirmations defaults to 1, so transactions confirm immediately upon inclusion (blockHeight > 0). Block height updates happen naturally as a side effect of account and transaction queries, making dedicated polling unnecessary. This change ensures zero redundant network calls when change-server is enabled, matching the Ethereum pattern where core owns the sync schedule.
102f0e5 to
c8be3c2
Compare
Verify contract conformance with edge-core-js PR EdgeApp#718: - usesChangeServer flag set on currencyInfo - onSubscribeAddresses called on startEngine with wallet address - syncNetwork exists and returns positive interval - syncNetwork handles initial sync (subscribeParam == null) - syncNetwork handles address wakeup (needsSync = true) - syncNetwork handles caught-up state (needsSync = false) - Polling loops disabled when usesChangeServer is true - subscribedAddresses restored from core with checkpoints - Tron: checkTokenBalances available for syncNetwork - Tron: fee update loop always active (matches Ethereum pattern) 35 new tests, all passing.
c8be3c2 to
d53242e
Compare
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.
Enable change-server protocol integration for XRP, Tezos, and Tron engines following the contract defined in edge-core-js PR #718.
Changes
Contract compliance (per edge-core-js PR #718)
Relates to Asana task 1213394471711297