Skip to content

Conversation

@plexoos
Copy link

@plexoos plexoos commented Oct 9, 2025

Related to #23

@veprbl
Copy link
Member

veprbl commented Oct 16, 2025

We need to update tokens, it seems. I took liberty to submit to https://eicweb.phy.anl.gov/containers/eic_container/-/merge_requests/1270 for now.

@wdconinc
Copy link
Contributor

This is not necessary. Directories are valid environments. Creating a named environment will place it in a different directory than intended.

@wdconinc
Copy link
Contributor

See https://spack.readthedocs.io/en/latest/environments.html#independent-environments in contrast with https://spack.readthedocs.io/en/latest/environments.html#creating-a-managed-environment

Adding a managed environment with the name $ENV will create it, but it will still be the anonymous environment that is filled and installed in the container.

@plexoos
Copy link
Author

plexoos commented Nov 6, 2025

Looks like updating the Spack packages repo isn’t possible unless you’re working inside a named environment (see #29).

Copilot AI review requested due to automatic review settings December 12, 2025 20:33
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This pull request attempts to fix an issue by adding spack env create ${ENV} before activating the spack environment. However, this change introduces a bug rather than fixing one. The added line creates a new named environment in spack's default location, but the subsequent line activates a directory-based environment at a different path. These are two distinct environments, and the change creates confusion between named and directory-based spack environment activation patterns.

Key Changes

  • Adds spack env create ${ENV} before the existing spack env activate --without-view --dir ${SPACK_ENV} command in the builder_concretization_default stage

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

# Concretization (default environment)
RUN <<EOF
set -e
spack env create ${ENV}
Copy link

Copilot AI Dec 12, 2025

Choose a reason for hiding this comment

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

This line creates a new named environment "xl" in spack's default location, but the next line activates a directory-based environment at ${SPACK_ENV} (/opt/spack-environment/xl). These are two different environments. The directory already contains a spack.yaml file (copied at line 44), so it can be activated directly without creating a new environment. Other similar usages in this file (lines 178, 283, 322) activate the directory environment without calling 'spack env create' first. This line should be removed.

Suggested change
spack env create ${ENV}

Copilot uses AI. Check for mistakes.
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