refactor: separate EnvironmentConfig from SLURM allocation - #41
Conversation
Implementation PlanProblem AnalysisThe current Deliverables
Acceptance Criteria
Files to Create or Modify
Testing Approach
Risks and Open Questions
Plan created by mach6 |
- Add EnvironmentConfig model (modules, pixi_manifest, conda_env, venv_path, extra_init) - compose_worker_init() produces shell snippet from structured fields - detect() classmethod auto-detects pixi/conda/venv from environment - Refactor TUI into 3 visual sections with Rich Rule separators - Remove dead _detect_gromacs_modules (shadowed definition) - Update docs and example YAML to new environment: section format
Progress UpdateImplemented the full refactor — replaced ChangesNew files:
Core changes:
Tests and docs:
Verification
Commit: Progress tracked by mach6 |
Code ReviewImportant1. Unquoted paths in Two shell snippets embed filesystem paths without shell-quoting: f'eval "$(pixi shell-hook --manifest-path {self.pixi_manifest} -e default)"'
f"source {self.venv_path}/bin/activate"A path with spaces breaks both commands silently — workers start but have no Python environment. Jobs then fail with 2. conda_path = Path(conda_prefix)
kwargs["conda_env"] = conda_path.nameWhen the base environment is active, Suggestions3. 4. 5. 6. Redundant mutual-exclusivity re-derivation in 7. 8. 9. Strengths
Agents run: code-reviewer, error-auditor, test-reviewer, completeness-checker, simplifier Reviewed by mach6 |
Review AssessmentClassifications
Action Plan
Assessment by mach6 |
Progress UpdateFixed review finding 5: added 3 tests for
All 91 orchestration tests pass, ruff clean. Commit: Progress tracked by mach6 |
Progress UpdateAdded
The environment config is "configure once, reuse everywhere" — stable across different SLURM configs that may vary per campaign. Commit: Progress tracked by mach6 |
Code ReviewImportant1. 2. Global env parse failure silently yields empty 3. Conda base-environment detection emits wrong env name (confidence: 85) 4. 5. 6. Suggestions7. Stale 8. 9. 10. Dead 11. Redundant two-step 12. Redundant mutual-exclusivity guards in 13. 14. Legacy Strengths
Agents run: code-reviewer, error-auditor, test-reviewer, completeness-checker, simplifier Reviewed by mach6 |
Review AssessmentClassifications
Action Plan
Assessment by mach6 |
Progress UpdateFixed all 5 genuine review findings from the mach6 assessment: Bug Fixes
New Tests
Verification
Commit: Progress tracked by mach6 |
Code Review (re-review after e8a974e)Fix VerificationAll 5 fixes from e8a974e confirmed correct:
Suggestions1. 2. 3. Dead 4. 5. 6. Sections 2+3 verbatim-duplicated in Strengths
Agents run: code-reviewer, error-auditor, test-reviewer, completeness-checker, simplifier Reviewed by mach6 |
Review Assessment (re-review after e8a974e)Classifications
Action PlanEmpty — no genuine issues remain. All 5 prior genuine findings are correctly fixed. All 6 new findings are deferred (pre-existing code outside this PR's scope, or below the project's own extraction threshold). Assessment by mach6 |
Closes #40
Separate
EnvironmentConfigfrom SLURM allocation in executor config — structured model replacing the opaqueworker_initstring, with backward compatibility and TUI refactoring into three visual sections.Implementation plan posted as a comment below.