Skip to content

Commit 6cd9152

Browse files
committed
Merge branch 'devel' into Issue1149_MoveDiags
2 parents 1b20162 + f5eb512 commit 6cd9152

File tree

88 files changed

+860
-5012
lines changed

Some content is hidden

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

88 files changed

+860
-5012
lines changed

.coveragerc

Lines changed: 0 additions & 30 deletions
This file was deleted.

.github/workflows/test-complete-matrix.yml

Lines changed: 49 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,13 @@ name: Complete testing matrix
22

33
on:
44
push:
5-
branches: [ devel, master ]
5+
branches:
6+
- devel
7+
- master
68
pull_request:
7-
branches: [ devel, master ]
9+
branches:
10+
- devel
11+
- master
812

913
jobs:
1014
build:
@@ -14,51 +18,63 @@ jobs:
1418
strategy:
1519
matrix:
1620
os: [ubuntu-latest]
17-
# macOS-latest: issue with latex
18-
# windows-latest: issue with TcL install error
19-
python-version: ['3.8', '3.9', '3.10', '3.11']
21+
# macOS-latest: issue with latex + meson fails build
22+
# windows-latest: issue with TcL install error + meson fails to build
23+
python-version: ['3.9', '3.10', '3.11']
2024
exclude:
2125
- python-version: ['3.11']
2226
os: windows-latest
2327

2428
steps:
29+
30+
# Install latex
2531
- name: Install latex for matplotlib
32+
shell: bash
2633
run: |
2734
if [ "$RUNNER_OS" == "Linux" ]; then
28-
sudo apt-get install texlive texlive-latex-extra texlive-fonts-recommended dvipng cm-super
29-
pip install latex
35+
sudo apt update
36+
sudo apt install texlive texlive-latex-extra texlive-fonts-recommended dvipng cm-super
3037
elif [ "$RUNNER_OS" == "macOS" ]; then
31-
# not enough to fix latex issue
32-
brew install --cask mactex
33-
pip install latex
34-
else
38+
# not enough to fix latex issue
39+
sudo brew install --cask mactex
40+
elif [ "$RUNNER_OS" != "Linux" ]; then
3541
echo "$RUNNER_OS not supported"
36-
exit 1
42+
exit 0
3743
fi
38-
- uses: actions/checkout@v4
39-
- name: Set up Python ${{ matrix.python-version }}
40-
uses: actions/setup-python@v5
44+
45+
# git checkout
46+
- name: git checkout
47+
uses: actions/checkout@v5
4148
with:
42-
python-version: ${{ matrix.python-version }}
43-
- name: Install dependencies
49+
# https://github.com/marketplace/actions/checkout#usage
50+
fetch-depth: 0 # to fetch all history from all branches
51+
fetch-tags: true
52+
53+
# Install uv
54+
- name: Install uv
55+
uses: astral-sh/setup-uv@v5
56+
with:
57+
python-version: ${{ matrix.python-version }}
58+
59+
# Build dist
60+
- name: Build the project
4461
run: |
45-
curl -X PURGE https://pypi.org/simple/datastock/
46-
curl -X PURGE https://pypi.org/simple/bsplines2d/
47-
curl -X PURGE https://pypi.org/simple/spectrally/
48-
pip install --upgrade pip
49-
pip install flake8 pytest coverage wheel
50-
pip install -r requirements.txt --no-cache
51-
- name: Lint with flake8
62+
uv build
63+
64+
# Create and activate env
65+
- name: Create and activate env
5266
run: |
53-
# stop the build if there are Python syntax errors or undefined names
54-
# flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
55-
flake8 . --count --select=E9,F63,F7 --show-source --statistics
56-
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
57-
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
58-
- name: install tofu
67+
uv venv venv --python ${{ matrix.python-version }}
68+
source .venv/bin/activate
69+
uv pip install latex
70+
71+
# Install library
72+
- name: Install the project
5973
run: |
60-
python -c "import setuptools; print(f'\nsetuptools version = {setuptools.__version__}\n')"
61-
pip install -e ".[dev]" --no-build-isolation
74+
uv pip install ./dist/*.whl
75+
76+
# Run tests
6277
- name: Test with pytest and coverage
6378
run: |
64-
coverage run --source=tofu/ -m pytest tofu/tests -v -x --durations=10
79+
cd ./dist/
80+
pytest --pyargs tofu.tests -xv --durations=10
Lines changed: 37 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Ubuntu, py 3.8, pip
1+
name: Ubuntu, py 3.11, pip
22

33
on:
44
push:
@@ -11,36 +11,53 @@ on:
1111
- master
1212
- devel
1313
- deploy-test
14+
1415
jobs:
1516
build-linux:
1617
runs-on: ubuntu-latest
1718
strategy:
1819
max-parallel: 5
1920
steps:
21+
22+
# Install latex
2023
- name: Install latex for matplotlib
2124
run: |
22-
sudo apt-get install texlive texlive-latex-extra texlive-fonts-recommended dvipng cm-super
23-
pip install latex
24-
- uses: actions/checkout@v4
25-
- name: Set up Python 3.9
26-
uses: actions/setup-python@v5
25+
sudo apt update
26+
sudo apt install texlive texlive-latex-extra texlive-fonts-recommended dvipng cm-super
27+
28+
# git checkout
29+
- name: git checkout
30+
uses: actions/checkout@v5
2731
with:
28-
python-version: 3.9
29-
- name: Install dependencies
32+
# https://github.com/marketplace/actions/checkout#usage
33+
fetch-depth: 0 # to fetch all history from all branches
34+
fetch-tags: true
35+
36+
# Install uv
37+
- name: Install uv
38+
uses: astral-sh/setup-uv@v5
39+
with:
40+
python-version: 3.11
41+
42+
# Build dist
43+
- name: Build the project
3044
run: |
31-
pip install --upgrade pip
32-
pip install flake8 pytest coverage wheel
33-
pip install -r requirements.txt # fix
34-
- name: Lint with flake8
45+
uv build
46+
47+
# Create and activate env
48+
- name: Create and activate env
3549
run: |
36-
# stop the build if there are Python syntax errors or undefined names
37-
# too many F82 errors, should uncomment the following line
38-
flake8 . --count --select=E9,F63,F7 --show-source --statistics
39-
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
40-
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
41-
- name: install tofu
50+
uv venv venv --python 3.11
51+
source .venv/bin/activate
52+
uv pip install latex
53+
54+
# Install library
55+
- name: Install the project
4256
run: |
43-
pip install -e ".[dev]" --no-build-isolation
57+
uv pip install ./dist/*.whl
58+
59+
# Run tests
4460
- name: Test with pytest and coverage
4561
run: |
46-
coverage run --source=tofu/ -m pytest tofu/tests -x -v --durations=10
62+
cd ./dist/
63+
pytest --pyargs tofu.tests -xv --durations=10

.travis.yml

Lines changed: 0 additions & 153 deletions
This file was deleted.

LICENSE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2016 Didier Vezinet
3+
Copyright (c) 2023 ToFuProject
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

0 commit comments

Comments
 (0)