Skip to content

Conversation

kenodegard
Copy link
Contributor

@kenodegard kenodegard commented Sep 20, 2024

Description

While tinkering with #5495 I noticed a few local imports to avoid circular imports between conda_build.metadata and conda_build.variants. This is an artifact of how selectors evolved where originally they were purely a meta.yaml feature (hence why it was defined within conda_build.metadata) and over time were introduced for the conda_build_config.yaml file.

To better reflect the agnostic nature of selectors I propose moving the related logic into a new submodule:

old path new path
conda_build.metadata.ARCH_MAP conda_build.utils.ARCH_MAP
conda_build.metadata.get_selectors conda_build.selectors.get_selectors
conda_build.metadata.ns_cfg conda_build.selectors.get_selectors
conda_build.metadata.sel_pat conda_build.selectors.RE_SELECTOR
conda_build.metadata.parseNameNotFound conda_build.selectors.parse_NameError
conda_build.metadata.eval_selector conda_build.selectors.eval_selector
conda_build.metadata._split_line_selector conda_build.selectors._split_line_selector
conda_build.metadata.select_lines conda_build.selectors.select_lines

Checklist - did you ...

  • Add a file to the news directory (using the template) for the next release's release notes?
  • Add / update necessary tests?
  • Add / update outdated documentation?

@conda-bot conda-bot added the cla-signed [bot] added once the contributor has signed the CLA label Sep 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed [bot] added once the contributor has signed the CLA

Projects

Status: 🏗️ In Progress

Development

Successfully merging this pull request may close these issues.

3 participants