[pr-fix] Count crash records for the measured benchmark run #173
Loading…
Reference in a new issue
No description provided.
Delete branch "akimfomin/Darner:codex/bench-crash-records"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Contributor role (optional)
Fluxer ID omitted.
What it changes
The benchmark read only
data/crashes.logand counted every line. A title-specific crash file could be missed entirely, while a three-line record in the old layout could inflate the count. A seeded run directory can also contain earlier failures.This change reads both the flat and title-ID layouts, counts record headers and attributes them using the play log’s PID, UTC start and the benchmark’s observation cutoff. Recalculating an older summary without a saved cutoff uses its previous modification time, then preserves that value. If records exist but the run’s process identity is unknown, the summary marks the count as unknown.
How it was tested
57dea7f236. The published tree atdb3d904237matches the locally tested tree at3aa7267713.Invoke-Pester -Script scripts/tests/bench-crashes.Tests.ps1passed 4/4 under Windows PowerShell 5.1 and PowerShell 7.6. Cases cover multiline records, copied history, PID reuse, missing process identity and missing crash logs.cargo run --quiet --locked --offline -p xtask -- policypassed.scripts/bench.ps1 -From. Main reported 0 and the patched summary reported 1. The reproduction used a synthetic console-output file to supply the original play-log filename.Checklist
main.docs/asset-policy.md.Checked for overlap
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.