Skip to content

fix(review): read the --open review URL from stderr (oasdiff >= v1.19.1)#165

Merged
reuvenharrison merged 1 commit into
mainfrom
fix/open-url-grep-stderr
Jun 14, 2026
Merged

fix(review): read the --open review URL from stderr (oasdiff >= v1.19.1)#165
reuvenharrison merged 1 commit into
mainfrom
fix/open-url-grep-stderr

Conversation

@reuvenharrison

Copy link
Copy Markdown
Contributor

What

oasdiff v1.19.1 (oasdiff/oasdiff#1011) moved the Opening <url> line from stdout to stderr so --open can't corrupt piped --format json/yaml output. But the action's --open run extracts the review URL by grepping stdout with 2>/dev/null:

free_review_url=$(oasdiff breaking ... --open --template= 2>/dev/null | grep .../review/e/...)

Against v1.19.1 that finds nothing → the action emits the misleading "couldn't upload, re-run the job" warning and posts no review comment at all, silently breaking the entire free-review link.

Fix

Merge stderr into the pipe (2>&1) so the URL is captured regardless of which stream oasdiff prints it on. Works with both old (stdout, ≤ v1.19.0) and new (stderr, ≥ v1.19.1) oasdiff.

How it was caught

The w3 encrypted-review e2e, run against tufin/oasdiff:latest (main HEAD, with #1011) via a test/oasdiff-latest-image action branch: the workflow failed the gate as expected but no /review/e comment appeared; the run log showed oasdiff: couldn't upload the side-by-side review. This must merge before action v0.1.1 is cut on oasdiff v1.19.1.

Test

sh -n clean on both entrypoints; re-validated by re-running the encrypted-review e2e with this fix applied (green).

🤖 Generated with Claude Code

oasdiff v1.19.1 (#1011) moved the "Opening <url>" line from stdout to stderr so
it can't corrupt piped --format json/yaml output. The action's --open run greps
the URL from stdout with `2>/dev/null`, so against v1.19.1 it found no URL,
emitted the misleading "couldn't upload, re-run" warning, and posted NO review
comment -- a silent break of the whole free-review link. Caught by the w3
encrypted-review e2e run against tufin/oasdiff:latest.

Merge stderr into the pipe (2>&1) so the URL is captured regardless of which
stream oasdiff prints it on. Works with both old (stdout) and new (stderr) oasdiff.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@reuvenharrison reuvenharrison merged commit 4e89893 into main Jun 14, 2026
56 checks passed
@reuvenharrison reuvenharrison deleted the fix/open-url-grep-stderr branch June 14, 2026 20:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant