8000 refactor: split grower_report into summary, wording, format and HTML modules by rafatahmed · Pull Request #321 · rafatahmed/Flahax · GitHub
[go: up one dir, main page]

Skip to content

refactor: split grower_report into summary, wording, format and HTML modules - #321

Merged
rafatahmed merged 3 commits into
mainfrom
refactor/split-grower-report
Nov 26, 2026
Merged

rafatahmed merged 3 commits into
mainfrom
refactor/split-grower-report

Conversation

@rafatahmed
Copy link
Copy Markdown
Owner

Closes #320.

grower_report.py (2,129 lines) is deleted and split into report_format (shared formatters), result_wording (reasons, qualifications, reagent, limit, solubility and dose rows), report_html (render_report, render_batch_sheet) and batch_summary (summarize_batch, now calling named steps for the pH record, chemistry and EC, tank plan, formulation, assumptions and identity).

  • A pure move: no key, wording or output changes. summarize_batch, render_report and render_batch_sheet import from flahax as before.
  • The reason and row helpers lose their leading underscore because other modules import them. All importers, tests, two examples and the docs diagram are updated; no re-export shim is left. The API reference is regenerated.

Verification: six flahax batch scenarios (including a blocked one) were captured on main and compared after the move and after the step split: 24 files identical once 64-hex hashes are masked. The only raw differences are calculation_identity.result_id, source_sha256 and export_identity.sha256, which hash the package source. Every runnable test module passes; test_grower_journey was run test by test. test_file_headers fails the same 434 cases as main on Windows. Not run locally: the slow ratio modules (they import nothing changed), and the pre-push script (over 5 minutes). The PHREEQC fixture is not re-captured: no chemistry changed.

…ort_html and batch_summary

A pure move: no key, wording or output changes. The reason and row helpers
lose their leading underscore because other modules import them. All
importers, tests and the API reference follow.
…try and EC, tank plan, formulation, assumptions and identity
@rafatahmed rafatahmed added the enhancement New feature or request label Nov 26, 2026
@rafatahmed rafatahmed self-assigned this Nov 26, 2026
@read-the-docs-community
Copy link
Copy Markdown

Documentation build overview

📚 Flahax | 🛠️ Build #36177514 | 📁 Comparing b24e2a6 against latest (e5c6a66)

  🔍 Preview build  

3 files changed
± changelog.html
± developer/index.html
± reference/api.html

@codecov
codecov Bot commented Nov 26, 2026 •
Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (e5c6a66) to head (b24e2a6).
⚠️ Report is 4 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #321   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          142       145    +3     
  Lines        17406     17441   +35     
  Branches      3539      3539           
=========================================
+ Hits         17406     17441   +35     
Flag Coverage Δ
unittests 100.00% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@rafatahmed
rafatahmed marked this pull request as ready for review November 26, 2026 03:17
@rafatahmed
rafatahmed merged commit c65b8d9 into main Nov 26, 2026
29 checks passed
@rafatahmed
rafatahmed deleted the refactor/split-grower-report branch November 26, 2026 03:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Split grower_report.py into summary, wording, format and HTML modules

1 participant

0