Skip to content

Commit 763c1ff

Browse files
committed
fix(deps): generate conda recipe dependencies from pyproject.toml
1 parent dd0baae commit 763c1ff

1 file changed

Lines changed: 16 additions & 16 deletions

File tree

‎conda-recipe/meta.yaml‎

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
11
{% set name = "codeentropy" %}
22
{% set version = "0.0.0" %}
3+
{% set pyproject = load_file_data("../pyproject.toml", from_recipe_dir=True) %}
4+
{% set pip_only = namespace(water_entropy="") %}
5+
{% for dependency in pyproject["project"]["dependencies"] %}
6+
{% if dependency.startswith("waterEntropy") %}
7+
{% set pip_only.water_entropy = dependency %}
8+
{% endif %}
9+
{% endfor %}
310

411
package:
512
name: {{ name }}
@@ -12,7 +19,7 @@ build:
1219
noarch: python
1320
script: |
1421
python -m pip install . -vv --no-deps
15-
PIP_NO_INDEX=0 python -m pip install -vv --index-url https://pypi.org/simple "waterEntropy>=2,<3.0"
22+
PIP_NO_INDEX=0 python -m pip install -vv --index-url https://pypi.org/simple "{{ pip_only.water_entropy }}"
1623
entry_points:
1724
- CodeEntropy=CodeEntropy.cli:main
1825

@@ -22,21 +29,14 @@ requirements:
2229
- pip
2330
- flit-core >=4,<5
2431
run:
25-
- python >=3.12
26-
- numpy >=2.3.2,<2.6.0
27-
- mdanalysis >=2.10,<3.0
28-
- pandas >=2.3.3,<4.0
29-
- psutil >=5.9.4,<8.0
30-
- pyyaml >=6.0.3,<7.0
31-
- rich >=13.0.0,<16.0
32-
- python-art >=5.0,<7.0
33-
- networkx >=2.8,<4.0
34-
- requests >=2.32.2,<3.0
35-
- rdkit >=2025.3.4,<2027
36-
- dask >=2025.4.0,<2027.1.0
37-
- distributed >=2025.4.0,<2027.1.0
38-
- dask-jobqueue >=0.9.0,<1.0
39-
- numba >=0.63.0,<0.70
32+
- python {{ pyproject["project"]["requires-python"] }}
33+
{% for dependency in pyproject["project"]["dependencies"] %}
34+
{% if dependency.startswith("art>") %}
35+
- python-{{ dependency }}
36+
{% elif not dependency.startswith("waterEntropy") %}
37+
- {{ dependency | lower }}
38+
{% endif %}
39+
{% endfor %}
4040

4141
test:
4242
imports:

0 commit comments

Comments
 (0)