Skip to content

Preserve retry progress when block cleanup fails - #2544

Draft
a-shannon wants to merge 3 commits into
ergoplatform:wallet-pruning-preventionfrom
a-shannon:fix/pr2362-cleanup-progress
Draft

a-shannon wants to merge 3 commits into
ergoplatform:wallet-pruning-preventionfrom
a-shannon:fix/pr2362-cleanup-progress

Conversation

@a-shannon

@a-shannon a-shannon commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Focused follow-up to #2362, targeting its wallet-pruning-prevention branch. Review the three-file correction and the full increment with two upstream CI backports.

Cleanup can advance its progress marker after a returned deletion failure, and marker-write failures are ignored. Persist a missing fallback marker before advancing the retention floor, require successful deletion before writing the next marker, and consume the marker-write result. Failures leave discoverable retry work while preserving the already-recorded best full block.

Five focused tests and the existing wallet-backlog regression pass. They cover deletion, initial/final marker persistence, deferred cleanup and later retry. Independent source and evidence review completed. Current-head CI finished 7/8: integration passed 12/13 executed tests, with one additional test ignored, and ForkResolutionSpec timed out after 15 minutes (run). Cleanup is disabled in that scenario (blocksToKeep=-1, no UTXO bootstrap). The available logs do not locate the stalled fork/restart/synchronization step; no per-node artifacts were retained. A maintainer rerun or diagnostic run remains necessary.

Backports the integration-test image update from #2294 (b1739cb5), replacing openjdk:11-jre-slim with eclipse-temurin:11-jre-jammy. Previous CI stopped while resolving the unavailable image, before integration tests started. Source and test scenarios are unchanged by this backport. If the parent branch adopts the same upstream fix, this duplicate backport can be dropped when rebasing.

The next CI exposed the already-corrected Autolykos negative-sample fixture from #2373, refined in #2291. This branch now uses the exact current-master test hunk: search at most 50 windows for a sample that the validator actually rejects, preserving the positive validation and vectors. The old assumption that the first altered-message solution must be invalid is false at easy test targets. All four focused Scala 2.12 tests pass; independent review completed. Production PoW code is unchanged. All hosted core matrix checks now pass; the integration timeout described above remains open.

Retry occurs on a later eligible block. Reclaiming historical data below the legacy fallback floor remains a separate migration decision. This does not add a power-loss guarantee or duplicate #2523's index-removal result correction.

Backports b1739cb from ergoplatform#2294 for this feature-branch follow-up. Source and test scenarios are unchanged.
Reuse the current-master AutolykosPowSchemeSpec correction from ergoplatform#2373 and ergoplatform#2291. Positive proof validation remains required; the bounded search must find an actually rejected sample. Production PoW code is unchanged.
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