Skip to content

Commit e3a3587

Browse files
authored
fix: Capture PR number on merge to master (#314)
fix: capture PR number on merge to master
1 parent a971322 commit e3a3587

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

.github/workflows/evaluations.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,14 @@ on:
1010
- 'master'
1111
# Also run on PRs with 'evals' label for testing
1212
pull_request:
13-
types: [labeled, synchronize, reopened]
13+
types: [labeled, synchronize, reopened, closed]
1414

1515
jobs:
1616
evaluations:
1717
name: MCP tool calling evaluations
1818
runs-on: ubuntu-latest
19-
# Run on master pushes or PRs with 'evals' label
20-
if: github.event_name == 'push' || contains(github.event.pull_request.labels.*.name, 'validated')
19+
# Run on master pushes, merged PRs, or PRs with 'validated' label
20+
if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.pull_request.merged == true) || contains(github.event.pull_request.labels.*.name, 'validated')
2121

2222
steps:
2323
- name: Checkout code
@@ -39,7 +39,7 @@ jobs:
3939
- name: Run evaluations
4040
run: npm run evals:run
4141
env:
42-
GITHUB_PR_NUMBER: ${{ github.event_name == 'pull_request' && github.event.number || 'master' }}
42+
GITHUB_PR_NUMBER: ${{ github.event_name == 'pull_request' && github.event.number || (github.event_name == 'push' && 'master') || 'unknown' }}
4343
PHOENIX_API_KEY: ${{ secrets.PHOENIX_API_KEY }}
4444
PHOENIX_BASE_URL: ${{ secrets.PHOENIX_BASE_URL }}
4545
OPENROUTER_BASE_URL: ${{ secrets.OPENROUTER_BASE_URL }}

0 commit comments

Comments
 (0)