Skip to content

fix: stop paying an indexer twice while its cancel is retried - #718

Merged
MoonBoi9001 merged 5 commits into
mb9/reviewfrom
mb9/keep-cancelling-indexers-out-of-selection
Oct 2, 2026
Merged

MoonBoi9001 merged 5 commits into
mb9/reviewfrom
mb9/keep-cancelling-indexers-out-of-selection

Conversation

@MoonBoi9001

Copy link
Copy Markdown
Member

While dipper is still retrying an on-chain cancel, the agreement's indexer is now kept out of selection for that deployment, an end the indexer made is read from the contract rather than assumed to be dipper's after an hour, and the retry checks agreements that may still be paying an indexer first, up to 50 per run instead of 10.

An agreement dipper is still cancelling may be live and paying its indexer, yet IISA wasn't told
to skip that indexer, so it could be picked again and paid twice. It now goes on the deployment's
declined list, which blocks a pick without counting it as part of the group.
The cancel retry marked an accepted agreement it found ended as cancelled by dipper after an hour,
even when the indexer had ended it, so the wrong end was announced. It now reads who ended it from
the contract, and leaves an end by the indexer for the chain listener to record as theirs.
The cancel retry took 10 agreements per run, oldest check first, so offers nobody had accepted could
hold up a live agreement for hours. It now takes up to 50, putting first those accepted or past their
offer deadline, and its 30 second time limit decides how many it gets through.
An agreement the indexer ended was left for the chain listener to record, so if the listener never
did, it stayed cancelling for good and its indexer was kept out of selection. After an hour, the
cancel retry now marks it cancelled by the indexer itself, naming them as the one who ended it.
Agreements that may be paying an indexer were always retried first, so if enough of them kept failing,
offers an indexer could still accept were never retried. Those agreements now get an hour's head
start instead, so an offer left unchecked for over an hour still gets its turn.
@MoonBoi9001
MoonBoi9001 added this pull request to stack #723 October 2, 2026 22:01
@MoonBoi9001
MoonBoi9001 removed this pull request from stack #723 October 2, 2026 22:01
@MoonBoi9001
MoonBoi9001 added this pull request to stack #724 October 2, 2026 22:04
@MoonBoi9001
MoonBoi9001 marked this pull request as ready for review October 2, 2026 22:04
@MoonBoi9001
MoonBoi9001 removed this pull request from stack #724 October 2, 2026 22:10
@MoonBoi9001
MoonBoi9001 added this pull request to stack #725 October 2, 2026 22:10
@MoonBoi9001
MoonBoi9001 merged commit d7349e6 into mb9/review Oct 2, 2026
12 checks passed
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