spyder-ide / spyder

Official repository for Spyder - The Scientific Python Development Environment
https://www.spyder-ide.org
MIT License
8.25k stars 1.6k forks source link

Build string in conda package url for Spyder in the conda-lock file release asset does not match conda-forge #22201

Closed mrclary closed 2 months ago

mrclary commented 3 months ago

The installer workflow generates a conda-lock file for updating installer-based Spyder versions. The explicit url specification in the file has the form:

https://conda.anaconda.org/conda-forge/<platform>/spyder-<version>-<build-string>.conda

There are two issues with the url in the conda-lock file.

  1. For non-stable releases (e.g. 6.0.0b2) label/spyder_dev/ is missing from the url.
  2. The <build-string> portion does not match that of the package on conda-forge. This is because the <build-string> contains a hash that is automatically generated by conda-build based on the contents of meta.yaml in the recipe, and this file will differ slightly between our CI and conda-forge.

@spyder-ide/core-developers, we should discuss possible solutions.

ccordoba12 commented 3 months ago

And what could be a possible solution? I'm sorry but I don't understand how to address this problem.

mrclary commented 3 months ago

The first issue, regarding the dev channel, is straight-forward and can be accommodated when we patch the conda-lock file.

I thought that the second issue would be more problematic. In order to have the same build string in the conda-lock file and on conda-forge I thought there were only 2 options: 1) explicitly set the build string; or 2) build the conda package from an un-patched meta.yaml file.

However, I have discovered that I'm wrong about how the hash info is compiled. The difference between our CI build string and the conda-forge build string results from conda-forge having an additional conda_build_config.yaml which is absent from our CI. conda-build searches several locations for this configuration file and merges all files discovered, so the configuration consists of more that just what is in our feedstock recipe.

I have narrowed down the relevant configuration spec to

python:
  - <major>.<minor>.* *_cython

This can be patched in the conda_build_config.yaml file in our feedstock when we build on CI.

ccordoba12 commented 3 months ago

Ok, that's really good 👍🏽