From 9f4ee49ce0a303b7d75f8d1041eb8c2994b0024c Mon Sep 17 00:00:00 2001 From: Thomas Baumann <39156931+brownbaerchen@users.noreply.github.com> Date: Mon, 28 Apr 2025 15:50:15 +0200 Subject: [PATCH 1/3] Making plot helper compatible with Python > 3.11 --- pySDC/helpers/plot_helper.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pySDC/helpers/plot_helper.py b/pySDC/helpers/plot_helper.py index f1a6238dcd..cca3cbdbee 100644 --- a/pySDC/helpers/plot_helper.py +++ b/pySDC/helpers/plot_helper.py @@ -1,6 +1,6 @@ import matplotlib as mpl import matplotlib.pyplot as plt -from distutils.spawn import find_executable +import shutil default_mpl_params = mpl.rcParams.copy() @@ -100,7 +100,7 @@ def setup_mpl(font_size=8, reset=False): mpl.rcParams.update(style_options) - if find_executable('latex'): + if shutil.which('latex'): latex_support = { "pgf.texsystem": "pdflatex", # change this if using xetex or lautex "text.usetex": True, # use LaTeX to write all text From e6d389097efe99938f43c354af29ec49db87b8f8 Mon Sep 17 00:00:00 2001 From: Thomas Baumann <39156931+brownbaerchen@users.noreply.github.com> Date: Mon, 28 Apr 2025 15:52:45 +0200 Subject: [PATCH 2/3] Forgot to add a file --- pySDC/helpers/plot_helper.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pySDC/helpers/plot_helper.py b/pySDC/helpers/plot_helper.py index cca3cbdbee..608f367c49 100644 --- a/pySDC/helpers/plot_helper.py +++ b/pySDC/helpers/plot_helper.py @@ -125,7 +125,7 @@ def newfig(textwidth, scale, ratio=0.6180339887): def savefig(filename, save_pdf=True, save_pgf=True, save_png=True): - if save_pgf and find_executable('latex'): + if save_pgf and shutil.which('latex'): plt.savefig('{}.pgf'.format(filename), bbox_inches='tight') if save_pdf: plt.savefig('{}.pdf'.format(filename), bbox_inches='tight') From fd7a3282f264e85e9c170f25e567245c0a813604 Mon Sep 17 00:00:00 2001 From: Thomas Baumann <39156931+brownbaerchen@users.noreply.github.com> Date: Mon, 5 May 2025 16:21:31 +0200 Subject: [PATCH 3/3] Added pytest-isolate-mpi to firedrake tests --- .github/workflows/ci_pipeline.yml | 1 + pySDC/tests/test_benchmarks/test_collocation.py | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/.github/workflows/ci_pipeline.yml b/.github/workflows/ci_pipeline.yml index 586ef8f9c0..caa2089499 100644 --- a/.github/workflows/ci_pipeline.yml +++ b/.github/workflows/ci_pipeline.yml @@ -204,6 +204,7 @@ jobs: . venv-pySDC/bin/activate pip install -e /repositories/pySDC pip install qmat + pip install pytest-isolate-mpi # test installation python -c "import pySDC; print(f'pySDC module: {pySDC}')" - name: Install gusto diff --git a/pySDC/tests/test_benchmarks/test_collocation.py b/pySDC/tests/test_benchmarks/test_collocation.py index 14cd361d29..1fcfadba7d 100644 --- a/pySDC/tests/test_benchmarks/test_collocation.py +++ b/pySDC/tests/test_benchmarks/test_collocation.py @@ -25,6 +25,7 @@ def wrapper(): benchmark(wrapper) +@pytest.mark.base @pytest.mark.parametrize("node_type", node_types) @pytest.mark.parametrize("quad_type", quad_types) def test_canintegratepolynomials(node_type, quad_type): @@ -61,6 +62,7 @@ def test_canintegratepolynomials(node_type, quad_type): ) +@pytest.mark.base @pytest.mark.parametrize("node_type", node_types) @pytest.mark.parametrize("quad_type", quad_types) def test_relateQandSmat(node_type, quad_type): @@ -82,6 +84,7 @@ def test_relateQandSmat(node_type, quad_type): ) +@pytest.mark.base @pytest.mark.parametrize("node_type", node_types) @pytest.mark.parametrize("quad_type", quad_types) def test_partialquadraturewithQ(node_type, quad_type): @@ -104,6 +107,7 @@ def test_partialquadraturewithQ(node_type, quad_type): ) +@pytest.mark.base @pytest.mark.parametrize("node_type", node_types) @pytest.mark.parametrize("quad_type", quad_types) def test_partialquadraturewithS(node_type, quad_type):