TASK-041: Fluid Configuration Section - #43
Merged
Conversation
…t (TASK-041) Stage 5's first task: gives the simulated fluid's physical properties (viscosity, diffusion_coefficient) their own `fluid:` config section, separate from `numerics:`, which selects numerical schemes rather than fluid properties. This is the project's first breaking configuration change -- a config still setting the retired `numerics.diffusion_ coefficient` is rejected with a named error pointing at its new home, not silently defaulted. Also fixes a real gap the roadmap's own drafting missed: it claimed this task had no engine-side dependency, but `assemble_numerics` already read `NumericsConfig.diffusion_coefficient` directly (TASK-024). Moving the field required a real signature change (`assemble_numerics` gained its own `diffusion_coefficient` parameter) plus a `bootstrap.py` call-site update -- recorded honestly in the roadmap rather than fixed silently. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
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
Stage 5's first task: gives the simulated fluid's physical properties (
viscosity,diffusion_coefficient) their ownfluid:config section, separate fromnumerics:(which selects numerical schemes, not fluid properties). This is the project's first breaking configuration change -- a config still setting the retirednumerics.diffusion_coefficientis rejected with a named error pointing at its new home, not silently defaulted.FluidConfigdataclass (viscosity,diffusion_coefficient, both default1.0) added toPyFlowConfig, wired intoload_config.numerics.diffusion_coefficientremoved fromNumericsConfig; a config still setting it fails loudly (loader.py's_numerics_config_from_raw).tests/features/fluid_configuration.feature(4 scenarios) bound bytests/integration/test_fluid_configuration.py-- lives inintegration/, notunit/, since one scenario needs a real CLI subprocess run.docs/implementation/config-template.yaml; migrated the Passive Scalar Transport golden demo's own config.A real gap found while implementing, not predicted by the roadmap's own drafting: TASK-041's Dependencies section claimed "no engine dependency at all," but
engine/numerics/assembly.py'sassemble_numericsalready readNumericsConfig.diffusion_coefficientdirectly (TASK-024). Moving the field required a real signature change --assemble_numericsgained its owndiffusion_coefficient: float = 1.0parameter (default preserves every existing scheme-selection-only caller), andbootstrap.py's call site now threadsconfig.fluid.diffusion_coefficientthrough explicitly. Recorded honestly in the roadmap (a Status note plus a correction in the Dependencies section itself) rather than fixed silently, per this repo's Integrity rule.Blast radius also covers:
tests/unit/numerics/test_assembly.py,tests/unit/test_main.py,tests/unit/test_generator.py,tests/integration/test_cli.py(key-order/field assertions), two architecture diagrams (sequences.md), an ICD signature line (icds.md), an ADR pointer (ADR-002),CLAUDE.mdentries inconfiguration/andengine/, and the roadmap's own live test/scenario-count paragraph (614→622 tests, 54→58 scenarios) plus regeneratedstatus.md/repository-inventory.md.Test plan
make cigreen: 622 tests passing, mypy--strictclean, all doc/graph/scenario/status/config-template checks pass.tests/features/fluid_configuration.featurescenarios andtest_configuration.py's new viscosity tests written and confirmed red before implementation.make check-references/make check-manifest/make check-scenariosall clean against the new files.passive_scalar_transport.yaml) still runs through the real CLI and produces its already-tested quantitative result after migration.🤖 Generated with Claude Code