Skip to content

Monitor revamp followups - #2043

Merged
spacebear21 merged 3 commits into
payjoin:masterfrom
xstoicunicornx:monitor-revamp-followups
Nov 9, 2026
Merged

spacebear21 merged 3 commits into
payjoin:masterfrom
xstoicunicornx:monitor-revamp-followups

Conversation

@xstoicunicornx

@xstoicunicornx xstoicunicornx commented Nov 9, 2026 •

Copy link
Copy Markdown
Collaborator

Follow ups from #2034:

  • cancel --no-broadcast no longer just tells users to broadcast the fallback manually; instead it says the session closed and to broadcast only if the fallback isn't on chain and its inputs are unspent.
  • The close docs in payjoin and payjoin-ffi now explain that the recorded outcome says whether the receiver completed its side of the Payjoin protocol and sent the proposal, not which transaction resolved the session, and that the session doesn't persist the ResolvedBy classification.
  • A new FFI changelog fragment adds migration notes for apps moving from Monitor.check_for_transaction to classify_tx and close_session.

Assigned reviewer is @spacebear21 .

Pull Request Checklist

Please confirm the following before requesting review:

`cancel --no-broadcast` printed "Broadcast the original transaction
manually", while a failed broadcast now points users at --no-broadcast
to close a session whose fallback is already on chain. Following that
hint led to an instruction to broadcast a transaction that may already
be confirmed or have spent inputs.

Say the session closed without broadcasting, and to broadcast the
printed fallback only if it isn't on chain and its inputs are unspent.
The sender and receiver now print the same message.
The outcome a receiver records on close says whether the receiver
completed its side of the Payjoin protocol and sent the Payjoin
proposal, not which transaction resolved the session. A session that
posted its proposal records PayjoinProposalSent even if the fallback
resolved it, and the ResolvedBy classification is not persisted.
Callers could otherwise expect a closed session to remember whether the
Payjoin or the fallback settled it.

State this in the close docs of ReceiveSession, Receiver<S> and the FFI
close_session.
@coveralls

coveralls commented Nov 9, 2026 •

Copy link
Copy Markdown
Collaborator

Coverage Report for CI Build 42720325922

Coverage decreased (-0.02%) to 87.825%

Details

  • Coverage decreased (-0.02%) from the base build.
  • Patch coverage: 6 uncovered changes across 1 file (0 of 6 lines covered, 0.0%).
  • No coverage regressions found.

Uncovered Changes

File Changed Covered %
payjoin-cli/src/app/v2/mod.rs 6 0 0.0%

Coverage Regressions

No coverage regressions found.


Coverage Stats

Coverage Status
Relevant Lines: 18620
Covered Lines: 16353
Line Coverage: 87.82%
Coverage Strength: 313.91 hits per line

💛 - Coveralls

payjoin-ffi removed Monitor.check_for_transaction outright, and the
classify-tx fragment only names the replacement. Apps moving to
classify_tx and close_session also need to know what changed in
behavior. The recorded outcome no longer carries the txid or which
transaction settled. Classification ignores confirmations. A
Resolution does not survive a restart. Malformed bytes raise
TransactionParseError.

The bindings have no separate migration guide, and
payjoin-ffi/CHANGELOG.md is their release notes, so list these in a
changelog fragment.

@spacebear21 spacebear21 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 014e0e3

@spacebear21
spacebear21 merged commit b2154b2 into payjoin:master Nov 9, 2026
34 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants