Skip to content
Snippets Groups Projects
Commit d0e43823 authored by Markus Holzer's avatar Markus Holzer
Browse files

Merge branch 'fhennig/sympy-and-ci' into 'master'

Update SymPy Dependency + Pipeline Cleanup

Closes #91

See merge request !398
parents 5e4c4ad7 1640c92c
Branches
Tags
1 merge request!398Update SymPy Dependency + Pipeline Cleanup
Pipeline #67385 failed with stages
in 16 minutes and 37 seconds
stages: stages:
- pretest - pretest
- test - test
- nightly
- docs
- deploy - deploy
# -------------------------- Templates ------------------------------------------------------------------------------------
# Base configuration for jobs meant to run at every commit
.every-commit:
rules:
- if: $CI_PIPELINE_SOURCE != "schedule"
# Base configuration for jobs meant to run at a schedule
.scheduled:
rules:
- if: $CI_PIPELINE_SOURCE == "schedule"
# -------------------------- Tests ------------------------------------------------------------------------------------ # -------------------------- Tests ------------------------------------------------------------------------------------
# Normal test - runs on every commit all but "long run" tests # Normal test - runs on every commit all but "long run" tests
tests-and-coverage: tests-and-coverage:
stage: pretest stage: pretest
except: extends: .every-commit
variables:
- $ENABLE_NIGHTLY_BUILDS
image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full
before_script: before_script:
- pip install -e . - pip install -e .
...@@ -65,9 +77,7 @@ tests-and-coverage-with-longrun: ...@@ -65,9 +77,7 @@ tests-and-coverage-with-longrun:
# pipeline with latest python version # pipeline with latest python version
latest-python: latest-python:
stage: test stage: test
except: extends: .every-commit
variables:
- $ENABLE_NIGHTLY_BUILDS
image: i10git.cs.fau.de:5005/pycodegen/pycodegen/latest_python image: i10git.cs.fau.de:5005/pycodegen/pycodegen/latest_python
before_script: before_script:
- pip install -e . - pip install -e .
...@@ -92,9 +102,6 @@ latest-python: ...@@ -92,9 +102,6 @@ latest-python:
# Minimal tests in windows environment # Minimal tests in windows environment
#minimal-windows: #minimal-windows:
# stage: test # stage: test
# except:
# variables:
# - $ENABLE_NIGHTLY_BUILDS
# tags: # tags:
# - win # - win
# script: # script:
...@@ -108,9 +115,7 @@ latest-python: ...@@ -108,9 +115,7 @@ latest-python:
ubuntu: ubuntu:
stage: test stage: test
except: extends: .every-commit
variables:
- $ENABLE_NIGHTLY_BUILDS
image: i10git.cs.fau.de:5005/pycodegen/pycodegen/ubuntu image: i10git.cs.fau.de:5005/pycodegen/pycodegen/ubuntu
before_script: before_script:
- ln -s /usr/include/locale.h /usr/include/xlocale.h - ln -s /usr/include/locale.h /usr/include/xlocale.h
...@@ -134,9 +139,7 @@ ubuntu: ...@@ -134,9 +139,7 @@ ubuntu:
.multiarch_template: .multiarch_template:
stage: test stage: test
except: extends: .every-commit
variables:
- $ENABLE_NIGHTLY_BUILDS
before_script: &multiarch_before_script before_script: &multiarch_before_script
# - pip3 install -v . # - pip3 install -v .
- export PYTHONPATH=src - export PYTHONPATH=src
...@@ -205,9 +208,7 @@ riscv64: ...@@ -205,9 +208,7 @@ riscv64:
minimal-conda: minimal-conda:
stage: pretest stage: pretest
except: extends: .every-commit
variables:
- $ENABLE_NIGHTLY_BUILDS
image: i10git.cs.fau.de:5005/pycodegen/pycodegen/minimal_conda image: i10git.cs.fau.de:5005/pycodegen/pycodegen/minimal_conda
before_script: before_script:
- pip install -e . - pip install -e .
...@@ -220,9 +221,7 @@ minimal-conda: ...@@ -220,9 +221,7 @@ minimal-conda:
minimal-sympy-master: minimal-sympy-master:
stage: test stage: test
except: extends: .every-commit
variables:
- $ENABLE_NIGHTLY_BUILDS
image: i10git.cs.fau.de:5005/pycodegen/pycodegen/minimal_conda image: i10git.cs.fau.de:5005/pycodegen/pycodegen/minimal_conda
before_script: before_script:
- pip install -e . - pip install -e .
...@@ -279,14 +278,42 @@ pycodegen-integration: ...@@ -279,14 +278,42 @@ pycodegen-integration:
reports: reports:
junit: pycodegen/*/report.xml junit: pycodegen/*/report.xml
# -------------------- Scheduled Tasks --------------------------------------------------------------------------
# Nightly test against the latest (pre-release) version of SymPy published on PyPI
nightly-sympy:
stage: nightly
needs: []
extends: .scheduled
image: i10git.cs.fau.de:5005/pycodegen/pycodegen/latest_python
before_script:
- pip install -e .
- pip install --upgrade --pre sympy
script:
- env
- pip list
- export NUM_CORES=$(nproc --all)
- mkdir -p ~/.config/matplotlib
- echo "backend:template" > ~/.config/matplotlib/matplotlibrc
- mkdir public
- pytest -v -n $NUM_CORES -m "not longrun" --junitxml=report.xml
tags:
- docker
- AVX
- cuda
artifacts:
when: always
reports:
junit: report.xml
# -------------------- Linter & Documentation -------------------------------------------------------------------------- # -------------------- Linter & Documentation --------------------------------------------------------------------------
flake8-lint: flake8-lint:
stage: pretest stage: pretest
except: extends: .every-commit
variables:
- $ENABLE_NIGHTLY_BUILDS
image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full
script: script:
- flake8 src/pystencils - flake8 src/pystencils
...@@ -295,8 +322,10 @@ flake8-lint: ...@@ -295,8 +322,10 @@ flake8-lint:
build-documentation: build-documentation:
stage: test stage: docs
extends: .every-commit
image: i10git.cs.fau.de:5005/pycodegen/pycodegen/documentation image: i10git.cs.fau.de:5005/pycodegen/pycodegen/documentation
needs: []
before_script: before_script:
- pip install -e . - pip install -e .
script: script:
...@@ -312,7 +341,9 @@ build-documentation: ...@@ -312,7 +341,9 @@ build-documentation:
pages: pages:
image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full
# extends: .every-commit
stage: deploy stage: deploy
needs: ["build-documentation"]
script: script:
- ls -l - ls -l
- mv coverage_report html_doc - mv coverage_report html_doc
......
...@@ -12,7 +12,7 @@ authors = [ ...@@ -12,7 +12,7 @@ authors = [
] ]
license = { file = "COPYING.txt" } license = { file = "COPYING.txt" }
requires-python = ">=3.10" requires-python = ">=3.10"
dependencies = ["sympy>=1.6,<=1.11.1", "numpy>=1.8.0", "appdirs", "joblib", "pyyaml"] dependencies = ["sympy>=1.9,<=1.12.1", "numpy>=1.8.0", "appdirs", "joblib", "pyyaml"]
classifiers = [ classifiers = [
"Development Status :: 4 - Beta", "Development Status :: 4 - Beta",
"Framework :: Jupyter", "Framework :: Jupyter",
......
...@@ -35,11 +35,11 @@ class FlagInterface: ...@@ -35,11 +35,11 @@ class FlagInterface:
>>> dh = create_data_handling((4, 5)) >>> dh = create_data_handling((4, 5))
>>> fi = FlagInterface(dh, 'flag_field', np.uint8) >>> fi = FlagInterface(dh, 'flag_field', np.uint8)
>>> assert dh.has_data('flag_field') >>> assert dh.has_data('flag_field')
>>> fi.reserve_next_flag() >>> int(fi.reserve_next_flag())
2 2
>>> fi.reserve_flag(4) >>> int(fi.reserve_flag(4))
4 4
>>> fi.reserve_next_flag() >>> int(fi.reserve_next_flag())
8 8
""" """
......
...@@ -82,8 +82,8 @@ def boolean_array_bounding_box(boolean_array): ...@@ -82,8 +82,8 @@ def boolean_array_bounding_box(boolean_array):
>>> a = np.zeros((4, 4), dtype=bool) >>> a = np.zeros((4, 4), dtype=bool)
>>> a[1:-1, 1:-1] = True >>> a[1:-1, 1:-1] = True
>>> boolean_array_bounding_box(a) >>> boolean_array_bounding_box(a) == [(1, 3), (1, 3)]
[(1, 3), (1, 3)] True
""" """
dim = boolean_array.ndim dim = boolean_array.ndim
shape = boolean_array.shape shape = boolean_array.shape
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment