Skip to content

Fix/extras single string - #3224

Open
wolfv wants to merge 4 commits into
conda:mainfrom
wolfv:fix/extras-single-string
Open

wolfv wants to merge 4 commits into
conda:mainfrom
wolfv:fix/extras-single-string

Conversation

@wolfv

@wolfv wolfv commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Description

Fixes an inconsistency in extras / flags list parsing. We parsed extras="bla,foo" as a list which I don't like :)

AI-generated details (model name)

Checklist:

  • I've discussed the proposed changes with a maintainer.
  • I understand the purpose of my changes and how they interact with the greater system.
  • User-facing changes are documented and prose in the documentation has been written/edited/reviewed by hand.

CEP 44 allows the extras value to be a string or a list of strings.
A string selects exactly one group, so `foo[extras="a,b"]` is now
rejected as an invalid group name instead of being split into two
groups. Lists must use the `[a, b]` flow-sequence syntax.

Amp-Thread-ID: https://ampcode.com/threads/T-9a983d41-b2a7-4eaa-816a-0b7fed9455a1
In strict mode a string value of `flags` is now one flag, so
`flags="a,b"` is rejected like `extras="a,b"`. Lenient parsing keeps
splitting comma-separated strings for both keys, for compatibility with
existing specs. `track_features` is unchanged because it is written and
stored as a space-separated string.

Amp-Thread-ID: https://ampcode.com/threads/T-9a983d41-b2a7-4eaa-816a-0b7fed9455a1
A string value of `extras` or `flags` is now always a single item,
regardless of parse strictness. Lists must use `[a, b]`.
Instead of special-casing commas, a string `flags` value is now checked
against the flag grammar as one flag, the same way a string `extras`
value is checked as one group name.

Amp-Thread-ID: https://ampcode.com/threads/T-9a983d41-b2a7-4eaa-816a-0b7fed9455a1

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant