Repository navigation
fix(profiling): accept PyAutoArray's new solver/stats kwargs in the solver injections (PyAutoArray#566) - #299
Merged
Conversation
…ertified solver injection (PyAutoArray#566) Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…y solver injection too (PyAutoArray#566) Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…ibrary lint.yml checks out PyAutoArray main, so asserting the #566 signature made this PR's CI red by construction until PyAutoArray#567 merges; skip there, assert on the new library. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This was referenced Sep 23, 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
PyAutoArray#566 (PR #567) adds two optional keyword arguments,
solver="pdip"andstats=None, toinversion_util.reconstruction_positive_only_from. The profiling harness's solver injections monkeypatch that function and assert (_assert_signature_covers) that the wrapper's signature covers the library's, so against the new library they failed. This PR makes both injections declare the new kwargs and forward them only to a library that accepts them, so the harness runs against the pre-#566 and the #566 library alike. Route (d)'s PDIP fallback now pinssolver="pdip"explicitly, so a library config selecting its own certified solver cannot change what the harness falls back to.Merge order: this PR may only merge AFTER PyAutoLabs/PyAutoArray#567 (library-first gate). This repo's lint workflow checks out PyAutoArray
main, sotest_fallback_pins_the_library_pdip_solver(which needs the #566 signature) skips there until #567 merges and asserts once it has; CI stays green on both.Scripts Changed
scripts/misc/likelihood_breakdown/library_solver_injection.py— certified injection declaressolver/stats, forwards them via_library_kwargsonly when the library has them; fallback pinssolver="pdip".scripts/misc/likelihood_breakdown/fixed_light_numpy_solvers.py— numpy solver injection declaressolver/statsand forwards them on the delegated JAX path only to a library that accepts them (inlined, no JAX import); injected kernel renamedinjectedto free thesolverkeyword.scripts/misc/test/test_fixed_light_library.py— tests for kwarg forwarding (old + new signature) and the pinned PDIP fallback (skips on a pre-#566 library).scripts/misc/test/test_fixed_light_numpy_solvers.py— tests for the numpy injection's signature coverage and forwarding.Upstream PR
PyAutoLabs/PyAutoArray#567
Test Plan
pytest scripts/misc/testagainst the NEW library (#567 branch,activate.sh): 795 passed / 5 skipped / 0 failed.pytest scripts/misc/testagainst the OLD library (PyAutoArray main 22e6d608 first on PYTHONPATH): 794 passed / 6 skipped / 0 failed — the extra skip istest_fallback_pins_the_library_pdip_solver, whichpytest.skips whenreconstruction_positive_only_fromhas nosolverkwarg (commit 2b013f9); every harness path (old-signature forwarding included) passes, so the harness still works pre-release.ruff check .clean;ruff format --check .clean (208 files);build_readme.py --checkexit 0;wall/check_submits.py --check0 failing.AUTOLENS_PROFILING_SMOKE=1 python scripts/imaging/likelihood_breakdown/fixed_light_trace.py --mesh delaunayexit 0.Heart RED override
release validation FAILED (stage integrate); YELLOWworkspace validation not passing (4 failed, cloud#35579888156: autolens notebooks/cluster/modeling.ipynb, autolens notebooks/weak/a2744.ipynb, autolens scripts/cluster/modeling.py, +1 more); YELLOWmanifest drift: hub organism blurb (organs present) — 7 mismatch(es) vs PyAutoMind/repos.yaml. Freeze: not frozen.i authorize,to the named issue-#566 (+ linked autolens_profiling fix) development override, per AUTONOMY.md "Human override for Heart RED (development only)"./prm, after PyAutoArray#567 merges and with required checks green.Generated by the PyAutoLabs agent workflow.
🤖 Generated with Claude Code