|
STAR
Cal STAR — firmware, DAQ server, and engine design
|
Variables | |
| list | CODE_CONSTANTS |
Physics constants and hardcoded design assumptions that live in code, not in a config field.
The UI's Parameters workspace ("In code" section, ``GET /api/config/parameters`` ->
``backend/routers/config.py``) reads ``CODE_CONSTANTS`` so every number that shapes a result but
has no ``Param``/schema-field provenance is at least visible, per CLAUDE.md's "every number
describing hardware carries a provenance" rule -- this module is the register for the numbers that
don't yet.
Each entry is a physics constant, a named lookup table, or a hardcoded threshold read straight out
of the current source (not a schema field's Python default, and not a config-editable
``design_requirements``/``Setup`` value, even one with no dedicated UI field -- those already have a
YAML path and are excluded here to avoid duplicating the Configuration tab). ``where`` is
``path/module.py:function_or_symbol`` (never a line number: lines move). ``affects_results`` is
True when the constant is on the live default path for at least one shipped injector/propellant
combination; False when it only feeds a diagnostic, a report-only model, or a legacy/inactive path.
Scope (2026-09-26, after the overnight physics pass in wave1_layer1/combustion/injector/
thermal_chamber.md and report_wave2a.json): engine/core, engine/pipeline,
engine/optimizer/layers/layer1_static_optimization.py, engine/core/injectors/layout.py,
ui/flight_sim.py. Excludes unit conversions (PSI, IN, RANKINE_PER_KELVIN, ...), array/grid sizes and
solver iteration counts/tolerances (MACH_SOLVER_MAX_ITERATIONS, PC_BRACKET_SCAN_POINTS, ...).
See also: docs/hidden-physical-parameters.md (parameters with a config path but no form field --
a different, overlapping list) and tests/test_code_constants.py (schema + existence check).
| list engine.pipeline.code_constants.CODE_CONSTANTS |
Definition at line 31 of file code_constants.py.