scitiff 0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- scitiff-0/.copier-answers.yml +13 -0
- scitiff-0/.github/dependabot.yml +13 -0
- scitiff-0/.github/workflows/ci.yml +58 -0
- scitiff-0/.github/workflows/docs.yml +79 -0
- scitiff-0/.github/workflows/nightly_at_main.yml +34 -0
- scitiff-0/.github/workflows/nightly_at_release.yml +41 -0
- scitiff-0/.github/workflows/python-version-ci +1 -0
- scitiff-0/.github/workflows/release.yml +115 -0
- scitiff-0/.github/workflows/test.yml +79 -0
- scitiff-0/.github/workflows/unpinned.yml +41 -0
- scitiff-0/.github/workflows/weekly_windows_macos.yml +42 -0
- scitiff-0/.gitignore +49 -0
- scitiff-0/.pre-commit-config.yaml +54 -0
- scitiff-0/.python-version +1 -0
- scitiff-0/CODE_OF_CONDUCT.md +134 -0
- scitiff-0/CONTRIBUTING.md +30 -0
- scitiff-0/LICENSE +33 -0
- scitiff-0/MANIFEST.in +1 -0
- scitiff-0/PKG-INFO +79 -0
- scitiff-0/README.md +16 -0
- scitiff-0/conda/meta.yaml +57 -0
- scitiff-0/docs/_static/anaconda-icon.js +13 -0
- scitiff-0/docs/_templates/class-template.rst +31 -0
- scitiff-0/docs/_templates/doc_version.html +6 -0
- scitiff-0/docs/_templates/module-template.rst +66 -0
- scitiff-0/docs/about/index.md +34 -0
- scitiff-0/docs/api-reference/index.md +29 -0
- scitiff-0/docs/conf.py +246 -0
- scitiff-0/docs/developer/coding-conventions.md +117 -0
- scitiff-0/docs/developer/dependency-management.md +13 -0
- scitiff-0/docs/developer/getting-started.md +91 -0
- scitiff-0/docs/developer/index.md +16 -0
- scitiff-0/docs/index.md +26 -0
- scitiff-0/docs/user-guide/index.md +11 -0
- scitiff-0/docs/user-guide/io.ipynb +109 -0
- scitiff-0/pyproject.toml +121 -0
- scitiff-0/requirements/base.in +6 -0
- scitiff-0/requirements/base.txt +15 -0
- scitiff-0/requirements/basetest.in +10 -0
- scitiff-0/requirements/basetest.txt +19 -0
- scitiff-0/requirements/ci.in +4 -0
- scitiff-0/requirements/ci.txt +58 -0
- scitiff-0/requirements/dev.in +11 -0
- scitiff-0/requirements/dev.txt +133 -0
- scitiff-0/requirements/docs.in +11 -0
- scitiff-0/requirements/docs.txt +259 -0
- scitiff-0/requirements/make_base.py +78 -0
- scitiff-0/requirements/mypy.in +2 -0
- scitiff-0/requirements/mypy.txt +14 -0
- scitiff-0/requirements/nightly.in +6 -0
- scitiff-0/requirements/nightly.txt +27 -0
- scitiff-0/requirements/static.in +1 -0
- scitiff-0/requirements/static.txt +25 -0
- scitiff-0/requirements/test.in +4 -0
- scitiff-0/requirements/test.txt +9 -0
- scitiff-0/requirements/wheels.in +1 -0
- scitiff-0/requirements/wheels.txt +15 -0
- scitiff-0/setup.cfg +4 -0
- scitiff-0/src/scitiff/__init__.py +12 -0
- scitiff-0/src/scitiff/_resources/schema.json +12 -0
- scitiff-0/src/scitiff/_resources/scipp_dataarray_schema.json +31 -0
- scitiff-0/src/scitiff/_resources/scipp_variable_schema.json +40 -0
- scitiff-0/src/scitiff/io.py +96 -0
- scitiff-0/src/scitiff/py.typed +0 -0
- scitiff-0/src/scitiff.egg-info/PKG-INFO +79 -0
- scitiff-0/src/scitiff.egg-info/SOURCES.txt +69 -0
- scitiff-0/src/scitiff.egg-info/dependency_links.txt +1 -0
- scitiff-0/src/scitiff.egg-info/requires.txt +8 -0
- scitiff-0/src/scitiff.egg-info/top_level.txt +1 -0
- scitiff-0/tests/package_test.py +20 -0
- scitiff-0/tox.ini +70 -0
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# Changes here will be overwritten by Copier; NEVER EDIT MANUALLY
|
|
2
|
+
_commit: d704227
|
|
3
|
+
_src_path: gh:scipp/copier_template
|
|
4
|
+
description: Scientific tiff format for imaging experiments.
|
|
5
|
+
max_python: '3.12'
|
|
6
|
+
min_python: '3.10'
|
|
7
|
+
namespace_package: ''
|
|
8
|
+
nightly_deps: ''
|
|
9
|
+
orgname: ess-dmsc-dram
|
|
10
|
+
prettyname: SciTiff
|
|
11
|
+
projectname: scitiff
|
|
12
|
+
related_projects: Scipp,Plopp,ESSImaging,EasyImaging
|
|
13
|
+
year: 2025
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
version: 2
|
|
2
|
+
updates:
|
|
3
|
+
# Note: We are not listing package-ecosystem: "github-actions". This causes
|
|
4
|
+
# noise in all template instances. Instead dependabot.yml in scipp/copier_template
|
|
5
|
+
# triggers updates of github-actions in the *template*. We then use `copier update`
|
|
6
|
+
# in template instances.
|
|
7
|
+
- package-ecosystem: "pip"
|
|
8
|
+
directory: "/requirements"
|
|
9
|
+
schedule:
|
|
10
|
+
interval: "daily"
|
|
11
|
+
allow:
|
|
12
|
+
- dependency-name: "scipp"
|
|
13
|
+
dependency-type: "direct"
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- main
|
|
7
|
+
- release
|
|
8
|
+
pull_request:
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
formatting:
|
|
12
|
+
name: Formatting and static analysis
|
|
13
|
+
runs-on: 'ubuntu-24.04'
|
|
14
|
+
outputs:
|
|
15
|
+
min_python: ${{ steps.vars.outputs.min_python }}
|
|
16
|
+
min_tox_env: ${{ steps.vars.outputs.min_tox_env }}
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
- name: Get Python version for other CI jobs
|
|
20
|
+
id: vars
|
|
21
|
+
run: |
|
|
22
|
+
echo "min_python=$(< .github/workflows/python-version-ci)" >> "$GITHUB_OUTPUT"
|
|
23
|
+
echo "min_tox_env=py$(sed 's/\.//g' < .github/workflows/python-version-ci)" >> "$GITHUB_OUTPUT"
|
|
24
|
+
- uses: actions/setup-python@v5
|
|
25
|
+
with:
|
|
26
|
+
python-version-file: '.github/workflows/python-version-ci'
|
|
27
|
+
- uses: pre-commit/action@v3.0.1
|
|
28
|
+
with:
|
|
29
|
+
extra_args: --all-files
|
|
30
|
+
- uses: pre-commit-ci/lite-action@v1.1.0
|
|
31
|
+
if: always()
|
|
32
|
+
with:
|
|
33
|
+
msg: Apply automatic formatting
|
|
34
|
+
|
|
35
|
+
tests:
|
|
36
|
+
name: Tests
|
|
37
|
+
needs: formatting
|
|
38
|
+
strategy:
|
|
39
|
+
matrix:
|
|
40
|
+
os: ['ubuntu-24.04']
|
|
41
|
+
python:
|
|
42
|
+
- version: '${{needs.formatting.outputs.min_python}}'
|
|
43
|
+
tox-env: '${{needs.formatting.outputs.min_tox_env}}'
|
|
44
|
+
uses: ./.github/workflows/test.yml
|
|
45
|
+
with:
|
|
46
|
+
os-variant: ${{ matrix.os }}
|
|
47
|
+
python-version: ${{ matrix.python.version }}
|
|
48
|
+
tox-env: ${{ matrix.python.tox-env }}
|
|
49
|
+
secrets: inherit
|
|
50
|
+
|
|
51
|
+
docs:
|
|
52
|
+
needs: tests
|
|
53
|
+
uses: ./.github/workflows/docs.yml
|
|
54
|
+
with:
|
|
55
|
+
publish: false
|
|
56
|
+
linkcheck: ${{ github.ref == 'refs/heads/main' }}
|
|
57
|
+
branch: ${{ github.head_ref == '' && github.ref_name || github.head_ref }}
|
|
58
|
+
secrets: inherit
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
name: Docs
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
inputs:
|
|
6
|
+
publish:
|
|
7
|
+
default: false
|
|
8
|
+
type: boolean
|
|
9
|
+
version:
|
|
10
|
+
default: ''
|
|
11
|
+
required: false
|
|
12
|
+
type: string
|
|
13
|
+
branch:
|
|
14
|
+
description: 'Branch/tag with documentation source. If not set, the current branch will be used.'
|
|
15
|
+
default: ''
|
|
16
|
+
required: false
|
|
17
|
+
type: string
|
|
18
|
+
workflow_call:
|
|
19
|
+
inputs:
|
|
20
|
+
publish:
|
|
21
|
+
default: false
|
|
22
|
+
type: boolean
|
|
23
|
+
version:
|
|
24
|
+
default: ''
|
|
25
|
+
required: false
|
|
26
|
+
type: string
|
|
27
|
+
branch:
|
|
28
|
+
description: 'Branch/tag with documentation source. If not set, the current branch will be used.'
|
|
29
|
+
default: ''
|
|
30
|
+
required: false
|
|
31
|
+
type: string
|
|
32
|
+
linkcheck:
|
|
33
|
+
description: 'Run the link checker. If not set the link checker will not be run.'
|
|
34
|
+
default: false
|
|
35
|
+
required: false
|
|
36
|
+
type: boolean
|
|
37
|
+
|
|
38
|
+
env:
|
|
39
|
+
VERSION: ${{ inputs.version }}
|
|
40
|
+
|
|
41
|
+
jobs:
|
|
42
|
+
docs:
|
|
43
|
+
name: Build documentation
|
|
44
|
+
runs-on: 'ubuntu-24.04'
|
|
45
|
+
env:
|
|
46
|
+
ESS_PROTECTED_FILESTORE_USERNAME: ${{ secrets.ESS_PROTECTED_FILESTORE_USERNAME }}
|
|
47
|
+
ESS_PROTECTED_FILESTORE_PASSWORD: ${{ secrets.ESS_PROTECTED_FILESTORE_PASSWORD }}
|
|
48
|
+
|
|
49
|
+
steps:
|
|
50
|
+
- run: sudo apt install --yes graphviz pandoc
|
|
51
|
+
- uses: actions/checkout@v4
|
|
52
|
+
with:
|
|
53
|
+
ref: ${{ inputs.branch == '' && github.ref_name || inputs.branch }}
|
|
54
|
+
repository: ${{ github.event.pull_request.head.repo.full_name }}
|
|
55
|
+
fetch-depth: 0 # history required so cmake can determine version
|
|
56
|
+
- uses: actions/setup-python@v5
|
|
57
|
+
with:
|
|
58
|
+
python-version-file: '.github/workflows/python-version-ci'
|
|
59
|
+
- run: python -m pip install --upgrade pip
|
|
60
|
+
- run: python -m pip install -r requirements/ci.txt
|
|
61
|
+
- run: tox -e releasedocs -- "${VERSION}"
|
|
62
|
+
if: ${{ inputs.version != '' }}
|
|
63
|
+
- run: tox -e docs
|
|
64
|
+
if: ${{ inputs.version == '' }}
|
|
65
|
+
# - run: tox -e linkcheck # Skip linkcheck for now
|
|
66
|
+
# if: ${{ inputs.linkcheck }}
|
|
67
|
+
- uses: actions/upload-artifact@v4
|
|
68
|
+
id: artifact-upload-step
|
|
69
|
+
with:
|
|
70
|
+
name: docs_html
|
|
71
|
+
path: html/
|
|
72
|
+
- run: echo "::notice::https://remote-unzip.deno.dev/${{ github.repository }}/artifacts/${{ steps.artifact-upload-step.outputs.artifact-id }}"
|
|
73
|
+
|
|
74
|
+
- uses: JamesIves/github-pages-deploy-action@v4.7.2
|
|
75
|
+
if: ${{ inputs.publish }}
|
|
76
|
+
with:
|
|
77
|
+
branch: gh-pages
|
|
78
|
+
folder: html
|
|
79
|
+
single-commit: true
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
name: Nightly test at main branch
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
schedule:
|
|
6
|
+
- cron: '30 1 * * 1-5'
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
setup:
|
|
10
|
+
name: Setup variables
|
|
11
|
+
runs-on: 'ubuntu-24.04'
|
|
12
|
+
outputs:
|
|
13
|
+
min_python: ${{ steps.vars.outputs.min_python }}
|
|
14
|
+
steps:
|
|
15
|
+
- uses: actions/checkout@v4
|
|
16
|
+
- name: Get Python version for other CI jobs
|
|
17
|
+
id: vars
|
|
18
|
+
run: echo "min_python=$(< .github/workflows/python-version-ci)" >> "$GITHUB_OUTPUT"
|
|
19
|
+
|
|
20
|
+
tests:
|
|
21
|
+
name: Tests
|
|
22
|
+
needs: setup
|
|
23
|
+
strategy:
|
|
24
|
+
matrix:
|
|
25
|
+
os: ['ubuntu-24.04']
|
|
26
|
+
python:
|
|
27
|
+
- version: '${{needs.setup.outputs.min_python}}'
|
|
28
|
+
tox-env: 'nightly'
|
|
29
|
+
uses: ./.github/workflows/test.yml
|
|
30
|
+
with:
|
|
31
|
+
os-variant: ${{ matrix.os }}
|
|
32
|
+
python-version: ${{ matrix.python.version }}
|
|
33
|
+
tox-env: ${{ matrix.python.tox-env }}
|
|
34
|
+
secrets: inherit
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
name: Nightly tests at latest release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
schedule:
|
|
6
|
+
- cron: '0 1 * * 1-5'
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
setup:
|
|
10
|
+
name: Setup variables
|
|
11
|
+
runs-on: 'ubuntu-24.04'
|
|
12
|
+
outputs:
|
|
13
|
+
min_python: ${{ steps.vars.outputs.min_python }}
|
|
14
|
+
release_tag: ${{ steps.release.outputs.release_tag }}
|
|
15
|
+
steps:
|
|
16
|
+
- uses: actions/checkout@v4
|
|
17
|
+
with:
|
|
18
|
+
fetch-depth: 0 # history required so we can determine latest release tag
|
|
19
|
+
- name: Get last release tag from git
|
|
20
|
+
id: release
|
|
21
|
+
run: echo "release_tag=$(git describe --tags --abbrev=0 --match '[0-9]*.[0-9]*.[0-9]*')" >> "$GITHUB_OUTPUT"
|
|
22
|
+
- name: Get Python version for other CI jobs
|
|
23
|
+
id: vars
|
|
24
|
+
run: echo "min_python=$(cat .github/workflows/python-version-ci)" >> "$GITHUB_OUTPUT"
|
|
25
|
+
|
|
26
|
+
tests:
|
|
27
|
+
name: Tests
|
|
28
|
+
needs: setup
|
|
29
|
+
strategy:
|
|
30
|
+
matrix:
|
|
31
|
+
os: ['ubuntu-24.04']
|
|
32
|
+
python:
|
|
33
|
+
- version: '${{needs.setup.outputs.min_python}}'
|
|
34
|
+
tox-env: 'nightly'
|
|
35
|
+
uses: ./.github/workflows/test.yml
|
|
36
|
+
with:
|
|
37
|
+
os-variant: ${{ matrix.os }}
|
|
38
|
+
python-version: ${{ matrix.python.version }}
|
|
39
|
+
tox-env: ${{ matrix.python.tox-env }}
|
|
40
|
+
checkout_ref: ${{ needs.setup.outputs.release_tag }}
|
|
41
|
+
secrets: inherit
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.10
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
6
|
+
workflow_dispatch:
|
|
7
|
+
|
|
8
|
+
defaults:
|
|
9
|
+
run:
|
|
10
|
+
shell: bash -l {0} # required for conda env
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
build_conda:
|
|
14
|
+
name: Conda build
|
|
15
|
+
runs-on: 'ubuntu-24.04'
|
|
16
|
+
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
with:
|
|
20
|
+
submodules: true
|
|
21
|
+
fetch-depth: 0 # history required so setuptools_scm can determine version
|
|
22
|
+
|
|
23
|
+
- uses: mamba-org/setup-micromamba@v1
|
|
24
|
+
with:
|
|
25
|
+
environment-name: build-env
|
|
26
|
+
create-args: >-
|
|
27
|
+
conda-build
|
|
28
|
+
boa
|
|
29
|
+
- run: conda mambabuild --channel conda-forge --no-anaconda-upload --override-channels --output-folder conda/package conda
|
|
30
|
+
|
|
31
|
+
- uses: actions/upload-artifact@v4
|
|
32
|
+
with:
|
|
33
|
+
name: conda-package-noarch
|
|
34
|
+
path: conda/package/noarch/*.tar.bz2
|
|
35
|
+
|
|
36
|
+
build_wheels:
|
|
37
|
+
name: Wheels
|
|
38
|
+
runs-on: 'ubuntu-24.04'
|
|
39
|
+
|
|
40
|
+
steps:
|
|
41
|
+
- uses: actions/checkout@v4
|
|
42
|
+
with:
|
|
43
|
+
fetch-depth: 0 # history required so setuptools_scm can determine version
|
|
44
|
+
|
|
45
|
+
- uses: actions/setup-python@v5
|
|
46
|
+
with:
|
|
47
|
+
python-version-file: '.github/workflows/python-version-ci'
|
|
48
|
+
|
|
49
|
+
- run: python -m pip install --upgrade pip
|
|
50
|
+
- run: python -m pip install -r requirements/wheels.txt
|
|
51
|
+
|
|
52
|
+
- name: Build wheels
|
|
53
|
+
run: python -m build
|
|
54
|
+
|
|
55
|
+
- name: Upload wheels
|
|
56
|
+
uses: actions/upload-artifact@v4
|
|
57
|
+
with:
|
|
58
|
+
name: dist
|
|
59
|
+
path: dist
|
|
60
|
+
|
|
61
|
+
upload_pypi:
|
|
62
|
+
name: Deploy PyPI
|
|
63
|
+
needs: [build_wheels, build_conda]
|
|
64
|
+
runs-on: 'ubuntu-24.04'
|
|
65
|
+
environment: release
|
|
66
|
+
permissions:
|
|
67
|
+
id-token: write
|
|
68
|
+
if: github.event_name == 'release' && github.event.action == 'published'
|
|
69
|
+
steps:
|
|
70
|
+
- uses: actions/download-artifact@v4
|
|
71
|
+
- uses: pypa/gh-action-pypi-publish@v1.8.14
|
|
72
|
+
|
|
73
|
+
# Skipping conda upload until we have a token.
|
|
74
|
+
# upload_conda:
|
|
75
|
+
# name: Deploy Conda
|
|
76
|
+
# needs: [build_wheels, build_conda]
|
|
77
|
+
# runs-on: 'ubuntu-24.04'
|
|
78
|
+
# if: github.event_name == 'release' && github.event.action == 'published'
|
|
79
|
+
|
|
80
|
+
# steps:
|
|
81
|
+
# - uses: actions/download-artifact@v4
|
|
82
|
+
# - uses: mamba-org/setup-micromamba@v1
|
|
83
|
+
# with:
|
|
84
|
+
# environment-name: upload-env
|
|
85
|
+
# # frozen python due to breaking removal of 'imp' in 3.12
|
|
86
|
+
# create-args: >-
|
|
87
|
+
# anaconda-client
|
|
88
|
+
# python=3.11
|
|
89
|
+
# - run: anaconda --token ${{ secrets.ANACONDATOKEN }} upload --user essdmsc --label main $(ls conda-package-noarch/*.tar.bz2)
|
|
90
|
+
|
|
91
|
+
docs:
|
|
92
|
+
# needs: [upload_conda, upload_pypi]
|
|
93
|
+
needs: [upload_pypi]
|
|
94
|
+
uses: ./.github/workflows/docs.yml
|
|
95
|
+
with:
|
|
96
|
+
publish: ${{ github.event_name == 'release' && github.event.action == 'published' }}
|
|
97
|
+
secrets: inherit
|
|
98
|
+
|
|
99
|
+
assets:
|
|
100
|
+
name: Upload docs
|
|
101
|
+
needs: docs
|
|
102
|
+
runs-on: 'ubuntu-24.04'
|
|
103
|
+
permissions:
|
|
104
|
+
contents: write # This is needed so that the action can upload the asset
|
|
105
|
+
steps:
|
|
106
|
+
- uses: actions/download-artifact@v4
|
|
107
|
+
- name: Zip documentation
|
|
108
|
+
run: |
|
|
109
|
+
mv docs_html documentation-${{ github.ref_name }}
|
|
110
|
+
zip -r documentation-${{ github.ref_name }}.zip documentation-${{ github.ref_name }}
|
|
111
|
+
- name: Upload release assets
|
|
112
|
+
uses: svenstaro/upload-release-action@v2
|
|
113
|
+
with:
|
|
114
|
+
file: ./documentation-${{ github.ref_name }}.zip
|
|
115
|
+
overwrite: false
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
name: Test
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
inputs:
|
|
6
|
+
os-variant:
|
|
7
|
+
default: 'ubuntu-24.04'
|
|
8
|
+
type: string
|
|
9
|
+
python-version:
|
|
10
|
+
type: string
|
|
11
|
+
tox-env:
|
|
12
|
+
default: 'test'
|
|
13
|
+
type: string
|
|
14
|
+
pip-recipe:
|
|
15
|
+
default: 'requirements/ci.txt'
|
|
16
|
+
type: string
|
|
17
|
+
coverage-report:
|
|
18
|
+
default: false
|
|
19
|
+
type: boolean
|
|
20
|
+
checkout_ref:
|
|
21
|
+
default: ''
|
|
22
|
+
type: string
|
|
23
|
+
workflow_call:
|
|
24
|
+
inputs:
|
|
25
|
+
os-variant:
|
|
26
|
+
default: 'ubuntu-24.04'
|
|
27
|
+
type: string
|
|
28
|
+
python-version:
|
|
29
|
+
type: string
|
|
30
|
+
tox-env:
|
|
31
|
+
default: 'test'
|
|
32
|
+
type: string
|
|
33
|
+
pip-recipe:
|
|
34
|
+
default: 'requirements/ci.txt'
|
|
35
|
+
type: string
|
|
36
|
+
coverage-report:
|
|
37
|
+
default: false
|
|
38
|
+
type: boolean
|
|
39
|
+
checkout_ref:
|
|
40
|
+
default: ''
|
|
41
|
+
type: string
|
|
42
|
+
|
|
43
|
+
jobs:
|
|
44
|
+
package-test:
|
|
45
|
+
runs-on: ${{ inputs.os-variant }}
|
|
46
|
+
|
|
47
|
+
steps:
|
|
48
|
+
- uses: actions/checkout@v4
|
|
49
|
+
with:
|
|
50
|
+
ref: ${{ inputs.checkout_ref }}
|
|
51
|
+
- uses: actions/setup-python@v5
|
|
52
|
+
with:
|
|
53
|
+
python-version: ${{ inputs.python-version }}
|
|
54
|
+
- run: python -m pip install --upgrade pip
|
|
55
|
+
- run: python -m pip install .
|
|
56
|
+
- run: python tests/package_test.py
|
|
57
|
+
name: Run package tests
|
|
58
|
+
|
|
59
|
+
test:
|
|
60
|
+
runs-on: ${{ inputs.os-variant }}
|
|
61
|
+
env:
|
|
62
|
+
ESS_PROTECTED_FILESTORE_USERNAME: ${{ secrets.ESS_PROTECTED_FILESTORE_USERNAME }}
|
|
63
|
+
ESS_PROTECTED_FILESTORE_PASSWORD: ${{ secrets.ESS_PROTECTED_FILESTORE_PASSWORD }}
|
|
64
|
+
|
|
65
|
+
steps:
|
|
66
|
+
- uses: actions/checkout@v4
|
|
67
|
+
with:
|
|
68
|
+
ref: ${{ inputs.checkout_ref }}
|
|
69
|
+
- uses: actions/setup-python@v5
|
|
70
|
+
with:
|
|
71
|
+
python-version: ${{ inputs.python-version }}
|
|
72
|
+
- run: python -m pip install --upgrade pip
|
|
73
|
+
- run: python -m pip install -r ${{ inputs.pip-recipe }}
|
|
74
|
+
- run: tox -e ${{ inputs.tox-env }}
|
|
75
|
+
- uses: actions/upload-artifact@v4
|
|
76
|
+
if: ${{ inputs.coverage-report }}
|
|
77
|
+
with:
|
|
78
|
+
name: CoverageReport
|
|
79
|
+
path: coverage_html/
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
name: Unpinned tests at latest release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
schedule:
|
|
6
|
+
- cron: '0 2 * * 1'
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
setup:
|
|
10
|
+
name: Setup variables
|
|
11
|
+
runs-on: 'ubuntu-24.04'
|
|
12
|
+
outputs:
|
|
13
|
+
min_python: ${{ steps.vars.outputs.min_python }}
|
|
14
|
+
release_tag: ${{ steps.release.outputs.release_tag }}
|
|
15
|
+
steps:
|
|
16
|
+
- uses: actions/checkout@v4
|
|
17
|
+
with:
|
|
18
|
+
fetch-depth: 0 # history required so we can determine latest release tag
|
|
19
|
+
- name: Get last release tag from git
|
|
20
|
+
id: release
|
|
21
|
+
run: echo "release_tag=$(git describe --tags --abbrev=0 --match '[0-9]*.[0-9]*.[0-9]*')" >> "$GITHUB_OUTPUT"
|
|
22
|
+
- name: Get Python version for other CI jobs
|
|
23
|
+
id: vars
|
|
24
|
+
run: echo "min_python=$(cat .github/workflows/python-version-ci)" >> "$GITHUB_OUTPUT"
|
|
25
|
+
|
|
26
|
+
tests:
|
|
27
|
+
name: Tests
|
|
28
|
+
needs: setup
|
|
29
|
+
strategy:
|
|
30
|
+
matrix:
|
|
31
|
+
os: ['ubuntu-24.04']
|
|
32
|
+
python:
|
|
33
|
+
- version: '${{needs.setup.outputs.min_python}}'
|
|
34
|
+
tox-env: 'unpinned'
|
|
35
|
+
uses: ./.github/workflows/test.yml
|
|
36
|
+
with:
|
|
37
|
+
os-variant: ${{ matrix.os }}
|
|
38
|
+
python-version: ${{ matrix.python.version }}
|
|
39
|
+
tox-env: ${{ matrix.python.tox-env }}
|
|
40
|
+
checkout_ref: ${{ needs.setup.outputs.release_tag }}
|
|
41
|
+
secrets: inherit
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
name: Windows and MacOS weekly tests
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
schedule:
|
|
6
|
+
- cron: '0 2 * * 1'
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
pytox:
|
|
10
|
+
name: Python and Tox env
|
|
11
|
+
runs-on: 'ubuntu-24.04'
|
|
12
|
+
outputs:
|
|
13
|
+
min_python: ${{ steps.vars.outputs.min_python }}
|
|
14
|
+
min_tox_env: ${{ steps.vars.outputs.min_tox_env }}
|
|
15
|
+
steps:
|
|
16
|
+
- uses: actions/checkout@v4
|
|
17
|
+
- name: Get Python version for other CI jobs
|
|
18
|
+
id: vars
|
|
19
|
+
run: |
|
|
20
|
+
echo "min_python=$(cat .github/workflows/python-version-ci)" >> $GITHUB_OUTPUT
|
|
21
|
+
echo "min_tox_env=py$(cat .github/workflows/python-version-ci | sed 's/\.//g')" >> $GITHUB_OUTPUT
|
|
22
|
+
tests:
|
|
23
|
+
name: Tests
|
|
24
|
+
needs: pytox
|
|
25
|
+
strategy:
|
|
26
|
+
matrix:
|
|
27
|
+
os: ['macos-latest', 'windows-latest']
|
|
28
|
+
python:
|
|
29
|
+
- version: '${{needs.pytox.outputs.min_python}}'
|
|
30
|
+
tox-env: '${{needs.pytox.outputs.min_tox_env}}'
|
|
31
|
+
uses: ./.github/workflows/test.yml
|
|
32
|
+
with:
|
|
33
|
+
os-variant: ${{ matrix.os }}
|
|
34
|
+
python-version: ${{ matrix.python.version }}
|
|
35
|
+
tox-env: ${{ matrix.python.tox-env }}
|
|
36
|
+
|
|
37
|
+
docs:
|
|
38
|
+
needs: tests
|
|
39
|
+
uses: ./.github/workflows/docs.yml
|
|
40
|
+
with:
|
|
41
|
+
publish: false
|
|
42
|
+
branch: ${{ github.head_ref == '' && github.ref_name || github.head_ref }}
|
scitiff-0/.gitignore
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Build artifacts
|
|
2
|
+
build
|
|
3
|
+
dist
|
|
4
|
+
html
|
|
5
|
+
.tox
|
|
6
|
+
*.egg-info
|
|
7
|
+
# we lock dependencies with pip-compile, not uv
|
|
8
|
+
uv.lock
|
|
9
|
+
|
|
10
|
+
*.sw?
|
|
11
|
+
|
|
12
|
+
# Environments
|
|
13
|
+
venv
|
|
14
|
+
.venv
|
|
15
|
+
|
|
16
|
+
# Caches
|
|
17
|
+
.clangd/
|
|
18
|
+
*.ipynb_checkpoints
|
|
19
|
+
__pycache__/
|
|
20
|
+
.vs/
|
|
21
|
+
.virtual_documents
|
|
22
|
+
.hypothesis
|
|
23
|
+
.pytest_cache
|
|
24
|
+
.mypy_cache
|
|
25
|
+
docs/generated/
|
|
26
|
+
.ruff_cache
|
|
27
|
+
|
|
28
|
+
# Editor settings
|
|
29
|
+
.idea/
|
|
30
|
+
.vscode/
|
|
31
|
+
|
|
32
|
+
# Data files
|
|
33
|
+
*.data
|
|
34
|
+
*.dat
|
|
35
|
+
*.csv
|
|
36
|
+
*.xye
|
|
37
|
+
*.h5
|
|
38
|
+
*.hdf5
|
|
39
|
+
*.hdf
|
|
40
|
+
*.nxs
|
|
41
|
+
*.raw
|
|
42
|
+
*.cif
|
|
43
|
+
*.rcif
|
|
44
|
+
*.ort
|
|
45
|
+
*.zip
|
|
46
|
+
*.sqw
|
|
47
|
+
*.nxspe
|
|
48
|
+
*.tiff
|
|
49
|
+
*.tif
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
repos:
|
|
2
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
3
|
+
rev: v5.0.0
|
|
4
|
+
hooks:
|
|
5
|
+
- id: check-added-large-files
|
|
6
|
+
- id: check-case-conflict
|
|
7
|
+
- id: check-illegal-windows-names
|
|
8
|
+
- id: check-json
|
|
9
|
+
exclude: asv.conf.json
|
|
10
|
+
- id: check-merge-conflict
|
|
11
|
+
- id: check-toml
|
|
12
|
+
- id: check-yaml
|
|
13
|
+
exclude: conda/meta.yaml
|
|
14
|
+
- id: detect-private-key
|
|
15
|
+
- id: trailing-whitespace
|
|
16
|
+
args: [ --markdown-linebreak-ext=md ]
|
|
17
|
+
exclude: '\.svg'
|
|
18
|
+
- repo: https://github.com/kynan/nbstripout
|
|
19
|
+
rev: 0.7.1
|
|
20
|
+
hooks:
|
|
21
|
+
- id: nbstripout
|
|
22
|
+
types: [ "jupyter" ]
|
|
23
|
+
args: [ "--drop-empty-cells",
|
|
24
|
+
"--extra-keys 'metadata.language_info.version cell.metadata.jp-MarkdownHeadingCollapsed cell.metadata.pycharm'" ]
|
|
25
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
26
|
+
rev: v0.8.0
|
|
27
|
+
hooks:
|
|
28
|
+
- id: ruff
|
|
29
|
+
args: [ --fix ]
|
|
30
|
+
types_or: [ python, pyi, jupyter ]
|
|
31
|
+
- id: ruff-format
|
|
32
|
+
types_or: [ python, pyi ]
|
|
33
|
+
- repo: https://github.com/codespell-project/codespell
|
|
34
|
+
rev: v2.3.0
|
|
35
|
+
hooks:
|
|
36
|
+
- id: codespell
|
|
37
|
+
additional_dependencies:
|
|
38
|
+
- tomli
|
|
39
|
+
- repo: https://github.com/pre-commit/pygrep-hooks
|
|
40
|
+
rev: v1.10.0
|
|
41
|
+
hooks:
|
|
42
|
+
- id: python-no-eval
|
|
43
|
+
- id: python-no-log-warn
|
|
44
|
+
- id: python-use-type-annotations
|
|
45
|
+
- id: rst-backticks
|
|
46
|
+
- id: rst-directive-colons
|
|
47
|
+
- id: rst-inline-touching-normal
|
|
48
|
+
- id: text-unicode-replacement-char
|
|
49
|
+
- repo: https://github.com/rhysd/actionlint
|
|
50
|
+
rev: v1.7.3
|
|
51
|
+
hooks:
|
|
52
|
+
- id: actionlint
|
|
53
|
+
# Disable because of false-positive SC2046
|
|
54
|
+
args: ["-shellcheck="]
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.10
|