Skip to content

Conversation

@anomiex
Copy link
Contributor

@anomiex anomiex commented Jan 26, 2023

Proposed changes:

There was a subtle change in the plugin upgrade test in the move from the Build to the Post-Build workflow: since the latter runs via workflow_run, the "current" branch is trunk rather than the PR commit, so that's what gets checked out.

Mostly that works fine, but at one point we look in the checkout for the plugin's wp-plugin-slug. For that one check, we need a copy of the PR commit rather than trunk. But we want to keep everything else running off of trunk to avoid potential security issues (the same ones that led GitHub to introduce the "pull_request_target" event).

Other information:

  • Have you written new tests for your changes, if applicable?
  • Have you checked the E2E test CI results, and verified that your changes do not break them?
  • Have you tested your changes on WordPress.com, if applicable (if so, you'll see a generated comment below with a script to run)?

Jetpack product discussion

#28479 (comment)

Does this pull request change what data or activity we track or use?

No

Testing instructions:

There was a subtle change in the plugin upgrade test in the move from
the Build to the Post-Build workflow: since the latter runs via
`workflow_run`, the "current" branch is trunk rather than the PR commit,
so that's what gets checked out.

Mostly that works fine, but at one point we look in the checkout for the
plugin's `wp-plugin-slug`. For that one check, we need a copy of the PR
commit rather than trunk. But we want to keep everything else running
off of trunk to avoid potential security issues (the same ones that led
GitHub to introduce the "pull_request_target" event).
@anomiex anomiex added [Type] Bug When a feature is broken and / or not performing as intended [Status] Needs Review This PR is ready for review. [Pri] Normal labels Jan 26, 2023
@anomiex anomiex requested a review from samiff January 26, 2023 17:14
@anomiex anomiex self-assigned this Jan 26, 2023
@github-actions github-actions bot added the Actions GitHub actions used to automate some of the work around releases and repository management label Jan 26, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Jan 26, 2023

Thank you for your PR!

When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:

  • ✅ Include a description of your PR changes.
  • ✅ All commits were linted before commit.
  • ✅ Add a "[Status]" label (In Progress, Needs Team Review, ...).
  • ✅ Add testing instructions.
  • ✅ Specify whether this PR includes any changes to data or privacy.
  • ✅ Add changelog entries to affected projects

This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖


The e2e test report can be found here. Please note that it can take a few minutes after the e2e tests checks are complete for the report to be available.


Once your PR is ready for review, check one last time that all required checks (other than "Required review") appearing at the bottom of this PR are passing or skipped.
Then, add the "[Status] Needs Team review" label and ask someone from your team review the code.
Once you’ve done so, switch to the "[Status] Needs Review" label; someone from Jetpack Crew will then review this PR and merge it to be included in the next Jetpack release.

Copy link
Contributor

@samiff samiff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's give it a shot

@samiff samiff added [Status] Ready to Merge Go ahead, you can push that green button! and removed [Status] Needs Review This PR is ready for review. labels Jan 26, 2023
@anomiex anomiex merged commit 5ddacb8 into trunk Jan 26, 2023
@anomiex anomiex deleted the fix/post-build-checkout-pr-commit branch January 26, 2023 17:41
@github-actions github-actions bot removed the [Status] Ready to Merge Go ahead, you can push that green button! label Jan 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Actions GitHub actions used to automate some of the work around releases and repository management [Pri] Normal [Type] Bug When a feature is broken and / or not performing as intended

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants