mind: correct and close out the autofit all-ones ell_comps bug - #184
Merged
Conversation
…ot cause Ran the investigation end-to-end against library main: the crash is in MockResult's fallback MockSamplesSummary(model=model), consumed by Result.instance inside search.fit() — not a database/aggregator round-trip. Records the validated fix, the three-suite regression evidence, the ag.m.MockResult API-narrowing wart, and a cloud-session repro recipe. Resizes the task from too-large to small: the workspace half already shipped. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XqpBSWF2JDx4L9g1YCQk67
Implemented on claude/autofit-mock-ones-parameters-bug-sv303m in PyAutoFit (prior_median_kwargs helper + 4 regression tests) and PyAutoGalaxy (MockResult forwards samples_summary). Records the post-implementation three-suite validation and narrows remaining scope to one optional tidy-up. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XqpBSWF2JDx4L9g1YCQk67
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XqpBSWF2JDx4L9g1YCQk67
PyAutoFit#1471 and PyAutoGalaxy#569 both merged. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XqpBSWF2JDx4L9g1YCQk67
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.
What this is
Rewrites
draft/bug/autofit/mock_all_ones_parameters_break_ell_comps_guard.mdafter running the investigation it asked for. The fix itself is PyAutoFit#1471 and PyAutoGalaxy#569.Why the prompt needed correcting
Its root-cause theory was wrong in three material ways, and would have sent a developer down a dead end:
search.fit(...), beforeaf.Aggregator.from_databaseis ever called._fit_fastevaluates at[prior.mean ...], which is 0.0 forell_comps— valid." The vector is fine. The crash is on the very next line (mock_search.py:82,self.result.instance), which builds an instance from the summary.MockSamplesSummary.default()… not a dict of 1.0s." Correct, and that is why the search-side summary was a dead end — but the reaching path isMockResult's fallbackMockSamplesSummary(model=model), a different construction site the prompt never checked.The prompt's "DISPROVEN — do not re-tread" note about
parameter_list_with_physical_ell_compsstands and is preserved:model.all_pathsandmodel.unique_prior_pathsare both sorted by prior id, so its index alignment is correct.Also recorded
autogalaxy_workspace_testdocs: plan the multi_galaxy/group/cluster lensing-regime split (epic + 9 child prompts) #104,autolens_workspace_testprompt: record latex-raw-string-docstrings as shipped (#491) #256) — hours after Heart run 31356506626 sampled them. The ticket was filed against stale evidence.ag.m.MockResultdroppedsamples_summaryfrom its signature, so callers could not avoid the bad fallback at all. That is PyAutoGalaxy#569.PYTHONPATH(an editable install is refused on Python 3.11 becauseautonervesnow requires>=3.12).too-large(score 17) tosmall. The original sizing assumed 3-repo library+workspace coordination; the workspace half was already shipped.Remaining scope is narrowed to one optional tidy-up: having
MockSearchinheritsamples_summaryfrom a passed-inresultrather than silently defaulting. No longer a correctness issue after the fix, and it touches ~55 call sites, so it belongs in its own change.Generated by Claude Code