Skip to content

Commit 0e17071

Browse files
authored
Sanitise docs 2 (#427)
1 parent 0ab8bd4 commit 0e17071

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+2778
-1802
lines changed

.github/workflows/publish_wps.yml

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,9 @@ on:
44
push:
55
branches:
66
- main
7+
- github_wps
78
pull_request:
8-
types: [opened,reopened,review_requested]
9+
types: [opened, reopened, synchronize]
910
workflow_dispatch:
1011

1112
permissions:
@@ -20,18 +21,23 @@ jobs:
2021
run: |
2122
git config --global user.email "umsysteam@metoffice.gov.uk"
2223
git config --global user.name "SSD Developers"
24+
2325
- name: Check out source
2426
uses: actions/checkout@v4
25-
- uses: actions/setup-python@v5
27+
28+
- name: Setup uv
29+
uses: astral-sh/setup-uv@v6
2630
with:
27-
python-version: '3.x'
31+
python-version: '3.12'
32+
2833
- name: Install Dependencies
29-
run: |
30-
pip install -r .github/workflows/requirements.txt
34+
run: uv sync
3135

32-
- name: build docs
33-
run: |
34-
make clean html
36+
- name: Lint Docs
37+
run: uv run sphinx-lint source
38+
39+
- name: Build Docs
40+
run: uv run make clean html
3541

3642
- name: commit docs to gh-pages branch
3743
if: ${{ github.event_name == 'push' && github.ref_name == 'main' }}

.github/workflows/requirements.txt

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
Sphinx==6.2.1
2-
sphinx-design==0.5.0
3-
pydata-sphinx-theme
4-
sphinx-sitemap
1+
sphinx==8.2.3
2+
pydata-sphinx-theme==0.16.1
3+
sphinx-design==0.6.1
4+
sphinx-copybutton==0.5.2
5+
sphinx-lint==1.0.0
6+
sphinx-sitemap==2.8.0
7+
sphinxcontrib-svg2pdfconverter==1.3.0
8+

.gitignore

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
#build output
2-
/build/
3-
4-
#IDE files
5-
/.idea
6-
/.venv/
7-
/venv/
1+
*.egg-info/
2+
*.py[cod]
3+
.idea
4+
.venv/
5+
__pycache__/
6+
build/
7+
uv.lock
8+
venv/

pyproject.toml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
[project]
2+
name = "simulation-systems"
3+
version = "0.1.0"
4+
description = "Simulation Systems Working Practices"
5+
readme = "README.md"
6+
requires-python = ">=3.11"
7+
dependencies = [
8+
"pydata-sphinx-theme==0.16.1",
9+
"sphinx==8.2.3",
10+
"sphinx-design==0.6.1",
11+
"sphinx-copybutton==0.5.2",
12+
"sphinx-lint==1.0.0",
13+
"sphinx-sitemap==2.8.0",
14+
"sphinxcontrib-svg2pdfconverter==1.3.0",
15+
]

source/Development/Diagnostics/lfric_diagnostics.rst

Lines changed: 192 additions & 216 deletions
Large diffs are not rendered by default.

source/Development/Diagnostics/um_stashmaster.rst

Lines changed: 37 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -2,46 +2,60 @@
22

33
STASH [#f1]_
44
============
5-
Information on every diagnostic available to the
6-
model is stored in a single file named ``STASHmaster_A``, which is read into
7-
the model at the start of the run.
85

9-
The UM's ``STASHmaster_A`` and associated help text file ``STASHmaster-meta.conf``
10-
are available in your branch at
6+
Information on every diagnostic available to the model is stored in a single
7+
file named ``STASHmaster_A``, which is read into the model at the start of the
8+
run.
9+
10+
The UM's ``STASHmaster_A`` and associated help text file
11+
``STASHmaster-meta.conf`` are available in your branch at
1112
``vnXX.Y_<branch_name>/rose-meta/um-atmos/HEAD/etc/stash/STASHmaster/``.
1213

1314
.. note::
14-
When running the UM rose stem suite, the suite will automatically use the
15-
``STASHmaster_A file`` from your branch when testing your code.
15+
16+
When running the UM rose stem suite, the suite will automatically use the
17+
``STASHmaster_A file`` from your branch when testing your code.
1618

1719
The following principles apply when altering the STASHmaster:
1820

1921
..
2022
JW suggest need to include STASH entry guidance here. Maybe an issue for this would be useful?
2123
22-
* If you add a new diagnostic to the ``STASHmaster_A`` file then you **must** also add to the stash master help text in :ref:`stashmaster-meta`.
23-
* If you are altering the stashmaster, this may be referred to the FFPP governance board by the sci/tech or code reviewers - see the STASH entry guidelines.
24-
* If your change has new stash items or changed/added attributes as an option code, versions mask etc., then first you have to get them reserved and recorded (published) on the reservation web page STASH/ReservedCodes
25-
* Note that every reservation should be linked to a ticket with the correct explanation and a milestone. This rule applies to all stash related tables placed on this page.
26-
* Although reservations could be some kind of self-service, contact the section owner first nevertheless. This could help to organise new items (when possible) in some logical groups.
24+
* If you add a new diagnostic to the ``STASHmaster_A`` file then you **must**
25+
also add to the stash master help text in :ref:`stashmaster-meta`.
26+
* If you are altering the stashmaster, this may be referred to the FFPP
27+
governance board by the sci/tech or code reviewers - see the STASH entry
28+
guidelines.
29+
* If your change has new stash items or changed/added attributes as an option
30+
code, versions mask etc., then first you have to get them reserved and
31+
recorded (published) on the reservation web page STASH/ReservedCodes
32+
* Note that every reservation should be linked to a ticket with the correct
33+
explanation and a milestone. This rule applies to all stash related tables
34+
placed on this page.
35+
* Although reservations could be some kind of self-service, contact the section
36+
owner first nevertheless. This could help to organise new items
37+
(when possible) in some logical groups.
2738
* For new option code numbers contact the STASH code owner.
2839

2940
.. note::
30-
Complete details of the STASH system (including the syntax used in the
31-
``STASHmaster_A`` file) can be found in
32-
`UMDP C04 <https://code.metoffice.gov.uk/doc/um/latest/papers/umdp_C04.pdf>`_
41+
42+
Complete details of the STASH system (including the syntax used in the
43+
``STASHmaster_A`` file) can be found in `UMDP C04
44+
<https://code.metoffice.gov.uk/doc/um/latest/papers/umdp_C04.pdf>`__
3345

3446
.. _stashmaster-meta:
3547

3648
STASHmaster-meta.conf
3749
---------------------
38-
If you are adding a new UM STASH diagnostic you must also add help text to the STASHmaster-meta.conf.
39-
This will provide others with help on your diagnostic. You will need to identify the stash entry with
40-
a ``[stashmaster:code(xyz)]`` section header, where the xyz is the stash code in the form
41-
``section number * 1000 + item number``.
4250

43-
Include a full name, any units and explanatory text. You should also add a description field that matches
44-
the full name of the diagnostic. For example:
51+
If you are adding a new UM STASH diagnostic you must also add help text to the
52+
STASHmaster-meta.conf. This will provide others with help on your diagnostic.
53+
You will need to identify the stash entry with a ``[stashmaster:code
54+
(xyz)]`` section header, where the xyz is the stash code in the form ``section
55+
number * 1000 + item number``.
56+
57+
Include a full name, any units and explanatory text. You should also add a
58+
description field that matches the full name of the diagnostic. For example:
4559

4660
.. code-block::
4761
@@ -56,7 +70,8 @@ the full name of the diagnostic. For example:
5670
=number of moles of NO2 removed by this process per second in the
5771
=whole model.
5872
59-
This assists the model user in being able to find useful help text on their diagnostic.
73+
This assists the model user in being able to find useful help text on their
74+
diagnostic.
6075

6176

6277
.. rubric:: Footnotes

source/Development/TestSuites/jules.rst

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ JULES testing is run with the following command from a working copy:
99
1010
-----
1111

12-
The JULES rose stem testing includes a range of builds using a variety of compilers,
13-
several configurations, and rose-ana tasks to check the output.
12+
The JULES rose stem testing includes a range of builds using a variety of
13+
compilers, several configurations, and rose-ana tasks to check the output.
1414

1515
The output is checked for correctness both by comparing the output to a set of
1616
stored :ref:`KGO files <kgo>`.
@@ -21,20 +21,20 @@ stored :ref:`KGO files <kgo>`.
2121
:ref:`jules-shared<shared-namelists>` metadata then these changes
2222
will need to be tested :ref:`with the UM<um_testing>` and
2323
:ref:`with LFRic Apps<lfric_apps_test>`. If you have access to LFRic, the
24-
:ref:`traclog` will state whether LFRic testing is required based on the branch
25-
diff. If you do not have LFRic access, this testing will need to be completed by
26-
your Met Office contact.
24+
:ref:`traclog` will state whether LFRic testing is required based on the
25+
branch diff. If you do not have LFRic access, this testing will need to
26+
be completed by your Met Office contact.
2727

2828
See :ref:`multirepo` for details on how to carry out this testing.
2929

3030
.. important::
31-
For **jules-shared** changes, when LFRic testing, the changes
32-
need to be manually synced to the LFRic location. When UM
33-
testing, this is not required as **jules-shared** is imported
34-
from the JULES branch.
31+
For **jules-shared** changes, when LFRic testing, the
32+
changes need to be manually synced to the LFRic location. When UM
33+
testing, this is not required as **jules-shared** is imported from the
34+
JULES branch.
3535

36-
Below is a (by no means comprehensive) set of groups that you may wish to use on
37-
Met Office systems.
36+
Below is a (by no means comprehensive) set of groups that you may wish to use
37+
on Met Office systems.
3838

3939
+--------------------+----------------------------------------------------------+
4040
| Group | Description |

source/Development/TestSuites/lfric_apps.rst

Lines changed: 27 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -4,50 +4,59 @@ Testing LFRic Apps
44
==================
55

66
Rose stem:
7+
78
LFRic Apps testing uses rose-stem and is run with the following commands
89
from a working copy:
910

10-
.. code-block::
11+
.. code-block:: shell
1112
1213
export CYLC_VERSION=8
1314
rose stem --group=developer
1415
cylc play <working copy name>
1516
cylc gui
1617
1718
Local testing:
19+
1820
Alternatively, a single application can be built and run locally using
19-
`these instructions <https://code.metoffice.gov.uk/trac/lfric_apps/wiki/local_builds>`_
21+
`these instructions
22+
<https://code.metoffice.gov.uk/trac/lfric_apps/wiki/local_builds>`__
2023

21-
This test does not use rose or cylc and is particularly useful for
22-
checking for compile errors while developing.
24+
This test does not use rose or cylc and is particularly useful for checking
25+
for compile errors while developing.
2326

2427
-----
2528

2629
.. important::
2730

28-
When specifying the lfric_core source the lfric_core revision **must** be updated in ``dependencies.sh``.
31+
When specifying the lfric_core source the lfric_core revision **must** be
32+
updated in ``dependencies.sh``.
2933

30-
* If setting the source to an fcm URL, the mirror (``.xm_``) needs to be used and the revision can either be blank (for latest commit) or any valid revision for that branch.
31-
* If setting the source to a Working Copy, the hostname needs to be provided (as Hostname:Path) and the revision must be blank.
34+
* If setting the source to an fcm URL, the mirror (``.xm_``) needs to be
35+
used and the revision can either be blank (for latest commit) or any
36+
valid revision for that branch.
37+
* If setting the source to a Working Copy, the hostname needs to be
38+
provided (as Hostname:Path) and the revision must be blank.
3239

3340
For more details, see :ref:`multi-repo_testing`.
3441

3542

3643
Rose stem
3744
---------
38-
The LFRic Apps rose stem includes a range of tests to exercise all the applications
39-
stored in this repository, using multiple compilers, and checksum and plot tasks to
40-
confirm the outputs.
45+
46+
The LFRic Apps rose stem includes a range of tests to exercise all the
47+
applications stored in this repository, using multiple compilers, and checksum
48+
and plot tasks to confirm the outputs.
4149

4250
.. tip::
4351

44-
For LFRic Apps it is possible to update the checksum files on your branch as
45-
you progress your development to aid with testing. Details on how to do this
46-
are on the :ref:`KGO page <kgo>`.
52+
For LFRic Apps it is possible to update the checksum files on your branch
53+
as you progress your development to aid with testing. Details on how to do
54+
this are on the :ref:`KGO page <kgo>`.
4755

48-
Below is a (by no means comprehensive) set of groups that you may wish to use on
49-
Met Office systems. Note that there is a lot of overlap between these groups,
50-
and that you can specify more than one at once, e.g. ``--group=developer,gungho_model``.
56+
Below is a (by no means comprehensive) set of groups that you may wish to use
57+
on Met Office systems. Note that there is a lot of overlap between these
58+
groups, and that you can specify more than one at once, e.g.
59+
``--group=developer,gungho_model``.
5160

5261
+--------------------+----------------------------------------------------------+
5362
| Group | Description |
@@ -76,8 +85,8 @@ and that you can specify more than one at once, e.g. ``--group=developer,gungho_
7685
+--------------------+----------------------------------------------------------+
7786

7887
As well as these general groups, each area in ``<lfric_apps>/applications`` and
79-
``<lfric_apps>/science`` have a set of specific groups that are structured as below,
80-
with ``name`` matching the directory name of the area.
88+
``<lfric_apps>/science`` have a set of specific groups that are structured as
89+
below, with ``name`` matching the directory name of the area.
8190

8291
+--------------------+----------------------------------------------------------+
8392
| Group | Description |

source/Development/TestSuites/lfric_core.rst

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,14 @@ Testing LFRic Core
55

66
.. note::
77

8-
At the LFRic Apps vn2.0 release, the cylc7 LFRic Core suite was deprecated and the make test-suite functionality removed. Only the cylc8 suite is now maintained.
8+
At the LFRic Apps vn2.0 release, the cylc7 LFRic Core suite was deprecated
9+
and the make test-suite functionality removed. Only the cylc8 suite is now
10+
maintained.
911

10-
LFRic testing is launched with Cylc8 rose-stem commands (as in eg. LFRic Apps):
12+
LFRic testing is launched with Cylc8 rose-stem commands (as in eg. LFRic
13+
Apps):
1114

12-
.. code-block::
15+
.. code-block:: shell
1316
1417
export CYLC_VERSION=8
1518
rose stem --group=developer
@@ -22,14 +25,19 @@ that the system level developer tests pass on all the applications. These are
2225
launched from make and utilise rose and cylc.
2326

2427
While developing your change, for expediency you may want to run the tests for
25-
only some applications. This can be done by changing the group you run, eg ``--group=simple_diffusion``.
28+
only some applications. This can be done by changing the group you run, eg
29+
``--group=simple_diffusion``.
2630

27-
The command above will launch the developer suite. You can include slightly more testing if required by running ``--group=all`` instead (this includes the developer suite).
31+
The command above will launch the developer suite. You can include slightly
32+
more testing if required by running ``--group=all`` instead (this includes the
33+
developer suite).
2834

29-
It is also possible to run on a single platform, eg. ``--group=ex1a``. To select which meto EX machine is used, add ``-S USE_EX<AB/CD/Z>``.
35+
It is also possible to run on a single platform, eg. ``--group=ex1a``. To
36+
select which meto EX machine is used, add ``-S USE_EX<AB/CD/Z>``.
3037

3138
.. tip::
3239

3340
For more details on LFRic testing including details of unit tests please
34-
visit the `LFRic testing trac wiki page <https://code.metoffice.gov.uk/trac/lfric/wiki/LFRicTechnical/Testing>`_.
41+
visit the `LFRic testing trac wiki page
42+
<https://code.metoffice.gov.uk/trac/lfric/wiki/LFRicTechnical/Testing>`__.
3543

0 commit comments

Comments
 (0)