Skip to content

Document the pip install path, and fix the stale test and command references - #186

Merged
antonio-leblanc merged 3 commits into
forefireAPI:masterfrom
HugoFara:doc-pip-and-stale-refs
Aug 13, 2026
Merged

Document the pip install path, and fix the stale test and command references#186
antonio-leblanc merged 3 commits into
forefireAPI:masterfrom
HugoFara:doc-pip-and-stale-refs

Conversation

@HugoFara

Copy link
Copy Markdown
Collaborator

Three findings from the documentation audit, the ones that send a reader somewhere wrong.

1. The documentation site never mentioned pip

$ grep -rni "pip\|pypi\|wheel" docs/source
$

Nothing. The README's headline instruction is pip install forefire, and the site sent every reader to build from source instead — with a NetCDF dependency they do not need, since it is bundled in the wheel.

installation.rst now leads with pip: which platforms have wheels, what the wheel contains, and the three things it does not have (MPI, -march=native, ANN_test). The source build follows, unchanged in substance. quickstart.rst offered Docker only, calling it "the quickest way"; a pip route comes first now, and the Docker walkthrough is untouched.

Two things fixed along the way:

  • The NetCDF prerequisite told the reader to answer the documentation's own question:"Ensure this is the correct/intended library. Older docs might mention libnetcdf-cxx-legacy-dev. Verify which one is actually required by the current CMake setup."CMakeLists.txt searches for netcdf_c++4, netcdf-cxx4 and netcdf-cxx, and its failure message already lists the package per distribution. That table is now in the page, with the note that libnetcdf-cxx-legacy-dev is a different, pre-C++4 API.
  • conf.py hard-coded release = '2.0.0', so the site advertised 2.0.0 while the code was v2.5.0. It parses src/include/Version.h, the same file CMake and scikit-build-core read.

2. tests/README.md was wrong in nearly every row

ClaimReality
idealized_wind.pythe file is idealizedwind.py
rothermel.fannthe file is Rothermel.ffann
runANN needs tensorflow (or torch)it needs neither — bin/ANN_test, and ForeFire reads the .ffann itself
runANN "compares with reference outputs"it diffs against result.txt.ref, which is not in the repository
percolation.py runs "three fires"four, one per entry in k_coeffs
idealizedwind.py produces "NetCDF files"only 360wind.png, via ForeFire's plot[]

The runANN entry now says plainly that the suite fails, with a pointer to #163.

runff also has two entry points that do different things, and the old text described neither: run.bash runs three scenarios and checks the artefacts exist; ff-run.bash runs two and compares KML and NetCDF against references. CI calls the second, so only the second can catch physics drift.

tests/python/README.md documented only farsite_flat.py — the one script that cannot run as checked out, because flatland.lcp is not in the repository — and did not mention that. It now covers all four files and keeps the download URL.

3. emit was invisible to the console

trans["emit"] = &emit; has been in Command::makeCmds since it was added, but emit appears in neither app/forefire/commands.md nor the command reference.

That file is not prose. AdvancedLineEditor.cpp:32 parses it into getCommandMan(), which drives Tab completion, the help text and the syntax colouring. A command missing from it is invisible to the console's own help.

Before, typing emit rendered uncoloured — exactly like a typo — while save beside it came out green. After:

forefire> emit <- green
forefire> clear <- green
forefire> nosuchcommand <- plain

commands.md also carried two## clear blocks. getCommandMan() assigns cmdMan[key] as it walks the file, so the second silently replaced the first and the longer entry was dead text. They are merged into one that matches what Command::clear actually does: free the domain, cancel scheduled events, keep the parameters.

Both files now cover all 22 registered commands, with no duplicates:

$ comm -23 <(registered) <(documented) # nothing

Not touching the open pull requests

This branch does not touch CHANGELOG.md, CONTRIBUTING.md or README.md — the only three files #184 and #185 change — so it merges in any order relative to them. No changelog entry is included for the same reason: CHANGELOG.md does not exist on master until #184 lands.

Verification

  • Sphinx builds with no new warnings. The eleven that remain are the doxygenclass lookups that need the Doxygen XML RTD generates in its pre_build step.
  • The console behaviour above was checked against a rebuilt binary, with a nonsense word as the negative control.
  • Every file name, package name and script behaviour in the corrected READMEs was read out of the tree rather than carried over.

This pull request, including its code changes and this description, was generated by Claude Opus 5, and reviewed manually before submitting.

The documentation site had no mention of pip, pypi or wheels -- `grep -rni
'pip\|pypi\|wheel' docs/source` returned nothing -- while the README's
headline instruction is `pip install forefire`. Every reader arriving at the
site was sent to build from source.
- installation.rst leads with pip: platforms, what the wheel contains, and
the three options wheels turn off (MPI, -march=native, ANN_test), then the
source build as before.
- The NetCDF prerequisite said 'Verify which one is actually required by the
current CMake setup', leaving the reader to answer the documentation's own
question. CMakeLists.txt looks for netcdf_c++4 / netcdf-cxx4 / netcdf-cxx
and its failure message already lists the package per distribution; that
table is now in the page, along with the note that libnetcdf-cxx-legacy-dev
is a different API.
- The FOREFIRE_* build options are documented, with their real defaults.
- quickstart.rst offered Docker only, calling it 'the quickest way'. A pip
route comes first now; the Docker walkthrough is unchanged.
- conf.py hard-coded release = '2.0.0', so the site advertised 2.0.0 while
the code was v2.5.0. It parses src/include/Version.h, as CMake and
scikit-build-core do.
Sphinx builds clean: the only warnings are the eleven doxygenclass lookups
that need the Doxygen XML RTD generates in its pre_build step.
Nearly every specific claim in tests/README.md was wrong:
- `idealized_wind.py` and `rothermel.fann` do not exist; the files are
`idealizedwind.py` and `Rothermel.ffann`.
- runANN was listed as needing `tensorflow` (or `torch`). It needs neither.
It runs `bin/ANN_test`, built from tools/runANN/ANNTest.cpp, and ForeFire
reads the .ffann network itself.
- runANN was described as comparing against reference outputs. It diffs
against result.txt.ref, which is not in the repository, so the suite fails
on its second line every time -- now stated, with a pointer to forefireAPI#163.
- percolation.py runs four fires, not three: one per entry in k_coeffs.
- idealizedwind.py writes no NetCDF, only 360wind.png, and by way of
ForeFire's plot[] command rather than matplotlib.
- runff has two entry points that do different things. run.bash runs three
scenarios and checks the artefacts exist; ff-run.bash runs two and compares
KML and NetCDF against references. CI calls the second, so only the second
can catch physics drift. The old text described neither accurately.
tests/python/README.md documented only farsite_flat.py, the one script that
cannot run as checked out, and did not say so. It now covers all four files,
keeps the download URL for flatland.lcp, and marks test_wheel.py as belonging
to cibuildwheel rather than to this suite.
`emit` has been in Command::makeCmds since it was added, but in neither
app/forefire/commands.md nor the command reference. That file is not prose:
AdvancedLineEditor.cpp parses it into getCommandMan(), which drives Tab
completion, the help text and the syntax colouring. A command missing from it
is invisible to the console -- typing `emit` was rendered uncoloured, exactly
like a typo, while `save` beside it came out green.
commands.md also carried two '## clear' blocks. getCommandMan() assigns
cmdMan[key] as it walks the file, so the second silently replaced the first
and the longer entry was dead text. They are merged into one that matches what
Command::clear does: free the domain, cancel scheduled events, keep the
parameters.
Both files now cover all 22 registered commands, with no duplicates.
Verified: rebuilt and piped `emit`, `clear` and a nonsense word into the
console. The first two now colour green as recognised commands, the third does
not. Sphinx builds with no new warnings.

@antonio-leblancantonio-leblanc left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok only documentarion.
Commands.md is used in autocomplete on the forefire shell but ok nothin breaks

@antonio-leblanc
antonio-leblanc merged commit 9c12bb7 into forefireAPI:masterAug 13, 2026
8 checks passed
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@HugoFara@antonio-leblanc