Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: correct PR number retrieval to fix size-report action #11223

Merged
merged 3 commits into from
Jun 28, 2024

Conversation

jh-leong
Copy link
Member

I noticed that the size report action has not been working recently.

The failure is due to the action using github.event.workflow_run.pull_requests[0].number to read the PR number. However, according to GitHub's security policy (ref: https://github.com/orgs/community/discussions/25220), this approach does not work for PRs from forked repositories as pull_requests can be empty.

To resolve this, I have reverted the method of retrieving the PR number to the previous implementation using artifact.

@ferferga
Copy link
Contributor

ferferga commented Jun 26, 2024

@jh-leong I couldn't reproduce what you say. This looks like could be the solution

The artifacts idea is not good either: it can be tampered in the origin.

@ferferga
Copy link
Contributor

This is another approach that we could attempt, imo even better because that way, in runs logs, they're grouped and it's easier to know the general flow of what's happening.

@yyx990803
Copy link
Member

/cc @sxzz

@yyx990803 yyx990803 requested a review from sxzz June 28, 2024 01:35
@sxzz sxzz merged commit 2f11a45 into vuejs:main Jun 28, 2024
11 checks 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.

4 participants