Keep failed static linear solutions cache-free#1094
Conversation
|
Audit verification scratchpad:
|
|
Scheduled CI checkpoint (2026-07-15 08:33 EDT):
No observed failure at this checkpoint is attributable to this PR. This is an interim checkpoint, not a claim that the full CI matrix or the targeted jobs have passed. |
|
Final CI follow-up (checked 2026-07-16 12:42 EDT): 50 checks succeeded, 5 failed, and 4 were skipped. Both target AD lanes and all Core lanes are green. Remaining reds are Trim repaired separately by #1093, QA/KLU repaired separately by #1095, the existing NonlinearSolve downstream failure, and excluded downgrade jobs. The formerly queued Ginkgo and GPU checks completed successfully. |
Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
005caa9 to
a10fe12
Compare
|
Post-rebase verification (2026-07-16): rebased commit |
|
One-hour post-rebase CI checkpoint (2026-07-16 14:28 EDT): 49 checks succeeded, 5 failed, 4 were skipped, and only the self-hosted GPU job remains queued. Both target AD lanes are green. The five completed reds are Trim repaired independently by #1093, QA/KLU repaired independently by #1095, the separately tracked NonlinearSolve downstream job, and excluded documentation/downgrade jobs. No completed failure is attributable to this focused static-cache change; the queued GPU job is still pending and this is not a claim that the entire matrix has completed. |
|
Independent clean-main follow-up completed:
The same two-line fix addresses both the LTS and current-Julia inference failures without weakening or skipping any test. |
Releases unreleased fixes on master: KLU JET inference paths (#1095) and cache-free static failure solutions (#1094). Claude-Session: https://claude.ai/code/session_01SFmcAmLrGPrGtzwP333mX8 Co-authored-by: ChrisRackauckas-Claude <accounts@chrisrackauckas.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Ignore this PR until it has been reviewed by @ChrisRackauckas.
Summary
nothingas the solution cache when static LU/GESV factorization reports failureSMatrixLU and GESV solves with a lightweight-solution regressionThe successful static paths already return cache-free
LinearSolutionobjects. The failure paths instead passed the problem as the cache, which violates the LinearSolve 5 lightweight-solution invariant and makes otherwise successful static solves infer a union ofcache::Nothingandcache::LinearProblem.Root cause
An automated
git bisectfroma9b13cfathrough clean main0496f135identified459445950ef413fe96ed78d0b1507aca7abe591c(LinearSolve 5.0 lightweight solutions) as the first bad commit.Explicit adjacent validation on Julia 1.10.11 confirmed:
a9b13cfa: the reduced static LU@inferred solve(...)passes and returns a successful solution withcache::LinearProblem45944595: the same call fails inference because the successful return hascache::Nothingwhile the singular-failure branch still hascache::LinearProblemMaking both static LU and GESV failure returns cache-free restores one concrete return type and completes the intended LinearSolve 5 behavior.
Local verification
On commit
a10fe1283009e27d7499ce4d3239bfcaf3046b33:GROUP=AD: Mooncake 41/41; Static Arrays 23 pass + 1 pre-existing broken; Caching 49 pass + 23 pre-existing broken; Enzyme 47/47;Pkg.test()exited 0GROUP=AD: the same counts passed;Pkg.test()exited 0@inferredreproducer: passed on Julia 1.10.11 and 1.12.6 withsol.cache === nothingGROUP=Core: exited 0; the modified Lightweight Solution testset passed 43/43, and all remaining Core testsets passed with only their pre-existing broken tests--check .: exited 0git diff --check: exited 0CI
The PR's AD jobs pass on Julia LTS and current, and Core passes on Julia LTS, current, and pre-release. The remaining red checks are unrelated baseline/external failures (including the PyAMG documentation link returning HTTP 429, the clean-main KLU JET failure tracked in #1095, and the Trim environment compatibility failure tracked in #1093).