Skip to content

fix: keep a reopened agreement's end record accurate - #732

Merged
MoonBoi9001 merged 3 commits into
mb9/reviewfrom
mb9/keep-the-end-record-right-after-a-reopen
Oct 6, 2026
Merged

MoonBoi9001 merged 3 commits into
mb9/reviewfrom
mb9/keep-the-end-record-right-after-a-reopen

Conversation

@MoonBoi9001

@MoonBoi9001 MoonBoi9001 commented Oct 5, 2026 •

Copy link
Copy Markdown
Member

An agreement found live again after dipper recorded it ended, such as an offer withdrawn then accepted when it landed anyway, now has its real end announced with the right transaction and time: the reopen clears the stale record when the chain showed it live, and any end recorded before the accept gives way to a later one. An agreement the chain listener marks ended just before dipper confirms its own cancel now counts as ended, not a failure.

An agreement reopened because the chain shows it live kept its earlier end on record, such as a
withdrawn offer, so its later real end was announced with the old transaction and time, or never
if one had gone out. That record is now cleared when the chain showed it live.
If the chain listener marked an agreement ended between dipper sending its cancel and
confirming it, the confirm found nothing to update, warned that it failed, and reported the
agreement as still cancelling. It now counts it as ended and logs that at debug level.
A reopen after a failed chain read keeps the end on record, and later cancels only filled blank
fields, so a withdrawn offer's end could still be announced for an agreement accepted after it.
An end recorded before the accept can't be the real one, so a later end now replaces it.
@MoonBoi9001
MoonBoi9001 marked this pull request as ready for review October 6, 2026 15:12
@MoonBoi9001
MoonBoi9001 merged commit 07b2772 into mb9/review Oct 6, 2026
12 checks passed
@MoonBoi9001
MoonBoi9001 deleted the mb9/keep-the-end-record-right-after-a-reopen branch October 6, 2026 15:13
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.

1 participant