Skip to content

Add pixi-pack support to poncho_package_run - #4557

Open
saifulislampi wants to merge 1 commit into
cooperative-computing-lab:masterfrom
saifulislampi:pixi-run-support-in-poncho
Open

saifulislampi wants to merge 1 commit into
cooperative-computing-lab:masterfrom
saifulislampi:pixi-run-support-in-poncho

Conversation

@saifulislampi

Copy link
Copy Markdown
Contributor

Summary

Add initial pixi-pack support to poncho_package_run while preserving the
existing conda-pack behavior.

For a Pixi archive, the runner:

  1. detects the root-level pixi-pack.json;
  2. locates a staged pixi-unpack executable;
  3. unpacks and activates the environment; and
  4. starts the requested command inside it.

pixi-unpack is transferred using the existing factory option:

vine_factory \
  --poncho-env environment.tar \
  --wrapper-input /path/to/pixi-unpack

Test scenario

Import an environment.yml, create the Pixi environment, and pack it:

pixi init pixi-workspace --import environment.yml
pixi install --manifest-path pixi-workspace/pixi.toml
pixi-pack --platform linux-64 pixi-workspace/pixi.toml

Then start the factory:

vine_factory -T local \
  --manager-name "$MANAGER_NAME" \
  --min-workers 1 \
  --max-workers 2 \
  --cores 1 \
  --poncho-env "$PWD/environment.tar" \
  --wrapper-input "/path/to/pixi-unpack"

Current limitation

pixi-unpack must currently be supplied explicitly with --wrapper-input.
Factory-side automatic staging can be added separately.

@saifulislampi
saifulislampi requested review from btovar and removed request for btovar October 30, 2026 18:40
if ! PIXI_UNPACK=$(find_pixi_unpack)
then
errmsg "pixi-pack archive detected, but pixi-unpack was not found."
errmsg "Stage pixi-unpack beside poncho_package_run or set PONCHO_PIXI_UNPACK."

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that if pixi-unpack is not inside the expanded directory, then it is not a valid poncho package in pixi format? The only things you should need for poncho are tar + decompress tool + poncho_package_run + tarball?


# force no args to activate, as it wants to consume "$@" which contains the command line
source "${UNPACK_TO}/bin/activate" ""
if [[ "${PACKAGE_FORMAT}" = pixi-pack ]]

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

poncho packages are not conda packages. They are constructed with some other support with environment variables, etc. This pr wants to support pixi-pack environments directly?

I rather have poncho_package_create modified to get an argument --format conda or pixi and modify poncho_package_run as little as possible.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💯 Poncho packages should be opaque, self-contained objects that require only poncho_package_run to deploy.

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