Skip to content

refactor: use shared config types from rattler_config#6528

Merged
Hofer-Julian merged 1 commit into
mainfrom
claude/rattler-shared-config-design-m8d2gb
Jul 6, 2026
Merged

refactor: use shared config types from rattler_config#6528
Hofer-Julian merged 1 commit into
mainfrom
claude/rattler-shared-config-design-m8d2gb

Conversation

@wolfv

@wolfv wolfv commented Jul 5, 2026

Copy link
Copy Markdown
Member

Description

Continuation of #6144 ("refactor: switch to rattler_config") on a branch in this repo — the original branch lives in a fork that couldn't be pushed to. The diff of #6144 applied cleanly onto main; no functional deviations.

pixi_config consumes the shared leaf types from the rattler_config crate (0.5, crates.io) instead of maintaining its own copies: RepodataConfig/RepodataChannelConfig (including the tolerant deserializer that keeps deprecated keys like disable-jlap as warnings), S3Options + the new S3OptionsMap newtype, ConcurrencyConfig, ProxyConfig, BuildConfig/PackageFormatAndCompression, and RunPostLinkScripts. All types are re-exported from pixi_config so external paths keep compiling.

Note (post-merge): this PR was merged at the leaf-type-migration commit. The follow-up work — the full Config = ConfigBase<PixiConfig> conversion and the compatibility test catalog — was pushed to the branch minutes after the merge and therefore continues in #6531.

How Has This Been Tested?

  • cargo check --workspace --all-targets passes.
  • cargo test -p pixi_config: 53 passed, 0 failed.
  • cargo fmt --check and cargo clippy -p pixi_config -p pixi_api --all-targets clean.

AI Disclosure

  • This PR contains AI-generated content.
    • I have tested any AI-generated content in my PR.
    • I take responsibility for any AI-generated content in my PR.

Tools: Claude Code

Checklist:

  • I have performed a self-review of my own code
  • I have added sufficient tests to cover my changes.
  • I have verified that changes that would impact the JSON schema have been made in schema/model.py (no schema impact)

Ports #6144 onto current main. pixi_config now reuses
the leaf config types from the rattler_config crate (0.5) instead of
maintaining its own copies, re-exporting them for back-compat:

- RepodataConfig / RepodataChannelConfig (incl. the tolerant
  Deserialize impl for unknown/deprecated keys like disable-jlap)
- S3Options / S3OptionsMap (IndexMap-backed newtype; Config.s3_options
  switches from HashMap<String, S3Options> to S3OptionsMap)
- ConcurrencyConfig and its default helpers
- ProxyConfig (rattler's Default reads HTTP(S)_PROXY/NO_PROXY env vars;
  pixi's local env statics are kept for get_proxies())
- BuildConfig / PackageFormatAndCompression
- RunPostLinkScripts

The former From<RepodataChannelConfig> for SourceConfig impl becomes a
free function (orphan rule), and merging goes through the
rattler_config::config::Config trait's merge_config. pixi_api's init
templates adapt to S3OptionsMap. The config_merge_multiple insta
snapshot is updated for the S3OptionsMap wrapper.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EzYs4p6XJDj9QBcNB4ipR7
@Hofer-Julian Hofer-Julian merged commit a90bc4c into main Jul 6, 2026
35 checks passed
@Hofer-Julian Hofer-Julian deleted the claude/rattler-shared-config-design-m8d2gb branch July 6, 2026 08:04
@wolfv wolfv changed the title refactor: use shared config types from rattler_config refactor!: back pixi's Config by rattler_config's ConfigBase&lt;PixiConfig&gt; Jul 6, 2026
@wolfv wolfv changed the title refactor!: back pixi's Config by rattler_config's ConfigBase&lt;PixiConfig&gt; refactor: use shared config types from rattler_config Jul 6, 2026
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.

3 participants