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

Selector evaluation failures #2247

Open
1 task done
maresb opened this issue Feb 25, 2025 · 0 comments
Open
1 task done

Selector evaluation failures #2247

maresb opened this issue Feb 25, 2025 · 0 comments
Labels

Comments

@maresb
Copy link
Contributor

maresb commented Feb 25, 2025

Solution to issue cannot be found in the documentation.

  • I checked the documentation.

Issue

I can reproduce this both locally and in CI.

I'm working on the pytensor recipe at conda-forge/pytensor-suite-feedstock#139 (comment). It's a recipe with two outputs. I'm using the same skip selector in both outputs:

skip: true # [py<310 or (osx and (not arm64) and py==311)]

It seems to have no effect. In particular, Intel OSX for Python 3.11 still gets built. Removing the selectors entirely and rerendering does not change the result.

I tried moving the skip selectors for the individual outputs to the top level in conda-forge/pytensor-suite-feedstock#140, and that led to a recursion error. The periodic stack trace is:

  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/environ.py", line 371, in get_dict
    d.update(meta_vars(m, skip_build_id=skip_build_id))
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/environ.py", line 597, in meta_vars
    d["PKG_BUILD_STRING"] = meta.build_id()
                            ^^^^^^^^^^^^^^^
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/metadata.py", line 1756, in build_id
    hash_ = self.hash_dependencies()
            ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/metadata.py", line 1730, in hash_dependencies
    hashing_dependencies = self.get_hash_contents()
                           ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/metadata.py", line 1677, in get_hash_contents
    dependencies = set(self.get_used_vars())
                       ^^^^^^^^^^^^^^^^^^^^
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/metadata.py", line 2821, in get_used_vars
    script_reqs = self._get_used_vars_output_script()
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/metadata.py", line 2940, in _get_used_vars_output_script
    self.get_rendered_output(self.name(), permit_undefined_jinja=True) or {}
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/metadata.py", line 2773, in get_rendered_output
    for output_ in self.get_rendered_outputs_section(
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/metadata.py", line 2755, in get_rendered_outputs_section
    self._get_contents(
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/metadata.py", line 1995, in _get_contents
    env.globals.update(get_dict(m=self, skip_build_id=skip_build_id))
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mares/micromamba/envs/forge/lib/python3.11/site-packages/conda_build/environ.py", line 371, in get_dict
    d.update(meta_vars(m, skip_build_id=skip_build_id))
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...

and the periodic key lookups are:

cache_key: ('name', 'python')
cache_key: ('version', '3.12.*')
cache_key: ('build', '*_cpython')
cache_key: ('name', 'setuptools')
cache_key: ('version', '>=59.0.0')
cache_key: ('name', 'cython')
cache_key: ('name', 'numpy')
cache_key: ('version', '2.0.*')
cache_key: ('name', 'versioneer')
cache_key: ('version', '0.29')
cache_key: ('name', 'pip')
cache_key: ('name', 'tomli')
cache_key: ('name', 'python')
...

Installed packages

x

Environment info

x
@maresb maresb added the bug label Feb 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant