diff --git a/conda-recipes/README.md b/conda-recipes/README.md index b36ab71..479dcfd 100644 --- a/conda-recipes/README.md +++ b/conda-recipes/README.md @@ -1,47 +1,33 @@ -# conda-forge recipes +# conda-forge recipe -Draft [conda-forge](https://conda-forge.org/) recipes for distributing -ThermoScreening (and its dependency PQAnalysis) through the `conda-forge` -channel. They are kept here for reference and maintenance; the recipes that -conda-forge actually builds live in per-package *feedstock* repositories created -from [`conda-forge/staged-recipes`](https://github.com/conda-forge/staged-recipes). - -## Why two recipes - -`ThermoScreening` depends on `PQAnalysis`, which is **not yet on conda-forge**. -conda-forge packages may only depend on other conda-forge packages, so -`PQAnalysis` has to land first. Every other dependency (`numpy`, `scipy`, -`pymatgen-core`, `beartype`, `ase`, `rdkit`, and PQAnalysis's own -`multimethod`/`lark`/`tqdm`/`decorator`/`argcomplete`/`rich-argparse`) is -already available on conda-forge. +Draft [conda-forge](https://conda-forge.org/) recipe for distributing +ThermoScreening through the `conda-forge` channel. It is kept here for reference +and maintenance; the recipe conda-forge actually builds lives in the +`thermoscreening` *feedstock* created from +[`conda-forge/staged-recipes`](https://github.com/conda-forge/staged-recipes). | Recipe | noarch? | Notes | |--------|---------|-------| -| `pqanalysis/` | no | Ships a compiled Cython extension, so it builds per platform (needs a C compiler). | | `thermoscreening/` | yes | Pure Python. | -## Submission order +## Dependency: PQAnalysis -1. **PQAnalysis first.** Fork `conda-forge/staged-recipes`, copy - `pqanalysis/` into its `recipes/` directory, and open a PR. Once it is - merged, conda-forge's bot creates `PQAnalysis-feedstock` and publishes the - package (usually within an hour). -2. **ThermoScreening second.** After `pqanalysis` is available on the - `conda-forge` channel, submit `thermoscreening/` the same way. Its - `pqanalysis >=1.3.0` run requirement will then resolve. +`ThermoScreening` depends on `PQAnalysis`, which must be on conda-forge first +(conda-forge packages may only depend on other conda-forge packages). Its recipe +lives in the [PQAnalysis repository](https://github.com/MolarVerse/PQAnalysis) +(`conda-recipes/pqanalysis/`). Every other dependency (`numpy`, `scipy`, +`pymatgen-core`, `beartype`, `ase`, `rdkit`) is already on conda-forge. -staged-recipes can build sibling recipes in dependency order within a single -PR, so submitting both at once can work — but the two-step order above is the -simpler, lower-risk path and lets `pqanalysis` publish before `thermoscreening` -is reviewed. +Both recipes were submitted together to `staged-recipes`, which builds sibling +recipes in dependency order (`pqanalysis` first, then `thermoscreening`). ## Before submitting - **Maintainer(s):** `extra.recipe-maintainers` lists `galjos`. Add any other - GitHub usernames who should co-maintain the feedstocks. -- **Versions & hashes** are pinned to the current PyPI releases - (PQAnalysis 1.3.0, ThermoScreening 0.1.0). To refresh for a new release, - bump `version` and replace `sha256` with the sdist hash: + GitHub usernames who should co-maintain the feedstock. +- **Versions & hashes** are pinned to the current PyPI release + (ThermoScreening 0.1.0). To refresh for a new release, bump `version` and + replace `sha256` with the sdist hash: ```bash # prints the sha256 of the PyPI source tarball @@ -50,17 +36,17 @@ is reviewed. print(next(u['digests']['sha256'] for u in d['urls'] if u['packagetype']=='sdist'))" ``` - After the feedstocks exist, conda-forge's `regro-cf-autotick-bot` opens + After the feedstock exists, conda-forge's `regro-cf-autotick-bot` opens version-bump PRs automatically, so this is mainly needed for the initial submission. ## Local check (optional) -If you have `conda-build` installed you can lint/build a recipe before +If you have `conda-build` installed you can lint/build the recipe before submitting: ```bash -conda build conda-recipes/pqanalysis +conda smithy recipe-lint conda-recipes/thermoscreening conda build conda-recipes/thermoscreening -c conda-forge ``` diff --git a/conda-recipes/pqanalysis/bld.bat b/conda-recipes/pqanalysis/bld.bat deleted file mode 100644 index 9b9242d..0000000 --- a/conda-recipes/pqanalysis/bld.bat +++ /dev/null @@ -1,4 +0,0 @@ -set SETUPTOOLS_SCM_PRETEND_VERSION=%PKG_VERSION% - -%PYTHON% -m pip install . -vv --no-deps --no-build-isolation -if errorlevel 1 exit 1 diff --git a/conda-recipes/pqanalysis/build.sh b/conda-recipes/pqanalysis/build.sh deleted file mode 100755 index f1b4b3b..0000000 --- a/conda-recipes/pqanalysis/build.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash -set -euxo pipefail - -# The PyPI sdist has no .git, so tell setuptools_scm the version explicitly. -export SETUPTOOLS_SCM_PRETEND_VERSION="${PKG_VERSION}" - -$PYTHON -m pip install . -vv --no-deps --no-build-isolation diff --git a/conda-recipes/pqanalysis/meta.yaml b/conda-recipes/pqanalysis/meta.yaml deleted file mode 100644 index 07b7aee..0000000 --- a/conda-recipes/pqanalysis/meta.yaml +++ /dev/null @@ -1,82 +0,0 @@ -{% set name = "PQAnalysis" %} -{% set version = "1.3.0" %} - -package: - name: {{ name|lower }} - version: {{ version }} - -source: - url: https://pypi.org/packages/source/{{ name[0]|lower }}/{{ name|lower }}/{{ name|lower }}-{{ version }}.tar.gz - sha256: 6b7ecd3aeb553c8c8cdc12805f991145e956690d73a7eddd4f71481c519ddc3e - -build: - number: 0 - # Not noarch: PQAnalysis ships a compiled Cython extension - # (PQAnalysis/io/traj_file/*.pyx), so it is built per platform. pip enforces - # Requires-Python >=3.12, so skip the older interpreters in the build matrix. - skip: true # [py<312] - entry_points: - - pqanalysis = PQAnalysis.cli.main:main - - traj2box = PQAnalysis.cli.traj2box:main - - traj2extxyz = PQAnalysis.cli.traj2extxyz:main - - traj2qmcfc = PQAnalysis.cli.traj2qmcfc:main - - rst2xyz = PQAnalysis.cli.rst2xyz:main - - xyz2rst = PQAnalysis.cli.xyz2rst:main - - continue_input = PQAnalysis.cli.continue_input:main - - rdf = PQAnalysis.cli.rdf:main - - add_molecules = PQAnalysis.cli.add_molecules:main - - activate_argcomplete = PQAnalysis.cli.activate_argcomplete:main - - build_nep_traj = PQAnalysis.cli.build_nep_traj:main - - xyz2gen = PQAnalysis.cli.xyz2gen:main - - gen2xyz = PQAnalysis.cli.gen2xyz:main - -requirements: - build: - - {{ compiler('c') }} - - {{ stdlib('c') }} - host: - - python - - pip - - setuptools >=70 - - setuptools_scm >=8 - - wheel - - cython >=3 - - numpy - run: - - python - - numpy - - scipy - - beartype - - multimethod - - lark - - tqdm - - decorator - - argcomplete - - rich-argparse - -test: - imports: - - PQAnalysis - - PQAnalysis.io - # the compiled Cython extension; import fails if the C build is broken - - PQAnalysis.io.traj_file.process_lines - commands: - - pip check - - pqanalysis --help - requires: - - pip - -about: - home: https://github.com/MolarVerse/PQAnalysis - license: MIT - license_file: LICENSE - summary: A Python package for the post-processing and analysis of molecular dynamics simulations. - description: | - PQAnalysis reads, writes, and analyses molecular dynamics trajectories and - related data (coordinates, restart files, cells), with command-line tools - for common trajectory conversions. - dev_url: https://github.com/MolarVerse/PQAnalysis - -extra: - recipe-maintainers: - - galjos