Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update conda recipe to be more like conda-forge feedstock #661

Merged
merged 1 commit into from
Jan 17, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions conda/meta.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{% set name = "zppy" %}
{% set version = "3.0.0rc1" %}
{% set python_min = "3.9" %}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs to be defined here but is set automatically as part of the infrastructure on conda-forge feedstocks.


package:
name: {{ name|lower }}
Expand All @@ -11,24 +12,24 @@ source:

build:
number: 0
script: "{{ PYTHON }} -m pip install . --no-deps -vv"
script: {{ PYTHON }} -m pip install . --no-deps --no-build-isolation -vv
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is best to not allow pip to install missing build dependencies from PyPI (which is what --no-build-isolation does).

The quotes are not needed.

noarch: python
entry_points:
- zppy = zppy.__main__:main
Comment on lines -16 to -17
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Entry points no longer need to be defined in conda recipes and removing them removes one more maintenance step we would otherwise have to do.


requirements:
host:
- python >=3.9
- python {{ python_min }}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here and below, conda-forge has moved to defining python_min (3.9 by default) and ensuring that the package bets built and tested with this minimum version. The idea is that thing tend to break more often when we only test with the newest python than when we only test with the oldest. See https://github.com/conda-forge/cfep/blob/main/cfep-25.md for details.

- pip
- setuptools
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

zppy gets installed with setuptools so this is a necessary dependency. It used to get bundled with pip but that is no longer the case.

run:
- python >=3.9
- python >={{ python_min }}
- configobj >=5.0.0,<6.0.0
- jinja2 >=2.0.0
- mache >=1.3.2
- mpas_tools >=0.15.0

test:
requires:
- python {{ python_min }}
- pip
imports:
- zppy
Expand Down
Loading