Skip to content

Commit 77d2eef

Browse files
committed
debug 2
1 parent f4daa6e commit 77d2eef

1 file changed

Lines changed: 14 additions & 14 deletions

File tree

.github/workflows/label-validation.yml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: PR Label Validation
2-
run-name: "Validate ${{ github.event.label.name }} PR #${{ github.event.pull_request.number }}"
2+
run-name: "Validate PR #${{ github.event.pull_request.number }}"
33

44
on:
55
pull_request:
@@ -15,22 +15,23 @@ jobs:
1515
model-prefix: ${{ steps.parse-label.outputs.model-prefix }}
1616
steps:
1717
- name: Parse label
18+
id: parse-label
1819
shell: python
1920
run: |
21+
import json
2022
import re
23+
import os
2124
22-
print("${{ github.event.label.name }}")
25+
# Print all PR labels
26+
labels_json = '${{ toJson(github.event.pull_request.labels) }}'
27+
print(f"All PR labels JSON: {labels_json}")
2328
24-
# Matches strings like h200-trt_gptoss
25-
runner_model_pattern = r'^([^_]+)_([^_]+)$'
26-
match = re.match(runner_model_pattern, '${{ github.event.label.name }}')
27-
if match:
28-
runner_type = match.group(1)
29-
model_prefix = match.group(2)
29+
labels = '${{ github.event.pull_request.labels }}'
30+
print(f"All PR labels: {labels}")
3031
31-
with open(os.environ['GITHUB_OUTPUT'], 'a') as f:
32-
f.write(f'runner-type={runner_type}\n')
33-
f.write(f'model-prefix={model_prefix}\n')
32+
labels = json.loads(labels_json)
33+
label_names = [label['name'] for label in labels]
34+
print(f"Label names: {label_names}")
3435
3536
3637
@@ -54,17 +55,16 @@ jobs:
5455
--seq-lens 1k1k \
5556
--test-mode \
5657
--config-files \
57-
${GITHUB_WORKSPACE}..github/configs/nvidia-master.yaml \
58+
${GITHUB_WORKSPACE}/.github/configs/nvidia-master.yaml \
5859
${GITHUB_WORKSPACE}/.github/configs/amd-master.yaml \
5960
--runner-config ${GITHUB_WORKSPACE}/.github/configs/runners.yaml)
6061
echo "search-space-config=$CONFIG_JSON" >> $GITHUB_OUTPUT
6162
6263
validate:
6364
needs: get-jobs
64-
# Prolly unnecessary
65+
# Prolly unnecessary
6566
if: ${{ needs.get-jobs.outputs.search-space-config != '[]' }}
6667
uses: ./.github/workflows/benchmark-tmpl.yml
67-
name: Validate ${{ github.event.label.name }}
6868
strategy:
6969
fail-fast: false
7070
matrix:

0 commit comments

Comments
 (0)