Skip to content

Commit 781bfa9

Browse files
authored
Clean up packaging metadata and build config (galsci#257)
* Remove unused importlib_metadata dependency * Install test extras in release instructions * Remove stale Python pandoc package dependency * Keep src layout in source distributions * Remove redundant wheel force-include * Fix README long description markup * Include package data in release artifacts * Ship presets.cfg in source distributions * Fix remaining docs warnings * Remove broken HalfDome docs reference
1 parent 9afa0b2 commit 781bfa9

File tree

5 files changed

+8
-9
lines changed

5 files changed

+8
-9
lines changed

README.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ See the `documentation <https://pysm3.readthedocs.io/en/latest/#installation>`_
3131

3232
* Install with ``pip install .`` or with ``pip install .[test]`` to also install the requirements for running tests
3333
* Optionally, if you have an MPI environment available and you would like to test the MPI capabilities of PySM, install ``mpi4py`` and ``libsharp``, check the documentation link above for more details.
34-
* This repository uses Git LFS for Jupyter notebook files (*.ipynb). Ensure Git LFS is installed and run ``git lfs pull`` after cloning to fetch large files.
34+
* This repository uses Git LFS for Jupyter notebook files (``*.ipynb``). Ensure Git LFS is installed and run ``git lfs pull`` after cloning to fetch large files.
3535
* Check code style with ``uv run flake8 src/pysm3 --count --max-line-length=100``
3636
* Test with ``uv run pytest -v``
3737
* Building docs requires ``pandoc``, not the python package, the actual ``pandoc`` command line tool, install it with conda or your package manager
@@ -54,6 +54,7 @@ Release
5454

5555
uv venv .venv
5656
uv pip install --python .venv/bin/python pip hatch
57+
uv pip install --python .venv/bin/python -e .[test]
5758

5859
Activate it for the remaining steps with ``source .venv/bin/activate``.
5960
4. Run the test suite (at least ``pytest``) to verify the release build.

docs/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,6 +209,7 @@ high-resolution templates shipped with PySM.
209209
Synchrotron curvature modelling <preprocess-templates/synchrotron_curvature>
210210
Log-pol-tens formalism notebook <preprocess-templates/synchrotron_template_logpoltens>
211211
WebSky bright source catalog workflow <preprocess-templates/websky_sources_high_flux_catalog>
212+
Compare WebSky and Agora SZ templates <preprocess-templates/verify_templates/compare_websky_agora_sz>
212213
Verify dust templates <preprocess-templates/verify_templates/verify_templates_dust>
213214
Verify synchrotron templates <preprocess-templates/verify_templates/verify_templates_synch>
214215

docs/models.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ Sunyaev–Zeldovich emission
144144

145145
- **tsz3**: Lensed Thermal SZ emission from the `Agora simulations <https://doi.org/10.1093/mnras/stae1031>`_. Available at $N_{side}=8192$.
146146

147-
- **tsz4**: Thermal SZ emission from the `HalfDome simulations <https://doi.org/10.48550/arXiv.2407.17462>`_ 0.1 (generated using xgpaint with Battaglia16 profiles). Eleven realizations available at $N_{side}=8192$ by overriding the `template_name` with seeds: 100 (default), 102, 104, 106, 108, 110, 112, 114, 116, 118, 120. For example: `halfdome/0.1/tsz/y_b16_halo_res1_s102.fits`. For more details see :ref:`halfdome`.
147+
- **tsz4**: Thermal SZ emission from the `HalfDome simulations <https://doi.org/10.48550/arXiv.2407.17462>`_ 0.1 (generated using xgpaint with Battaglia16 profiles). Eleven realizations available at $N_{side}=8192$ by overriding the `template_name` with seeds: 100 (default), 102, 104, 106, 108, 110, 112, 114, 116, 118, 120. For example: `halfdome/0.1/tsz/y_b16_halo_res1_s102.fits`.
148148

149149
- **ksz1**: Kinetic SZ emission from WebSky 0.4. Available at $N_{side}=4096$. For more details see :ref:`websky`.
150150

docs/requirements.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ numba
44
numpy
55
healpy
66
ipykernel
7-
pandoc
87
sphinx-astropy
98
sphinx-math-dollar
109
nbsphinx

pyproject.toml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ dependencies = [
2929
"h5py",
3030
"scipy >= 1.10, < 1.15",
3131
"healpy >= 1.16.0",
32-
"importlib_metadata;python_version<'3.8'",
3332
"numba",
3433
"numpy >= 1.21",
3534
"toml",
@@ -62,7 +61,6 @@ docs = [
6261
"ipykernel",
6362
"matplotlib",
6463
"nbsphinx",
65-
"pandoc",
6664
"sphinx-pyproject",
6765
"sphinx-astropy",
6866
"sphinx-math-dollar",
@@ -94,12 +92,12 @@ version-file = "src/pysm3/_version.py"
9492

9593
[tool.hatch.build.targets.sdist]
9694
include = [
97-
"/src/pysm3",
98-
]
99-
packages = [
100-
"src/pysm3",
95+
"/src/pysm3/**",
10196
]
10297

98+
[tool.hatch.build.targets.sdist.force-include]
99+
"src/pysm3/data/presets.cfg" = "src/pysm3/data/presets.cfg"
100+
103101
[tool.hatch.build.targets.wheel]
104102
include = [
105103
"/src/pysm3/**",

0 commit comments

Comments
 (0)