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

system-requirements can't be target specific. #2714

Open
2 tasks done
ruben-arts opened this issue Dec 16, 2024 · 0 comments
Open
2 tasks done

system-requirements can't be target specific. #2714

ruben-arts opened this issue Dec 16, 2024 · 0 comments
Labels
🗒️ configuration Issue related to configuration of project or global behavior

Comments

@ruben-arts
Copy link
Contributor

ruben-arts commented Dec 16, 2024

Checks

  • I have checked that this issue has not already been reported.

  • I have confirmed this bug exists on the latest version of pixi, using pixi --version.

Reproducible example

[project]
name = "test"
channels = []
platforms = ["osx-arm64", "linux-64"]

[target.linux-64.system-requirements]
cuda = "12.0"

Results in:

  × unknown field `system-requirements`, expected one of `dependencies`, `host-dependencies`, `build-dependencies`, `run-dependencies`, `pypi-
  │ dependencies`, `activation`, `tasks`
   ╭─[pixi.toml:8:28]
 7 │
 8 │ [target.linux-64.system-requirements]
   ·                  ───────────────────
 9 │ cuda = "12.0"
   ╰────

Issue description

This is not implemented correctly, as it should have system requirements here:

pub struct WorkspaceTarget {
/// Dependencies for this target.
///
/// TODO: While the pixi-build feature is not stabilized yet, a workspace
/// can have host- and build dependencies. When pixi-build is stabilized, we
/// can simplify this part of the code.
pub dependencies: HashMap<SpecType, IndexMap<PackageName, PixiSpec>>,
/// Specific python dependencies
pub pypi_dependencies: Option<IndexMap<PyPiPackageName, PyPiRequirement>>,
/// Additional information to activate an environment.
pub activation: Option<Activation>,
/// Target specific tasks to run in the environment
pub tasks: HashMap<TaskName, Task>,
}

Expected behavior

Being able to set system requirements per target.

@ruben-arts ruben-arts added the 🗒️ configuration Issue related to configuration of project or global behavior label Dec 16, 2024
@ruben-arts ruben-arts changed the title system-requirements can't be target specific. system-requirements can't be target specific. Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🗒️ configuration Issue related to configuration of project or global behavior
Projects
None yet
Development

No branches or pull requests

1 participant