Skip to content

Commit

Permalink
bump requirements
Browse files Browse the repository at this point in the history
  • Loading branch information
MridulS committed Sep 18, 2024
1 parent bf074db commit bdd2950
Show file tree
Hide file tree
Showing 22 changed files with 124 additions and 53 deletions.
2 changes: 1 addition & 1 deletion .copier-answers.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Changes here will be overwritten by Copier; NEVER EDIT MANUALLY
_commit: 101e594
_commit: 75b9a8f
_src_path: gh:scipp/copier_template
description: Reflectometry data reduction for the European Spallation Source
max_python: '3.12'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
- uses: pre-commit/action@v3.0.1
with:
extra_args: --all-files
- uses: pre-commit-ci/lite-action@v1.0.2
- uses: pre-commit-ci/lite-action@v1.0.3
if: always()
with:
msg: Apply automatic formatting
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ jobs:
name: docs_html
path: html/

- uses: JamesIves/github-pages-deploy-action@v4.6.3
- uses: JamesIves/github-pages-deploy-action@v4.6.4
if: ${{ inputs.publish }}
with:
branch: gh-pages
Expand Down
15 changes: 15 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,21 @@ on:
type: string

jobs:
package-test:
runs-on: ${{ inputs.os-variant }}

steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.checkout_ref }}
- uses: actions/setup-python@v5
with:
python-version: ${{ inputs.python-version }}
- run: python -m pip install --upgrade pip
- run: python -m pip install .
- run: python tests/package_test.py
name: Run package tests

test:
runs-on: ${{ inputs.os-variant }}
env:
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@ dist
html
.tox
*.egg-info
uv.lock # we lock dependencies with pip-compile, not uv

*.sw?

# Environments
venv
.venv

# Caches
.clangd/
Expand Down Expand Up @@ -39,3 +41,4 @@ docs/generated/
*.cif
*.rcif
*.ort
*.zip
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
rev: v4.6.0
hooks:
- id: check-added-large-files
- id: check-json
Expand All @@ -14,22 +14,22 @@ repos:
args: [ --markdown-linebreak-ext=md ]
exclude: '\.svg'
- repo: https://github.com/kynan/nbstripout
rev: 0.6.0
rev: 0.7.1
hooks:
- id: nbstripout
types: [ "jupyter" ]
args: [ "--drop-empty-cells",
"--extra-keys 'metadata.language_info.version cell.metadata.jp-MarkdownHeadingCollapsed cell.metadata.pycharm'" ]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.4.3
rev: v0.6.2
hooks:
- id: ruff
args: [ --fix ]
types_or: [ python, pyi, jupyter ]
- id: ruff-format
types_or: [ python, pyi ]
- repo: https://github.com/codespell-project/codespell
rev: v2.2.6
rev: v2.3.0
hooks:
- id: codespell
additional_dependencies:
Expand Down
1 change: 1 addition & 0 deletions .python-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.10
8 changes: 8 additions & 0 deletions conda/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ source:

{% set pyproject = load_file_data('pyproject.toml') %}
{% set dependencies = pyproject.get('project', {}).get('dependencies', {}) %}
{% set test_dependencies = pyproject.get('project', {}).get('optional-dependencies', {}).get('test', {}) %}


requirements:
Expand All @@ -31,6 +32,13 @@ test:
requires:
- pytest
- pooch

{# Conda does not allow spaces between package name and version, so remove them #}
{% for package in test_dependencies %}
- {% if package == "graphviz" %}python-graphviz{% else %}{{ package|replace(" ", "") }}{% endif %}
{% endfor %}


source_files:
- pyproject.toml
- tests/
Expand Down
3 changes: 3 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright (c) 2024 Scipp contributors (https://github.com/scipp)

import doctest
import os
import sys
Expand Down
18 changes: 16 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,12 @@ dependencies = [

dynamic = ["version"]

[project.optional-dependencies]
test = [
"pytest",
"pooch",
]

[project.urls]
"Bug Tracker" = "https://github.com/scipp/essreflectometry/issues"
"Documentation" = "https://scipp.github.io/essreflectometry"
Expand Down Expand Up @@ -82,8 +88,8 @@ ignore = [
# https://docs.astral.sh/ruff/formatter/#conflicting-lint-rules
"COM812", "COM819", "D206", "D300", "E111", "E114", "E117", "ISC001", "ISC002", "Q000", "Q001", "Q002", "Q003", "W191",
]
fixable = ["I001", "B010"]
isort.known-first-party = ["essreflectometry"]
fixable = ["B010", "I001", "PT001"]
isort.known-first-party = ["ess.reflectometry"]
pydocstyle.convention = "numpy"

[tool.ruff.lint.per-file-ignores]
Expand Down Expand Up @@ -114,3 +120,11 @@ enable_error_code = [
"truthy-bool",
]
warn_unreachable = true

[tool.codespell]
ignore-words-list = [
# Codespell wants "socioeconomic" which seems to be the standard spelling.
# But we use the word in our code of conduct which is the contributor covenant.
# Let's not modify it if we don't have to.
"socio-economic",
]
18 changes: 9 additions & 9 deletions requirements/base.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,27 +19,27 @@ cyclebane==24.6.0
# via sciline
cycler==0.12.1
# via matplotlib
dask==2024.8.2
dask==2024.9.0
# via -r base.in
decorator==5.1.1
# via ipython
essreduce==24.9.0
essreduce==24.9.1
# via -r base.in
exceptiongroup==1.2.2
# via ipython
executing==2.1.0
# via stack-data
fonttools==4.53.1
# via matplotlib
fsspec==2024.6.1
fsspec==2024.9.0
# via dask
graphviz==0.20.3
# via -r base.in
h5py==3.11.0
# via
# scippneutron
# scippnexus
importlib-metadata==8.4.0
importlib-metadata==8.5.0
# via dask
ipydatawidgets==4.3.5
# via pythreejs
Expand All @@ -53,7 +53,7 @@ jedi==0.19.1
# via ipython
jupyterlab-widgets==3.0.13
# via ipywidgets
kiwisolver==1.4.6
kiwisolver==1.4.7
# via matplotlib
locket==1.0.0
# via partd
Expand Down Expand Up @@ -92,7 +92,7 @@ pexpect==4.9.0
# via ipython
pillow==10.4.0
# via matplotlib
plopp==24.6.0
plopp==24.9.1
# via
# -r base.in
# scippneutron
Expand Down Expand Up @@ -127,9 +127,9 @@ scipp==24.9.1
# essreduce
# scippneutron
# scippnexus
scippneutron==24.8.0
scippneutron==24.9.0
# via -r base.in
scippnexus==24.8.1
scippnexus==24.9.0
# via
# essreduce
# scippneutron
Expand Down Expand Up @@ -163,5 +163,5 @@ wcwidth==0.2.13
# via prompt-toolkit
widgetsnbextension==4.0.13
# via ipywidgets
zipp==3.20.1
zipp==3.20.2
# via importlib-metadata
6 changes: 6 additions & 0 deletions requirements/basetest.in
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Dependencies that are only used by tests.
# Do not make an environment from this file, use test.txt instead!
# Add more dependencies in the ``test`` list
# under ``[project.optional-dependencies]`` section, in ``pyproject.toml``

# Anything above "--- END OF CUSTOM SECTION ---"
# will not be touched by ``make_base.py``
# --- END OF CUSTOM SECTION ---
# The following was generated by 'tox -e deps', DO NOT EDIT MANUALLY!
pytest
pooch
8 changes: 4 additions & 4 deletions requirements/basetest.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,25 +11,25 @@ charset-normalizer==3.3.2
# via requests
exceptiongroup==1.2.2
# via pytest
idna==3.8
idna==3.10
# via requests
iniconfig==2.0.0
# via pytest
packaging==24.1
# via
# pooch
# pytest
platformdirs==4.2.2
platformdirs==4.3.6
# via pooch
pluggy==1.5.0
# via pytest
pooch==1.8.2
# via -r basetest.in
pytest==8.3.2
pytest==8.3.3
# via -r basetest.in
requests==2.32.3
# via pooch
tomli==2.0.1
# via pytest
urllib3==2.2.2
urllib3==2.2.3
# via requests
14 changes: 7 additions & 7 deletions requirements/ci.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,28 +17,28 @@ colorama==0.4.6
# via tox
distlib==0.3.8
# via virtualenv
filelock==3.15.4
filelock==3.16.1
# via
# tox
# virtualenv
gitdb==4.0.11
# via gitpython
gitpython==3.1.43
# via -r ci.in
idna==3.8
idna==3.10
# via requests
packaging==24.1
# via
# -r ci.in
# pyproject-api
# tox
platformdirs==4.2.2
platformdirs==4.3.6
# via
# tox
# virtualenv
pluggy==1.5.0
# via tox
pyproject-api==1.7.1
pyproject-api==1.7.2
# via tox
requests==2.32.3
# via -r ci.in
Expand All @@ -48,9 +48,9 @@ tomli==2.0.1
# via
# pyproject-api
# tox
tox==4.18.0
tox==4.19.0
# via -r ci.in
urllib3==2.2.2
urllib3==2.2.3
# via requests
virtualenv==20.26.3
virtualenv==20.26.5
# via tox
8 changes: 4 additions & 4 deletions requirements/dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ arrow==1.3.0
# via isoduration
async-lru==2.0.4
# via jupyterlab
cffi==1.17.0
cffi==1.17.1
# via argon2-cffi-bindings
copier==9.3.1
# via -r dev.in
Expand Down Expand Up @@ -87,9 +87,9 @@ prometheus-client==0.20.0
# via jupyter-server
pycparser==2.22
# via cffi
pydantic==2.8.2
pydantic==2.9.2
# via copier
pydantic-core==2.20.1
pydantic-core==2.23.4
# via pydantic
python-json-logger==2.0.7
# via jupyter-events
Expand All @@ -115,7 +115,7 @@ terminado==0.18.1
# jupyter-server-terminals
toposort==1.10
# via pip-compile-multi
types-python-dateutil==2.9.0.20240821
types-python-dateutil==2.9.0.20240906
# via arrow
uri-template==1.3.0
# via jsonschema
Expand Down
Loading

0 comments on commit bdd2950

Please sign in to comment.