Repository navigation
fix(not-join): :db/valid-at binds the query's valid time on the per-row path (#615, backport) - #618
Merged
Merged
Conversation
…r-row path (#615) evaluate_not_join matched the body with PatternMatcher::from_slice, so a :db/valid-at pattern bound nil when the body held an expression, sat in an or branch, or ran on the rules query path. It now takes the valid-at value and uses from_slice_with_valid_at, as not_body_matches does. The StratifiedEvaluator passes Value::Null, matching how it matches rule bodies. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PtCdzbJMSS1V8qEPaJ4jXz (cherry picked from commit 90f862c)
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PtCdzbJMSS1V8qEPaJ4jXz
This was referenced Oct 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Backport of #616 (v3) for #615, a data-integrity issue on v2.x. A
:db/valid-atpattern in anot-joinbody boundnilon the per-row path (evaluate_not_join): a body with an expression, anynot-joinin anorbranch, andnot-joinin queries that invoke rules.evaluate_not_joinnow takes the valid-at value and usesfrom_slice_with_valid_at, asnot_body_matchesdoes. Rule definitions are unchanged (they passValue::Null, as their other matchers do); see #617.Cherry-picked cleanly except the CHANGELOG, where the entry goes under
[Unreleased].Verification
cargo test— all green; the three newtests/not_join_test.rscases fail without the fixcargo clippy --all-features -- -D warnings,cargo fmt --check— clean🤖 Generated with Claude Code
https://claude.ai/code/session_01PtCdzbJMSS1V8qEPaJ4jXz