Skip to content

Commit 5b7dcee

Browse files
authored
Merge branch 'main' into dokken/mixed_quadrature
2 parents b8f4e80 + d3d320b commit 5b7dcee

31 files changed

Lines changed: 235 additions & 294 deletions

File tree

.github/workflows/ccpp.yml

Lines changed: 29 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -93,22 +93,22 @@ jobs:
9393

9494
- name: Install Python build dependencies
9595
run: |
96-
pip install --upgrade -r python/build-requirements.txt
96+
pip -v install --upgrade -r python/build-requirements.txt
9797
9898
- name: Install FEniCS Python components
9999
run: |
100-
pip install git+https://github.com/fenics/ufl.git@${{ env.ufl_ref }}
101-
pip install git+https://github.com/fenics/basix.git@${{ env.basix_ref }}
102-
pip install git+https://github.com/fenics/ffcx.git@${{ env.ffcx_ref }}
100+
pip install --no-build-isolation git+https://github.com/fenics/ufl.git@${{ env.ufl_ref }}
101+
pip install --no-build-isolation git+https://github.com/fenics/basix.git@${{ env.basix_ref }}
102+
pip install --no-build-isolation git+https://github.com/fenics/ffcx.git@${{ env.ffcx_ref }}
103103
104104
- name: Configure and install C++
105105
run: |
106-
cmake -G Ninja -DDOLFINX_ENABLE_PETSC=false -DCMAKE_BUILD_TYPE=Developer -B build -S cpp/
106+
cmake -Werror=dev --warn-uninitialized -G Ninja -DDOLFINX_ENABLE_PETSC=false -DCMAKE_BUILD_TYPE=Developer -B build -S cpp/
107107
cmake --build build
108108
sudo cmake --install build
109109
- name: Build C++ unit tests
110110
run: |
111-
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/test/ -S cpp/test/
111+
cmake -Werror=dev --warn-uninitialized -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/test/ -S cpp/test/
112112
cmake --build build/test
113113
- name: Run C++ unit tests (serial)
114114
run: |
@@ -124,9 +124,11 @@ jobs:
124124
pip install --check-build-dependencies --no-build-isolation --config-settings=cmake.build-type="Debug" 'python/[test]'
125125
python -c "from mpi4py import MPI; import dolfinx; assert not dolfinx.has_petsc4py"
126126
127-
- name: Run mypy
127+
- name: Run mypy # Use a venv to avoid NumPy upgrades that are incompatible with numba
128128
working-directory: python
129129
run: |
130+
python -m venv mypy-env
131+
. ./mypy-env/bin/activate
130132
pip install mypy types-cffi scipy-stubs
131133
mypy -p dolfinx
132134
# mypy test
@@ -175,21 +177,24 @@ jobs:
175177
- name: Load environment variables
176178
run: cat .github/workflows/fenicsx-refs.env >> $GITHUB_ENV
177179

180+
- name: Install Python build dependencies
181+
run: pip install -r python/build-requirements.txt
182+
178183
- name: Install FEniCS Python components
179184
run: |
180-
pip install git+https://github.com/FEniCS/ufl.git@${{ env.ufl_ref }}
181-
pip install git+https://github.com/FEniCS/basix.git@${{ env.basix_ref }}
182-
pip install git+https://github.com/FEniCS/ffcx.git@${{ env.ffcx_ref }}
185+
pip install --no-build-isolation git+https://github.com/FEniCS/ufl.git@${{ env.ufl_ref }}
186+
pip install --no-build-isolation git+https://github.com/FEniCS/basix.git@${{ env.basix_ref }}
187+
pip install --no-build-isolation git+https://github.com/FEniCS/ffcx.git@${{ env.ffcx_ref }}
183188
184189
- name: Configure, build and install C++ library
185190
run: |
186-
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -DDOLFINX_ENABLE_ADIOS2=true -DDOLFINX_ENABLE_KAHIP=true -DDOLFINX_ENABLE_PARMETIS=false -DDOLFINX_ENABLE_PETSC=true -DDOLFINX_ENABLE_SCOTCH=true -DDOLFINX_ENABLE_SLEPC=true -B build -S cpp/
191+
cmake -Werror=dev --warn-uninitialized -G Ninja -DCMAKE_BUILD_TYPE=Developer -DDOLFINX_ENABLE_ADIOS2=true -DDOLFINX_ENABLE_KAHIP=true -DDOLFINX_ENABLE_PARMETIS=false -DDOLFINX_ENABLE_PETSC=true -DDOLFINX_ENABLE_SCOTCH=true -DDOLFINX_ENABLE_SLEPC=true -B build -S cpp/
187192
cmake --build build
188193
cmake --install build
189194
190195
- name: Build C++ unit tests
191196
run: |
192-
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/test/ -S cpp/test/
197+
cmake -Werror=dev --warn-uninitialized -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/test/ -S cpp/test/
193198
cmake --build build/test
194199
- name: Run C++ unit tests (serial)
195200
run: |
@@ -201,28 +206,30 @@ jobs:
201206
mpirun -n 3 ctest -V --output-on-failure -R unittests
202207
- name: Build and run C++ regression tests (serial and MPI (np=2))
203208
run: |
204-
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/demo/ -S cpp/demo/
209+
cmake -Werror=dev --warn-uninitialized -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/demo/ -S cpp/demo/
205210
cmake --build build/demo
206211
cd build/demo
207212
ctest -V -R demo -R serial
208213
ctest --output-on-failure -V -R demo -R mpi_2
209214
210-
- name: Install Python build dependencies
211-
run: pip install -r python/build-requirements.txt
212-
213215
- name: Build Python interface
214216
run: |
215217
pip install --check-build-dependencies --no-build-isolation --config-settings=cmake.build-type="Debug" 'python/[test]'
216218
python -c "from mpi4py import MPI; import dolfinx; assert dolfinx.has_adios2; assert dolfinx.has_kahip; assert not dolfinx.has_parmetis; assert dolfinx.has_petsc; assert dolfinx.has_petsc4py; assert dolfinx.has_ptscotch; assert dolfinx.has_slepc; assert dolfinx.has_complex_ufcx_kernels"
217219
218-
- name: Run mypy
220+
- name: Run mypy # Use a venv to avoid NumPy upgrades that are incompatible with numba
219221
working-directory: python
220222
run: |
223+
python -m venv mypy-env
224+
. ./mypy-env/bin/activate
221225
pip install mypy types-cffi scipy-stubs
222226
mypy -p dolfinx
223227
# mypy test
224228
# mypy demo
225229

230+
- name: Numpy version
231+
run: python -c "import numpy; print(numpy.__version__)"
232+
226233
- name: Set default DOLFINx JIT options
227234
run: |
228235
mkdir -p ~/.config/dolfinx
@@ -264,19 +271,19 @@ jobs:
264271

265272
- name: Install FEniCS Python components
266273
run: |
267-
pip install git+https://github.com/FEniCS/ufl.git@${{ env.ufl_ref }}
268-
pip install git+https://github.com/FEniCS/basix.git@${{ env.basix_ref }}
269-
pip install git+https://github.com/FEniCS/ffcx.git@${{ env.ffcx_ref }}
274+
pip install -r python/build-requirements.txt
275+
pip install --no-build-isolation git+https://github.com/FEniCS/ufl.git@${{ env.ufl_ref }}
276+
pip install --no-build-isolation git+https://github.com/FEniCS/basix.git@${{ env.basix_ref }}
277+
pip install --no-build-isolation git+https://github.com/FEniCS/ffcx.git@${{ env.ffcx_ref }}
270278
271279
- name: Configure C++
272280
run: |
273-
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build -S cpp/
281+
cmake -Werror=dev --warn-uninitialized -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build -S cpp/
274282
cmake --build build
275283
cmake --install build
276284
277285
- name: Build Python interface
278286
run: |
279-
pip install -r python/build-requirements.txt
280287
pip install --check-build-dependencies --no-build-isolation --config-settings=cmake.build-type="Debug" 'python/[docs]'
281288
282289
- name: Build C++ interface documentation

.github/workflows/ci-spack.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,15 +94,15 @@ jobs:
9494
run: |
9595
. ./spack-src/share/spack/setup-env.sh
9696
spack env activate .
97-
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build -S dolfinx-src/cpp/
97+
cmake -Werror=dev --warn-uninitialized -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build -S dolfinx-src/cpp/
9898
cmake --build build
9999
cmake --install build
100100
101101
- name: Build C++ unit tests
102102
run: |
103103
. ./spack-src/share/spack/setup-env.sh
104104
spack env activate .
105-
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/test/ -S dolfinx-src/cpp/test/
105+
cmake -Werror=dev --warn-uninitialized -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/test/ -S dolfinx-src/cpp/test/
106106
cmake --build build/test
107107
- name: Run C++ unit tests (serial and MPI)
108108
run: |
@@ -114,7 +114,7 @@ jobs:
114114
run: |
115115
. ./spack-src/share/spack/setup-env.sh
116116
spack env activate .
117-
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/demo/ -S dolfinx-src/cpp/demo/
117+
cmake -Werror=dev --warn-uninitialized -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/demo/ -S dolfinx-src/cpp/demo/
118118
cmake --build build/demo
119119
cd build/demo
120120
ctest -V -R demo -R serial

.github/workflows/macos.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
run: |
5151
export PATH="$(brew --prefix gfortran)/bin:$(brew --prefix bison)/bin:$PATH"
5252
export PATH="$(brew --prefix make)/libexec/gnubin:$PATH"
53-
git clone -b release https://gitlab.com/petsc/petsc.git petsc
53+
git clone --depth 1 --branch release https://gitlab.com/petsc/petsc.git petsc
5454
cd petsc
5555
python ./configure \
5656
--with-64-bit-indices=no \
@@ -79,19 +79,20 @@ jobs:
7979
8080
- name: Build and install DOLFINx C++ library
8181
run: |
82-
cmake -G Ninja -B build -S cpp/
82+
cmake -Werror=dev --warn-uninitialized -G Ninja -B build -S cpp/
8383
cmake --build build
8484
sudo cmake --install build
8585
8686
- name: Build C++ unit tests
8787
run: |
88-
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/test/ -S cpp/test/
88+
cmake -Werror=dev --warn-uninitialized -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/test/ -S cpp/test/
8989
cmake --build build/test
9090
9191
- name: Run C++ unit tests (serial)
9292
run: |
9393
cd build/test
9494
mpiexec -np 1 ctest -V --output-on-failure -R unittests
95+
9596
- name: Run C++ unit tests (MPI)
9697
run: |
9798
cd build/test

README.md

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
# DOLFINx
22

33
[![DOLFINx CI](https://github.com/FEniCS/dolfinx/actions/workflows/ccpp.yml/badge.svg)](https://github.com/FEniCS/dolfinx/actions/workflows/ccpp.yml)
4-
[![Actions Docker images](https://github.com/FEniCS/dolfinx/actions/workflows/docker-end-user.yml/badge.svg)](https://github.com/FEniCS/dolfinx/actions/workflows/docker-end-user.yml)
54
[![Actions Spack build](https://github.com/FEniCS/dolfinx/actions/workflows/spack.yml/badge.svg)](https://github.com/FEniCS/dolfinx/actions/workflows/spack.yml)
65
[![Actions Conda install](https://github.com/FEniCS/dolfinx/actions/workflows/conda.yml/badge.svg)](https://github.com/FEniCS/dolfinx/actions/workflows/conda.yml)
76
[![Actions macOS/Homebrew install](https://github.com/FEniCS/dolfinx/actions/workflows/macos.yml/badge.svg)](https://github.com/FEniCS/dolfinx/actions/workflows/macos.yml)
8-
[![Actions Windows/vcpkg install](https://github.com/FEniCS/dolfinx/actions/workflows/windows.yml/badge.svg)](https://github.com/FEniCS/dolfinx/actions/workflows/windows.yml)
7+
[![Actions Docker images](https://github.com/FEniCS/dolfinx/actions/workflows/docker-end-user.yml/badge.svg)](https://github.com/FEniCS/dolfinx/actions/workflows/docker-end-user.yml)
98

109
DOLFINx is the computational environment of
1110
[FEniCSx](https://fenicsproject.org) and implements the FEniCS Problem
@@ -26,7 +25,7 @@ Documentation can be viewed at <https://docs.fenicsproject.org>.
2625

2726
### From source
2827

29-
For detailed instructions and the list of dependencies, see
28+
For detailed instructions and a list of dependencies, see
3029
<https://docs.fenicsproject.org/dolfinx/main/python/installation>.
3130

3231
#### C++ core
@@ -52,9 +51,9 @@ pip install --check-build-dependencies --no-build-isolation .
5251

5352
### Spack
5453

55-
Spack is recommended for building DOLFINx on HPC systems. To build the
56-
most recent release using [Spack](https://spack.readthedocs.io/)
57-
(assuming a bash-compatible shell):
54+
To build the most recent release using
55+
[Spack](https://spack.readthedocs.io/) (assuming a bash-compatible
56+
shell):
5857

5958
```shell
6059
git clone https://github.com/spack/spack.git
@@ -65,10 +64,9 @@ spack add fenics-dolfinx+petsc+adios2 py-fenics-dolfinx cflags="-O3" fflags="-O3
6564
spack install
6665
```
6766

68-
See the Spack [documentation](https://spack.readthedocs.io/) for
69-
comprehensive instructions.
67+
Spack is the recommended approach for HPC systems.
7068

71-
### Binary
69+
### Binary packages
7270

7371
**Recommendations**
7472

@@ -94,10 +92,9 @@ conda install -c conda-forge fenics-dolfinx mpich pyvista # Linux and macOS
9492
conda install -c conda-forge fenics-dolfinx pyvista pyamg # Windows
9593
```
9694

97-
*Windows only*: Windows conda packages are currently in beta testing. PETSc and
98-
petsc4py are not available on Windows; as an alternative we recommend using
99-
`pyamg` following `python/demo/demo_pyamg.py`. Because FEniCS uses just-in-time
100-
compilation it necessary to install [Microsoft Visual
95+
*Windows only*: Windows conda packages are currently in beta testing.
96+
PETSc and petsc4py are not available on Windows. Because FEniCS uses
97+
just-in-time compilation it necessary to install [Microsoft Visual
10198
Studio](https://visualstudio.microsoft.com/downloads/).
10299

103100
conda is distributed with [Anaconda](https://www.anaconda.com/) and

0 commit comments

Comments
 (0)