Skip to content

Commit

Permalink
Add handling to report-failures when no log files are available (#1009)
Browse files Browse the repository at this point in the history
  • Loading branch information
charlesbluca authored Jan 25, 2023
1 parent 4e1642d commit 08cff1a
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions .github/workflows/test-upstream.yml
Original file line number Diff line number Diff line change
Expand Up @@ -203,15 +203,20 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: actions/download-artifact@v3
with:
name: test-ubuntu-latest-py3.10-results
- name: Prepare issue label
- name: Prepare logs & issue label
run: |
# TODO: remove this if xarray-contrib/issue-from-pytest-log no longer needs a log-path
if [ -f test-ubuntu-latest-py3.10-results/test-ubuntu-latest-py3.10-results.jsonl ]; then
cp test-ubuntu-latest-py3.10-results/test-ubuntu-latest-py3.10-results.jsonl results.jsonl
else
touch results.jsonl
fi
# convert which_upstream to lowercase
echo "which_upstream_lower=${which_upstream,,}" >> $GITHUB_ENV
- name: Open or update issue on failure
uses: xarray-contrib/[email protected]
with:
log-path: test-ubuntu-latest-py3.10-results.jsonl
log-path: results.jsonl
issue-title: ⚠️ Upstream CI ${{ env.which_upstream }} failed ⚠️
issue-label: upstream-${{ env.which_upstream_lower }}

0 comments on commit 08cff1a

Please sign in to comment.