Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 15 additions & 3 deletions .github/actions/cubit_setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ inputs:
required: false
default: "60"
outputs:
cubit_root:
cubitpy_config_file:
description: "Path to the Cubit installation"
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

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

The description is incorrect. This output now contains the path to the cubit config file (cubit_config.yaml), not the path to the Cubit installation. The description should be updated to reflect this change.

Suggested change
description: "Path to the Cubit installation"
description: "Path to the Cubit config file (cubit_config.yaml)"

Copilot uses AI. Check for mistakes.
value: ${{ steps.cubit-setup.outputs.cubit_root }}
value: ${{ steps.cubit-setup.outputs.cubitpy_config_file }}
runs:
using: composite
steps:
Expand All @@ -46,7 +46,7 @@ runs:
# Save cubit root path for following steps
CUBIT_FOLDER=$(find . -maxdepth 1 -type d -name "Coreform-Cubit-*" | head -n 1 | sed 's|^\./||')
CUBIT_ROOT="$(pwd)/$CUBIT_FOLDER"
echo "cubit_root=$CUBIT_ROOT" >> "$GITHUB_OUTPUT"
echo "cubit_root=$CUBIT_ROOT" >> "$GITHUB_ENV"
# Activate cubit. Retry login until success or timeout.
timeout="${{ inputs.cubit_activation_timeout }}"
delay="${{ inputs.cubit_activation_delay_between_retries }}"
Expand All @@ -65,3 +65,15 @@ runs:
sleep $delay
done
echo "Cubit activation succeeded."

- name: Create cubit config file
shell: bash
run: |
CUBITPY_CONFIG_FILE="$GITHUB_WORKSPACE/cubit_config.yaml"
echo "cubitpy_config_file=$CUBITPY_CONFIG_FILE" >> "$GITHUB_OUTPUT"

: > $CUBITPY_CONFIG_FILE # truncate / create file

printf "cubitpy_mode: local\n" >> $CUBITPY_CONFIG_FILE
printf "local_config:\n" >> $CUBITPY_CONFIG_FILE
printf " cubit_path: \"%s\"\n" "$CUBIT_ROOT" >> $CUBITPY_CONFIG_FILE
6 changes: 3 additions & 3 deletions .github/actions/run_tests/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ inputs:
description: Additional flags to pass to pytest, i.e., markers
required: false
default: ""
cubit-root:
description: Path to the cubit installation
cubitpy_config_file:
description: Path to the cubitpy config file
required: false
default: ""
runs:
Expand All @@ -18,7 +18,7 @@ runs:
BEAMME_FOUR_C_EXE: /home/user/4C/bin/4C
OMPI_MCA_rmaps_base_oversubscribe: 1
run: |
export CUBIT_ROOT=${{ inputs.cubit-root }}
export CUBITPY_CONFIG_PATH=${{ inputs.cubitpy_config_file }}
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

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

This line is incorrectly setting CUBIT_ROOT to the config file path. According to the README (line 376), CUBIT_ROOT should point to the Cubit/Coreform installation path, not a config file. The cubit_setup action already sets the installation path in GITHUB_ENV as 'cubit_root' (line 49 of cubit_setup/action.yml), which should be available as an environment variable here. If CubitPy now requires a config file path in addition to CUBIT_ROOT, it should be exported using a different environment variable name (e.g., CUBITPY_CONFIG_FILE). This line needs to be corrected to either: 1) export CUBIT_ROOT from the environment variable that was set in cubit_setup, or 2) export a different environment variable for the config file path while also ensuring CUBIT_ROOT is properly set.

Suggested change
export CUBITPY_CONFIG_PATH=${{ inputs.cubitpy_config_file }}
export CUBITPY_CONFIG_PATH=${{ inputs.cubitpy_config_file }}
export CUBIT_ROOT="${{ env.cubit_root }}"

Copilot uses AI. Check for mistakes.
cd ${GITHUB_WORKSPACE}
TEMP_DIR="${RUNNER_TEMP}/beamme_pytest"
mkdir -p "$TEMP_DIR"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/testing_protected.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,12 @@ jobs:
uses: ./.github/actions/run_tests
with:
additional-pytest-flags: "--4C --ArborX --CubitPy --check-for-unused-reference-files --cov-fail-under=93"
cubit-root: ${{ steps.cubit.outputs.cubit_root }}
cubitpy_config_file: ${{ steps.cubit.outputs.cubitpy_config_file }}
- name: Free cubit license
if: ${{ always() }}
uses: ./.github/actions/cubit_finalize
with:
cubit-root: ${{ steps.cubit.outputs.cubit_root }}
cubitpy_config_file: ${{ steps.cubit.outputs.cubitpy_config_file }}
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

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

The cubit_finalize action is being passed 'cubit_config_file', but the action definition (.github/actions/cubit_finalize/action.yml) has not been updated in this PR and still expects 'cubit-root' as an input parameter. This will cause the finalize step to fail because: 1) the parameter name mismatch means the action won't receive the value, and 2) even if the parameter name were updated, the action needs the actual Cubit installation path (to run rlm_activate), not the config file path. The cubit_finalize action needs to be updated to either accept the installation path via the 'cubit_root' environment variable that was set in cubit_setup, or parse the installation path from the config file.

Suggested change
cubitpy_config_file: ${{ steps.cubit.outputs.cubitpy_config_file }}
cubit-root: ${{ env.cubit_root }}

Copilot uses AI. Check for mistakes.
- name: Coverage badge and report
uses: ./.github/actions/coverage

Expand Down
Loading