Skip to content

fix: harden result caches and query regression coverage - #588

Merged
savasp-agent[bot] merged 4 commits into
mainfrom
codex/paul-regression-coverage
Nov 13, 2026
Merged

savasp-agent[bot] merged 4 commits into
mainfrom
codex/paul-regression-coverage

Conversation

@savasp-agent

@savasp-agent savasp-agent Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Qualify the combined changes in #579, #580, #581, #582, #583 and #585 against their query, mutation and CLR lifetime contracts. This PR is based on merged #585 (615f5348), with no stack dependency.

Fix result caches that retained constructed generic types with collectible arguments, node-label property metadata and diagnostic target keys. Respect non-default contextual reflection instead of returning a default-context cached type for the same assembly identity. Publish the discovered-type array and its assembly generation as one immutable snapshot so readers cannot mark an old scan current.

Add 19 serialization lifetime/context/late-load/warm-reuse cases, two provider-neutral TCK contracts for synchronous Count/LongCount composition and overlapping-edge delete preflight, and two AGE commit/rollback cases for derived index/aggregate state. Strengthen failed-provisioning postconditions to verify catalog rollback and subsequent CRUD. The TCK inventory grows from 502 to 504 methods. Existing AGE matrix jobs now retain Cobertura coverage alongside their test results, using the existing collector and artifact path.

Closes #587.

Coverage and design assessment

The pre-change full-provider CI artifacts at #585 head 546cd550 give the baseline below. The new reports use the same Release/Linux configuration; this PR also collects AGE 1.8 coverage. Line hits are unioned across project reports by source file/line; generated files and the TCK package are excluded.

Production surface Baseline covered / executable lines This PR, including AGE 1.8
Core/query 4,378 / 4,883 (89.7%) 4,378 / 4,883 (89.7%)
Shared Cypher 3,482 / 3,883 (89.7%) 3,482 / 3,883 (89.7%)
AGE 8,940 / 10,565 (84.6%) 9,015 / 10,565 (85.3%)
Serialization 2,145 / 2,542 (84.4%) 2,167 / 2,545 (85.1%)

These are whole-surface line measurements, not changed-line or branch coverage. That job executes AGE 1.7; the separate 1.8 matrix already executed native-path tests but did not publish coverage. The new matrix flag closes that visibility gap. The native shortest-path planner now measures 234/257 lines (91.1%), compared with 173/257 (67.3%) in the earlier report. Much of the AGE increase exposes previously executed 1.8 behavior rather than new tests; the serialization and transaction contracts add semantic protection beyond line totals. Current coverage artifacts retain the full-suite and both matrix reports. Four runtime regression groups reproduced cache failures before their fixes; the snapshot fix has a concrete publication interleaving, without a claimed deterministic runtime race reproduction.

The provider design retains useful boundaries: typed fast-path eligibility and catalog/version checks; ordinary execution when a plan is inapplicable; explicit rejection of unsupported path compositions; native paths through shared hydration; and transactional coupling of label, companion and aggregate writes. No query/storage redesign was justified. The new tests verify these compositions across the provider bindings and the transaction/maintenance boundaries that lacked direct coverage.

Test plan

  • Complete fast lane with coverage: 2,584 passed, 3 expected skips, eight projects.
  • Complete strict AGE matrix with coverage, run serially: 1.7.0 had 920 passed / 13 expected skips; 1.8.0 had 932 passed / 1 expected skip.
  • Complete strict Neo4j lane with coverage: 619 passed, no skips.
  • Package-reference validation passed for the expanded public TCK assembly.
  • Focused serialization 19/19 and AGE boundary/contract 9/9; validation inventory, changed-file format and whitespace checks passed.
  • Installed pre-push Release build and full format gate passed.
  • All 16 hosted checks passed on 18dfcc64: full provider suite, both AGE versions and three-platform package validation, CodeQL, documentation, dependency review and repository checks. Coverage artifacts for both AGE versions were downloaded and verified.

Recommendations and limits

Keep differential ordinary/optimized execution and transaction/error-path tests as the acceptance criteria when broadening fast-path eligibility. Preserve the named rejection boundary for unsupported path compositions. Assess declared-index/aggregate read gains together with write amplification, maintenance cost and contention for the intended workload; historical performance benchmarks were not rerun here.

The cache tests establish result-cache lifetime/context guarantees. They do not certify complete plugin/provider/schema/serializer unloading. The existing conservative label-discovery policy can still rescan while collectible assemblies remain loaded, so plugin-heavy throughput is a workload to measure separately. No required finding is deferred and no separate architectural follow-up is needed to land these corrections.

Co-authored-by: Savas Parastatidis 39513442+savasp@users.noreply.github.com

savasp-agent Bot and others added 4 commits November 13, 2026 14:18
Co-authored-by: Savas Parastatidis <39513442+savasp@users.noreply.github.com>
Co-authored-by: Savas Parastatidis <39513442+savasp@users.noreply.github.com>
…shots atomically

Co-authored-by: Savas Parastatidis <39513442+savasp@users.noreply.github.com>
Co-authored-by: Savas Parastatidis <39513442+savasp@users.noreply.github.com>
@savasp-agent
savasp-agent Bot requested review from a team and savasp November 13, 2026 22:32
@savasp-agent
savasp-agent Bot enabled auto-merge November 13, 2026 22:32
@savasp-agent
savasp-agent Bot disabled auto-merge November 13, 2026 22:43
@savasp-agent
savasp-agent Bot enabled auto-merge November 13, 2026 22:43
@savasp-agent
savasp-agent Bot added this pull request to the merge queue Nov 13, 2026
Merged via the queue into main with commit 001fd90 Nov 13, 2026
16 checks passed
@savasp-agent
savasp-agent Bot deleted the codex/paul-regression-coverage branch November 13, 2026 23:06
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.

Harden regression coverage for recent query and serialization optimizations

1 participant