Skip to content

fix(pr-comment): omit 'View full report' link when reportUrl is empty#5

Merged
PrestaEdit merged 1 commit into
mainfrom
fix/omit-empty-report-link
Jul 11, 2026
Merged

fix(pr-comment): omit 'View full report' link when reportUrl is empty#5
PrestaEdit merged 1 commit into
mainfrom
fix/omit-empty-report-link

Conversation

@PrestaEdit

Copy link
Copy Markdown
Contributor

Bug

The upload endpoint on api.prestaflow.io/ci/github-action/ currently only returns {id} in the response body (no url). The action then rendered the PR comment with:

📊 [View full report]()

which GitHub resolves to the current page (i.e. clicking it takes readers back to the PR they're already on). Confusing UX.

Fix

When reportUrl is empty, drop the link line entirely. Once the API starts returning a url, the link comes back automatically — no code change needed.

Applies to both success and failure body variants.

Test plan

Follow-up

The API should return a url field alongside id — separate ticket on the backend.

🤖 Generated with Claude Code

The API endpoint currently doesn't return a 'url' field in its response,
so reportUrl was rendered as '[View full report]()' — an empty href that
GitHub resolves to the current page (the PR itself). Confusing for
readers.

When reportUrl is empty, drop the link line entirely. Once the API
returns a proper URL, the link comes back automatically without a code
change.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@PrestaEdit
PrestaEdit merged commit 7c2ef4f into main Jul 11, 2026
1 check passed
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