mirror of
https://github.com/logos-blockchain/lssa.git
synced 2026-04-12 22:23:11 +00:00
debugging
This commit is contained in:
parent
e6ad1d3eea
commit
35b7712b12
14
.github/workflows/ci.yml
vendored
14
.github/workflows/ci.yml
vendored
@ -213,13 +213,19 @@ jobs:
|
||||
if: failure()
|
||||
run: |
|
||||
kill "$(cat /tmp/log-watcher.pid)" 2>/dev/null || true
|
||||
# Filter out noisy gossipsub/overwatch lines that bloat the log without helping debug.
|
||||
NOISE='gossipsub|libp2p_gossipsub|overwatch::overwatch::(handle|runner)|services::state::handle'
|
||||
for f in /tmp/container-logs/*.log; do
|
||||
[ -e "$f" ] || continue
|
||||
echo "=== $f (lines: $(wc -l < $f)) ==="
|
||||
echo "--- proposed-block events with removals ---"
|
||||
grep -B 200 -A 5 -E '\([1-9][0-9]* removed\)' "$f" | tail -3000 || true
|
||||
echo "--- mempool/tx/inscribe activity ---"
|
||||
grep -i -E 'mempool|inscrib|verif|reject|invalid|gas|validate|removed' "$f" | tail -1000 || true
|
||||
echo "--- proposed-block events with removals (denoised) ---"
|
||||
grep -v -E "$NOISE" "$f" \
|
||||
| grep -B 200 -A 5 -E '\([1-9][0-9]* removed\)' \
|
||||
| tail -3000 || true
|
||||
echo "--- mempool/tx/inscribe activity (denoised) ---"
|
||||
grep -v -E "$NOISE" "$f" \
|
||||
| grep -i -E 'mempool|inscrib|verif|reject|invalid|gas|validate|removed' \
|
||||
| tail -1000 || true
|
||||
done
|
||||
|
||||
valid-proof-test:
|
||||
|
||||
@ -25,25 +25,32 @@ const L2_TO_L1_TIMEOUT_MILLIS: u64 = 900_000;
|
||||
/// or until [`L2_TO_L1_TIMEOUT_MILLIS`] elapses. Returns the last indexer block
|
||||
/// id observed.
|
||||
async fn wait_for_indexer_to_catch_up(ctx: &TestContext) -> u64 {
|
||||
let deadline = tokio::time::Instant::now() + Duration::from_millis(L2_TO_L1_TIMEOUT_MILLIS);
|
||||
loop {
|
||||
let seq = sequencer_service_rpc::RpcClient::get_last_block_id(ctx.sequencer_client())
|
||||
.await
|
||||
.unwrap_or(0);
|
||||
let ind = ctx
|
||||
.indexer_client()
|
||||
.get_last_finalized_block_id()
|
||||
.await
|
||||
.unwrap_or(1);
|
||||
if ind >= seq && ind > 1 {
|
||||
info!("Indexer caught up: seq={seq}, ind={ind}");
|
||||
return ind;
|
||||
let timeout = Duration::from_millis(L2_TO_L1_TIMEOUT_MILLIS);
|
||||
let mut last_ind: u64 = 1;
|
||||
let inner = async {
|
||||
loop {
|
||||
let seq = sequencer_service_rpc::RpcClient::get_last_block_id(ctx.sequencer_client())
|
||||
.await
|
||||
.unwrap_or(0);
|
||||
let ind = ctx
|
||||
.indexer_client()
|
||||
.get_last_finalized_block_id()
|
||||
.await
|
||||
.unwrap_or(1);
|
||||
last_ind = ind;
|
||||
if ind >= seq && ind > 1 {
|
||||
info!("Indexer caught up: seq={seq}, ind={ind}");
|
||||
return ind;
|
||||
}
|
||||
tokio::time::sleep(Duration::from_secs(2)).await;
|
||||
}
|
||||
if tokio::time::Instant::now() >= deadline {
|
||||
info!("Indexer catch-up timed out: seq={seq}, ind={ind}");
|
||||
return ind;
|
||||
};
|
||||
match tokio::time::timeout(timeout, inner).await {
|
||||
Ok(ind) => ind,
|
||||
Err(_) => {
|
||||
info!("Indexer catch-up timed out: ind={last_ind}");
|
||||
last_ind
|
||||
}
|
||||
tokio::time::sleep(Duration::from_secs(2)).await;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user