Skip to content

Commit

Permalink
Fail on warnings in the documentation (Exawind#624)
Browse files Browse the repository at this point in the history
* Fail on warnings in the documentation.

* Use https for HIP binaries.
  • Loading branch information
jrood-nrel authored May 18, 2022
1 parent bcb8041 commit 6172f16
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 25 deletions.
33 changes: 21 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: AMR-Wind CI
name: AMR-Wind-CI

on:
push:
Expand All @@ -10,8 +10,10 @@ jobs:
Formatting:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: DoozyX/[email protected]
- name: Clone
uses: actions/checkout@v3
- name: Check formatting
uses: DoozyX/[email protected]
with:
source: './amr-wind ./unit_tests ./tools/utilities'
exclude: '.'
Expand Down Expand Up @@ -45,7 +47,8 @@ jobs:
uses: styfle/[email protected]
with:
access_token: ${{github.token}}
- uses: actions/checkout@v2
- name: Clone
uses: actions/checkout@v3
with:
submodules: true
- name: Dependencies
Expand Down Expand Up @@ -96,7 +99,8 @@ jobs:
uses: styfle/[email protected]
with:
access_token: ${{github.token}}
- uses: actions/checkout@v2
- name: Clone
uses: actions/checkout@v3
with:
submodules: true
- name: Prepare CUDA environment
Expand Down Expand Up @@ -128,13 +132,14 @@ jobs:
uses: styfle/[email protected]
with:
access_token: ${{github.token}}
- uses: actions/checkout@v2
- name: Clone
uses: actions/checkout@v3
with:
submodules: true
- name: Prepare HIP environment
run: |
wget -q -O - http://repo.radeon.com/rocm/rocm.gpg.key | sudo apt-key add -
echo 'deb [arch=amd64] http://repo.radeon.com/rocm/apt/debian/ ubuntu main' | sudo tee /etc/apt/sources.list.d/rocm.list
wget -q -O - https://repo.radeon.com/rocm/rocm.gpg.key | sudo apt-key add -
echo 'deb [arch=amd64] https://repo.radeon.com/rocm/apt/debian/ ubuntu main' | sudo tee /etc/apt/sources.list.d/rocm.list
echo 'export PATH=/opt/rocm/llvm/bin:/opt/rocm/bin:/opt/rocm/profiler/bin:/opt/rocm/opencl/bin:$PATH' | sudo tee -a /etc/profile.d/rocm.sh
sudo apt-get update
sudo apt-get install -y --no-install-recommends ninja-build \
Expand Down Expand Up @@ -166,7 +171,8 @@ jobs:
uses: styfle/[email protected]
with:
access_token: ${{github.token}}
- uses: actions/checkout@v2
- name: Clone
uses: actions/checkout@v3
with:
submodules: true
- name: Prepare DPC++ environment
Expand Down Expand Up @@ -198,7 +204,8 @@ jobs:
uses: styfle/[email protected]
with:
access_token: ${{github.token}}
- uses: actions/checkout@v2
- name: Clone
uses: actions/checkout@v3
with:
submodules: true
- name: Dependencies
Expand Down Expand Up @@ -234,7 +241,8 @@ jobs:
uses: styfle/[email protected]
with:
access_token: ${{github.token}}
- uses: actions/checkout@v2
- name: Clone
uses: actions/checkout@v3
with:
submodules: true
- name: Dependencies
Expand Down Expand Up @@ -281,7 +289,8 @@ jobs:
# uses: styfle/[email protected]
# with:
# access_token: ${{github.token}}
# - uses: actions/checkout@v2
# - name: Clone
# uses: actions/checkout@v3
# with:
# submodules: true
# - name: Build and test
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: AMR-Wind Docs
name: AMR-Wind-Docs

on:
push:
Expand All @@ -14,7 +14,8 @@ jobs:
uses: styfle/[email protected]
with:
access_token: ${{github.token}}
- uses: actions/checkout@v2
- name: Clone
uses: actions/checkout@v3
- name: Python
uses: actions/setup-python@v2
with:
Expand All @@ -31,7 +32,7 @@ jobs:
# execute from top-level amr-wind directory
run: |
echo "::add-matcher::.github/problem-matchers/sphinx.json"
sphinx-build -M html ./docs/sphinx ./build_docs/manual 2>&1 | tee -a build-output.txt
sphinx-build -M html ./docs/sphinx ./build_docs/manual -W --keep-going -n 2>&1 | tee -a build-output.txt
# Doxygen output gets parsed wrong by the sphinx problem matcher so unregister it
echo "::remove-matcher owner=sphinx-problem-matcher-loose-no-severity::"
echo "::remove-matcher owner=sphinx-problem-matcher-loose::"
Expand Down
17 changes: 8 additions & 9 deletions docs/sphinx/developer/unit_testing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,11 @@ a brief overview of the core classes and their purpose.
```````````````````````````````````

Classes written in AMR-Wind often require user inputs that are generally read in
from input files through :class:`amrex::ParmParse` (see `docs
from input files through `amrex::ParmParse` (see `docs
<https://amrex-codes.github.io/amrex/docs_html/Basics.html#parmparse>`_).
``pp_utils`` are a set of functions that create skeleton input data that are
used by various classes during initialization. For example, it populates the
problem domain, mesh sizes, etc. so that :class:`amrex::AmrMesh` can be
problem domain, mesh sizes, etc. so that `amrex::AmrMesh` can be
initialized properly.

.. function:: default_mesh_inputs()
Expand All @@ -189,8 +189,7 @@ initialized properly.

.. function:: default_time_inputs()

Populates ParmParse data structure with necessary inputs for
:class:`amr_wind::SimTime`.
Populates ParmParse data structure with necessary inputs for `amr_wind::SimTime`.

.. class:: AmrexTestEnv

Expand Down Expand Up @@ -315,10 +314,10 @@ of this test fixture:

.. class:: AmrTestMesh

:class:`AmrTestMesh` is a concrete implementation of :class:`amrex::AmrCore`
:class:`AmrTestMesh` is a concrete implementation of `amrex::AmrCore`
that creates an AMR mesh that can be used with unit testing. In addition to
implementing the basic level data creation methods and refinement routines
``ErrorEst``, it also creates an :class:`amr_wind::FieldRepo` instance for
``ErrorEst``, it also creates an `amr_wind::FieldRepo` instance for
creating and manipulating fields from within unit tests. :class:`AmrTestMesh` is
never directly created within unit tests, instead it is created on-demand
through the test fixture :class:`MeshTest` described next.
Expand All @@ -328,7 +327,7 @@ through the test fixture :class:`MeshTest` described next.
:class:`MeshTest` is the base test fixture for any test that requires a mesh and
associated field data that will be used by the test. In addition to performing
setup/teardown actions described in :class:`AmrexTest`, it also resets the
default :class:`amrex::Geometry` static data so that different tests can run on
default `amrex::Geometry` static data so that different tests can run on
different problem domains perscribed by the test fixture.

Almost all unit tests within AMR-Wind use :class:`MeshTest` as their base test
Expand Down Expand Up @@ -432,7 +431,7 @@ scratch. After a call to this function, the mesh is ready for use.
.. function:: populate_parameters()

Populate default parameters necessary for creating an AMRMesh and
:class:`amr_wind::SimTime` objects.
`amr_wind::SimTime` objects.


.. function:: create_mesh_instance()
Expand All @@ -451,7 +450,7 @@ be used as starting points for users to write new tests:
`test_simtime.cpp <https://github.com/Exawind/amr-wind/blob/development/unit_tests/core/test_simtime.cpp>`_

Simple unit test example that tests the behavior of
:class:`amr_wind::SimTime`. This test only relies on :class:`AmrexTest` and
`amr_wind::SimTime`. This test only relies on :class:`AmrexTest` and
does not require a mesh.

`test_abl_init.cpp <https://github.com/Exawind/amr-wind/blob/development/unit_tests/wind_energy/test_abl_init.cpp>`_
Expand Down
2 changes: 1 addition & 1 deletion docs/sphinx/user/inputs_MLMG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ temperature, to do that use "temperature_diffusion" as your prefix.

**type:** Integer, optional, default = 200

Sets the max number of multigrid iterations. If :input_param:`do_fixed_iters`
Sets the max number of multigrid iterations. If :input_param:`diffusion.do_fixed_iters`
is set to True, then AMReX will not abort if specified tolerance is not met
after max iterations, otherwise it will abort.

Expand Down

0 comments on commit 6172f16

Please sign in to comment.