-
Notifications
You must be signed in to change notification settings - Fork 76
Expand file tree
/
Copy pathpixi.toml
More file actions
104 lines (94 loc) · 3.93 KB
/
Copy pathpixi.toml
File metadata and controls
104 lines (94 loc) · 3.93 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
# Pixi development environment for mplhep
#
# We use a standalone pixi.toml instead of embedding in pyproject.toml because
# pixi doesn't properly evaluate PEP 508 environment markers in dependencies.
# The pyproject.toml has markers like `python_version < '3.10'` which pixi
# tries to satisfy simultaneously, causing resolution failures.
#
# Tracking issues:
# https://github.com/prefix-dev/pixi/issues/1259
# https://github.com/prefix-dev/pixi/issues/3724
#
# Usage:
# pixi install && pixi run test
[workspace]
name = "mplhep"
channels = ["conda-forge"]
platforms = ["linux-64"]
[dependencies]
python = ">=3.10"
# Core dependencies from conda (avoids pyproject.toml marker conflicts)
# Note: matplotlib is installed via pip (see pypi-dependencies) to get freetype 2.6.1
# embedded in PyPI wheels, matching nox environment and avoiding pytest-mpl baseline mismatches
numpy = ">=1.16"
packaging = "*"
pyparsing = "<3.3.0" # Avoid oneOf deprecation warning with matplotlib
uhi = ">=0.2"
pip = "*"
# Test dependencies (only packages that don't depend on matplotlib)
# hist, seaborn, pytest-mpl are installed via pip to avoid conda's matplotlib-base
pytest = ">=6.0"
pytest-xdist = "*"
pytest-benchmark = "*"
pytest-mock = "*"
boost-histogram = "*"
scipy = ">=1.1"
uproot = ">=5.0"
scikit-hep-testdata = "*"
# Dev dependencies
jupyter = "*"
pre-commit = "*"
questionary = "*"
# PDF to PNG conversion for pytest-mpl
ghostscript = "*"
# Note: ROOT testing is done via the 'root' feature (pixi run root-test)
# ROOT requires newer freetype which conflicts with matching PyPI wheel rendering
# The single ROOT test (test_make_plottable_histogram_from_root_hist) uses pytest.importorskip
# Note: LaTeX tests require system texlive installation (texlive-core on conda-forge is broken)
[pypi-dependencies]
# Install matplotlib and dependents via pip to get freetype 2.6.1 (embedded in PyPI wheels)
# This ensures pytest-mpl baseline images match CI (which uses uv/pip)
# Must match the pyproject.toml floor (>=3.11.1): label.py's
# _descent_from_layout relies on the mpl>=3.11 Text._get_layout return
# format, and postinstall's `pip install --no-deps` skips dependency checks.
matplotlib = ">=3.11.1"
pytest-mpl = "*"
hist = "*"
seaborn = "*"
mplhep-data = ">=0.0.4"
prek = "*"
[activation]
scripts = [".pixi/install-hooks.sh"]
[tasks]
postinstall = "pip install --no-deps -e ."
test = { cmd = "python -m pytest -r sa --mpl --mpl-results-path=pytest_results -n auto", depends-on = ["postinstall"] }
test-serial = { cmd = "python -m pytest -r sa --mpl --mpl-results-path=pytest_results", depends-on = ["postinstall"] }
test-benchmark = "python -m pytest --benchmark-only --benchmark-sort=mean --benchmark-warmup=on"
test-baseline = "python -m pytest -r sa --mpl -n auto --mpl-generate-path=tests/baseline"
precommit = "prek run --all-files"
prek = "prek run --all-files"
# ROOT feature for testing ROOT histogram support
[feature.root.dependencies]
root = "*"
[feature.root.tasks]
root-test = { cmd = "python -m pytest tests/test_make_plottable_histogram.py::test_make_plottable_histogram_from_root_hist -v", depends-on = ["postinstall"] }
# Docs feature for building documentation with mkdocs
[feature.docs.pypi-dependencies]
mkdocs-material = { version = ">=9.0", extras = ["imaging"] }
mkdocstrings = { version = ">=0.20", extras = ["python"] }
mike = "*"
mkdocs-minify-plugin = "*"
mkdocs-git-revision-date-localized-plugin = "*"
mkdocs-git-committers-plugin-2 = "*"
markdown-exec = "*"
docstring-inheritance = "*"
griffe-inherited-docstrings = "*"
neoteroi-mkdocs = "*"
mkdocs-matplotlib = { git = "https://github.com/andrzejnovak/mkdocs-matplotlib.git", rev = "e3d9ce14a6f0a1fea9550323439b7db93f220b38" }
[feature.docs.tasks]
docs-postinstall = "pip install --no-deps -e ."
docs = { cmd = "mkdocs serve -f new_docs/mkdocs.yml", depends-on = ["docs-postinstall"] }
docs-build = { cmd = "mkdocs build -f new_docs/mkdocs.yml", depends-on = ["docs-postinstall"] }
[environments]
root = ["root"]
docs = ["docs"]