8000 Merge main into v3: bench issue branch names (#566), Bencher window (#568), v2.0.5, v2.x fixes by adityamukho · Pull Request #569 · project-minigraf/minigraf · GitHub
[go: up one dir, main page]

Skip to content

Merge main into v3: bench issue branch names (#566), Bencher window (#568), v2.0.5, v2.x fixes - #569

Merged
adityamukho merged 15 commits into
v3from
merge/main-into-v3-bench-branch
Oct 13, 2026
Merged

adityamukho merged 15 commits into
v3from
merge/main-into-v3-bench-branch

Conversation

@adityamukho
@adityamukho adityamukho commented Oct 13, 2026 •
Copy link
Copy Markdown
Collaborator

Merges main into v3 (merge commit). Brings in:

Resolution

Checks

cargo test --quiet: 1431 passing, 0 failed, 11 ignored (1442 total). fmt clean.

🤖 Generated with Claude Code

https://claude.ai/code/session_01HyLscCUuJ1GQpdAeX79EdR

adityamukho and others added 14 commits October 11, 2026 11:04
Backport of the v3 fix (#534) to v2.x. RecursiveEvaluator seeded
seen_facts with every base fact and compared its size with max_results,
so on a database with max_results (default 1,000,000) live facts every
rule query failed with INT-020 at its first derived fact, whatever the
size of its answer. The limit now counts only the facts the rules derive.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012wXxZguv7PgKQjMMH4yJ5h
fix(query): count only derived facts against max_results (#528, v2.x backport)
…lose-time save (#457, #476)

Backport of #525 and #526 (v3) to v2.x.

- #457: do_checkpoint's early return (nothing to flush) now deletes a
  WAL whose entries are all already in the file, and syncs the parent
  directory. The golden-corpus test requires v7_stale_wal to have no WAL
  after a checkpoint.
- #476: Inner::drop under wal_checkpoint_threshold(usize::MAX) discards
  the storage's dirty flag, so PersistentFactStorage::drop saves nothing;
  the WAL keeps the pending facts for the next open. OpenOptions field
  docs say what usize::MAX does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012wXxZguv7PgKQjMMH4yJ5h
fix(db): stale WAL removed by checkpoint; usize::MAX threshold skips close-time save (#457, #476, v2.x backport)
Doc sync (CHANGELOG, CLAUDE.md, ROADMAP, README, TEST_COVERAGE) and
version bump to 2.0.5. v2.x patch: a sub-page file is refused with
STG-045 unless it is a torn first write (#506); a commit after a torn
WAL entry is no longer lost, failed appends poison the handle with
WAL-007 (#513); backports of #528, #457 and #476 from v3; weekly soak
test (#392) and working coverage gates (#396). File format v7
unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012wXxZguv7PgKQjMMH4yJ5h
Backport of the v3 fixes (PRs #556, #557) to v2.x.

#554: commits added a transaction's facts to FactStorage one load_fact
call at a time, each under its own write lock, so a query on another
thread could see part of the transaction. FactStorage::load_facts
appends a batch under one lock; execute, WriteTransaction::commit, WAL
replay and BrowserDb's commit use it.

#555: selective_fact_fetch read each entity/attribute lookup under its
own read lock, so a commit between two lookups was seen by some
patterns and not others. The three lookup bodies become functions over
&FactData and FactStorage::get_facts_for_lookups runs them all under one
read guard. The old methods remain for tests only.

The file-backed #555 reproducer disables checkpoints: on v2.x a query
that runs during a checkpoint can lose committed facts, a separate bug.

Refs #554, #555

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012wXxZguv7PgKQjMMH4yJ5h
…f-written (#558)

save() appends the new fact pages at 1 + old_fact_page_count, over the
pages of the index that queries on other threads read through the
published CommittedIndexReader, and then published the new readers and
cleared the pending facts with three separately locked calls. A query
during a checkpoint could miss committed facts or see part of a
transaction.

FactStorage::lock_for_checkpoint returns a guard on the store's write
lock. save() takes it before the backend lock (the order queries use:
store read lock, then backend), reads the pending facts through it, and
publishes both readers and clears pending in one step
(CheckpointGuard::publish). get_pending_facts and post_checkpoint_clear
are now test-only.

v3 is not affected (copy-on-write checkpoints).

Refs #558

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012wXxZguv7PgKQjMMH4yJ5h
fix: queries see whole transactions and one state per query (#554, #555)
fix(storage): queries wait for a checkpoint instead of reading it half-written (#558)
Issues for main were titled "Benchmark regression: <suite>" with no
branch, while v3 issues carried "(v3)". Title every issue
"Benchmark regression: <suite> (<branch>)", like the nightly fuzz
issue, and add a Branch line to the body. An open issue with the old
main title is still matched, renamed and commented on.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HyLscCUuJ1GQpdAeX79EdR
ci(bench): name the branch in every regression issue
Brings in #566 (every nightly benchmark regression issue names its
branch), the v2.0.5 release and the v2.x backports #538, #540, #559
and #560.

Resolution: v3 keeps its own fixes for #528, #457, #476, #554 and
#555, so src/ and the conflicting tests keep v3's side; main's copy of
the #476 test in tests/wal_test.rs is dropped (v3 already has it).
#558 is v2.x only (v3's copy-on-write checkpoints are not affected),
but its race test `checkpoint_never_hides_committed_facts` is added to
tests/snapshot_atomicity_test.rs as a guard; it passes on v3.
CHANGELOG gains the v2.0.5 section; Cargo.toml version follows main
(2.0.5). Test count: 1442 (1431 passing, 11 ignored).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HyLscCUuJ1GQpdAeX79EdR
)

Bencher's t-test used every sample since May, so a correct step change
kept alerting for weeks: query/pre
8000
dicate_pushdown/100k since #445
(#512, #495), and checkpoint/* and open/wal_replay/100k since #476's
backport stopped the drop-save that had made those fixtures no-ops
(#561, #562). Replaying main's history, a 30-run window still alerts on
two runs in a row for a lasting change, then takes it as the baseline
after about five runs.


Claude-Session: https://claude.ai/code/session_016QAt9R1aSPQG7rV5ouFDMU

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016QAt9R1aSPQG7rV5ouFDMU
@adityamukho adityamukho changed the title Merge main into v3: bench issue branch names (#566), v2.0.5, v2.x fixes Merge main into v3: bench issue branch names (#566), Bencher window (#568), v2.0.5, v2.x fixes Oct 13, 2026
@adityamukho
adityamukho merged commit 090829f into v3 Oct 13, 2026
23 checks passed
@adityamukho
adityamukho deleted the merge/main-into-v3-bench-branch branch October 13, 2026 05:41
@codecov
codecov Bot commented Oct 13, 2026
Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

adityamukho added a commit that referenced this pull request Oct 13, 2026
docs: v2.0.5 status line and test counts on v3 after #569
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

0