From f0975578c1faec11a579aae63d5fd8fdd217e6d8 Mon Sep 17 00:00:00 2001 From: Rashid N H M <95639609+rashidnhm@users.noreply.github.com> Date: Fri, 21 Jun 2024 15:59:00 -0400 Subject: [PATCH] sc-66351 auto onboard large runenrs (#774) **Context:** This PR fixes an issue introduced as part of the previous pr #769 . This issue was identified while trying to replicate an RC branch and testing the workflows as part of #773. **Description of the Change:** - Added extra echo statements to see clearly the outcome of the workflow if logic - Removes quotes around the regex expression as that was making all evaluations of the logic to go false. - This issue did not arise in my previous testing but turned out to be a mismatch in shell configuration between myself locally and github actions. I was able to reproduce the bug locally and see that this worked. #773 worked as expected with the changes introduced in this PR. Links: - https://github.com/PennyLaneAI/pennylane-lightning/actions/runs/9616650952/job/26526641408?pr=773#step:2:14 - https://github.com/PennyLaneAI/pennylane-lightning/actions/runs/9616650967/job/26526641639?pr=773#step:2:14 **Benefits:** Auto on-boarding tested and working with this fix. **Possible Drawbacks:** **Related GitHub Issues:** --------- Co-authored-by: ringo-but-quantum Co-authored-by: Vincent Michaud-Rioux Co-authored-by: Ali Asadi <10773383+maliasadi@users.noreply.github.com> --- .github/CHANGELOG.md | 3 +++ .github/workflows/determine-workflow-runner.yml | 5 ++++- pennylane_lightning/core/_version.py | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/CHANGELOG.md b/.github/CHANGELOG.md index 871b50c2d0..e694d46ee1 100644 --- a/.github/CHANGELOG.md +++ b/.github/CHANGELOG.md @@ -98,6 +98,9 @@ ### Bug fixes +* Fix regex matching issue with auto on-boarding of release candidate branch to using the large runner queue. + [(#774)](https://github.com/PennyLaneAI/pennylane-lightning/pull/774) + * Fix random CI failures for `lightning.tensor` python unit tests and ignore `lightning_tensor` paths. [(#761)](https://github.com/PennyLaneAI/pennylane-lightning/pull/761) diff --git a/.github/workflows/determine-workflow-runner.yml b/.github/workflows/determine-workflow-runner.yml index 4bb994275f..981c45f7d9 100644 --- a/.github/workflows/determine-workflow-runner.yml +++ b/.github/workflows/determine-workflow-runner.yml @@ -41,6 +41,9 @@ jobs: RC_BRANCH_FORMAT_REGEX: v[0-9]+\.[0-9]+\.[0-9]+-rc[0-9]? REPO_FULL_NAME: PennyLaneAI/pennylane-lightning run: | - if [[ '${{ contains(github.event.pull_request.labels.*.name, 'urgent') }}' == 'true' || ('${{ github.event.pull_request.head.repo.full_name }}' == "$REPO_FULL_NAME" && "${{ github.event.pull_request.head.ref }}" =~ "$RC_BRANCH_FORMAT_REGEX") ]]; then + if [[ '${{ contains(github.event.pull_request.labels.*.name, 'urgent') }}' == 'true' || ('${{ github.event.pull_request.head.repo.full_name }}' == "$REPO_FULL_NAME" && '${{ github.event.pull_request.head.ref }}' =~ $RC_BRANCH_FORMAT_REGEX) ]]; then + echo "This job requires usage of the large runner group '$LARGE_RUNNER_GROUP_NAME'"; echo "runner_group=$LARGE_RUNNER_GROUP_NAME" >> $GITHUB_OUTPUT + else + echo "This job does not require usage of large runners ..."; fi diff --git a/pennylane_lightning/core/_version.py b/pennylane_lightning/core/_version.py index f288d1200e..8a46df66d0 100644 --- a/pennylane_lightning/core/_version.py +++ b/pennylane_lightning/core/_version.py @@ -16,4 +16,4 @@ Version number (major.minor.patch[-label]) """ -__version__ = "0.37.0-dev45" +__version__ = "0.37.0-dev46"