scipp / copier_template

Copier template for Scipp projects
BSD 3-Clause "New" or "Revised" License
2 stars 1 forks source link

Improve conda dependency generation from pyproject.toml? #189

Closed SimonHeybrock closed 3 months ago

SimonHeybrock commented 3 months ago

A pyproject.toml like this:

dependencies = [
  "abcde >= 24.06.0",
]

currently leads to a failing conda-build. Apparently conda does not like the spaces around >=.

Can/should https://github.com/scipp/cyclebane/blob/3b67e2d2c0fb8b03d3ce0f4306b86d33fde20efd/conda/meta.yaml#L10-L11 be adapted to remove spaces? Or should we just "remember" to not use spaces in pyproject.toml?

jokasimr commented 3 months ago

Is this fixed with https://github.com/scipp/essreduce/pull/40 merged? What's left to do? Should this be closed?

SimonHeybrock commented 3 months ago

Not fixed (in the template). What is left to do is think about the last paragraph in the issue description. Note that I have so far seen 2 project where we have had this problem.

jl-wynen commented 3 months ago

Neither package names nor version numbers are allowed to contain spaces. So it is safe, as far as I can tell, to remove all spaces.

It should be possible to replace spaces by using replace in https://github.com/scipp/cyclebane/blob/3b67e2d2c0fb8b03d3ce0f4306b86d33fde20efd/conda/meta.yaml#L22.