Skip to content

fix: resolve timestamp heuristic, event sequence gap, network passphrase validation, and Module49 progress bugs (#544, #543, #542, #546) - #592

Open
Sweet-Kid wants to merge 6 commits into
conduit-protocol:mainfrom
Sweet-Kid:fix/sdk-bugfixes-544-543-542-546
Open

fix: resolve timestamp heuristic, event sequence gap, network passphrase validation, and Module49 progress bugs (#544, #543, #542, #546)#592
Sweet-Kid wants to merge 6 commits into
conduit-protocol:mainfrom
Sweet-Kid:fix/sdk-bugfixes-544-543-542-546

Conversation

@Sweet-Kid

Copy link
Copy Markdown

PR Description

Bug Fixes

…digit-count heuristic

The old threshold (value < 1e12 ⇒ seconds) misclassified pre-2001
millisecond timestamps and post-33658 second timestamps. Use digit
count instead: 10 digits ⇒ seconds, 13 ⇒ ms.
…faces

Events without a topics[2] sequence slot will carry undefined for
sequence, matching the updated dispatchEvent return behavior.
…quence topic

dispatchEvent previously returned 0n for events without topics[2],
which caused spurious onGap calls and reset lastSequence to 0n.
Now returns undefined so the poll loop's sequence !== undefined guard
works correctly.
…Transaction objects

KeypairWalletAdapter.signTransaction previously ignored opts.networkPassphrase
when given a Transaction object, allowing a testnet-signed transaction to be
validly signed for mainnet. Now asserts tx.networkPassphrase matches the
caller's opts.networkPassphrase before signing (when both are defined).
…gress/normalizeProgress

Module49.processSingleItem reimplemented progress logic (returning 0.5
for open-ended streams) instead of using the shared utils.streamProgress
and normalizeProgress. This duplicated Module48's pre-conduit-protocol#433 bug and
diverged from the canonical NaN→0.5 mapping. Now delegates to the
shared functions like Module48.
…defined for missing sequence

The clawback event in the test has only 2 topics (no topics[2] sequence
slot), so sequence is now undefined instead of 0n.
@drips-wave

drips-wave Bot commented Aug 31, 2026

Copy link
Copy Markdown

@Sweet-Kid 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! 🚀

Learn more about application limits

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