Conversation
Codecov Report❌ Patch coverage is
@@ Coverage Diff @@
## main #1454 +/- ##
===========================================
- Coverage 75.58% 65.34% -10.24%
===========================================
Files 802 800 -2
Lines 75676 76102 +426
===========================================
- Hits 57200 49730 -7470
- Misses 18476 26372 +7896
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 256 files with indirect coverage changes 🚀 New features to boost your workflow:
|
|
Commit: ada79b1 SP1 Execution Results
|
|
note for myself: we need to implement |
fcc620b to
489fd98
Compare
f97ebd5 to
489fd98
Compare
|
new |
Yes it does. That's why I'm stalled in this PR :/ |
|
something is a bit weird in the tests.... (the fact that checkpoints get final). Closing and reopening to make sure CI uses the correct code. |
barakshani
left a comment
There was a problem hiding this comment.
I believe this PR mixes 2 notions of finalisation (and actually admit it in one of the comments):
- reth has some notion of block finlisation, which I believe it's 100 blocks of confirmation.
- OL has a different notion of (bitcoin) finlisation.
I believe that ExEX kicks in when the block is final (ExecCommand::NewFinalizedTip) according to reth. This PR checks checkpoint (OL) finalisation as some triggering point in time. I may wrong, but this need further investigation. Anyway the test constantly fails right now.
Also left some comment about the correctness of our method to see if files were pruned.
|
|
||
| # Mine L1 blocks while polling Strata status until epoch 1 is confirmed. | ||
| # | ||
| # In functional-tests-new `el_ol`, epoch finalization may not always be available |
There was a problem hiding this comment.
This, ideally, would be fixed in https://alpenlabs.atlassian.net/browse/STR-2424.
functional-tests-new/tests/alpen_client/test_exex_wal_pruning.py
Outdated
Show resolved
Hide resolved
| # | ||
| # In functional-tests-new `el_ol`, epoch finalization may not always be available | ||
| # (for example when no proving/finalization pipeline is wired in the environment), | ||
| # but confirmation still advances with L1 progress and is sufficient to exercise |
There was a problem hiding this comment.
if so, we should not check for finalization, because the test may fail unjustifiably.
|
PR #1479 adds seal config to |
| status_after_finalization = wait_until_with_value( | ||
| lambda: _mine_and_get_sync_status(strata_seq, btc_rpc, mine_address), | ||
| lambda status: status["finalized"] is not None | ||
| and status["finalized"]["epoch"] >= 1, | ||
| error_with="Epoch 1 was not finalized in time", | ||
| timeout=120, | ||
| step=2, | ||
| ) |
There was a problem hiding this comment.
@storopoli To prune wal files, the ideal requirement should be to have the proofs to be generated and stored in db (or might only be witness stored in db 🤔 ). In releases/0.2.0 I waited for OL checkpoint finalization because that was the safest signal to cleanup wal files. And in fast mode epoch could be finalized in seconds there. So we just waited for a finalized checkpoint. And we checked if reth cleaned up wal files.
In main branch, I found out that OL checkpoints never get finalized (which @bewakes confirmed as well) due to which this condition never passes. So I think this whole functional test can be simplified by just having two waits:
- first we wait until we have some
nnumber of wal files - after that we wait until some of those preexisting wal files gets deleted, don't need to wait for all of them to be cleaned up.
In this test we do not care if OL checkpoint finalizes or not. We just want to make sure that the wal files are cleared by reth after sometime.
|
@sapinb do you think this fix is relevant for the Reth issues we experienced in testnet I? |
- Fix ProverWitnessGenerator emitting FinishedHeight with block number 0 (from outcome.first_block()) instead of the real block number, which prevented WAL files from ever being pruned - Add functional test verifying WAL files are pruned after epoch finalization
489fd98 to
c92fffe
Compare
delbonis
left a comment
There was a problem hiding this comment.
The wait calls about WAL files can stay as-is, those are weird and specific so don't make sense in a general-purpose wait helper.
The el_ol environment does not reliably expose checkpoint finalization, so the functional test now only checks that preexisting WAL files eventually disappear. This keeps the pruning assertion stable even while new WAL files are created during block production.
c92fffe to
977333a
Compare
|
@purusang whenever you have time please take a look. |
Description
This is a back ported fix which has already been tested in staging.
Type of Change
Notes to Reviewers
Is this PR addressing any specification, design doc or external reference document?
If yes, please add relevant links:
Checklist
Related Issues