Skip to content

feat: add the pixi_conda_script crate with the block parser and TOML model - #6907

Draft
Hofer-Julian wants to merge 1 commit into
mainfrom
conda-script-parser
Draft

feat: add the pixi_conda_script crate with the block parser and TOML model#6907
Hofer-Julian wants to merge 1 commit into
mainfrom
conda-script-parser

Conversation

@Hofer-Julian

@Hofer-Julian Hofer-Julian commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

First slice of the conda-script proposal (#3751): a new pixi_conda_script crate that parses the /// conda-script comment block.

  • Envelope parser: detects the comment prefix from the opening line, strips it from every block line and maps all diagnostics back into the original file
  • TOML model: channels, entrypoint (string or platform table), [dependencies] restricted to the keys the spec defines, [tool.pixi] with dependencies and pypi-dependencies
  • Errors for unterminated blocks, multiple blocks and files mixing a PEP 723 block with a conda-script block

Considerations before merging

  • The spec allows url combined with when for cross-platform URL pinning, but pixi cannot attach conditions to URL specs yet, so the parser rejects the combination with a "not supported yet" error instead

@Hofer-Julian Hofer-Julian changed the title conda script parser feat: add the pixi_conda_script crate with the block parser and TOML model Aug 27, 2026
…L model

The first piece of the `conda-script` proposal (#3751): a parser for the
`/// conda-script` comment block. The envelope parser detects the comment
prefix, extracts the TOML and maps diagnostics back into the original file;
the model covers `channels`, `entrypoint` (string or platform table),
`[dependencies]` restricted to the keys the spec defines, and `[tool.pixi]`
with `dependencies` and `pypi-dependencies`.
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