Make WordPress Core

Opened 22 months ago

Last modified 6 weeks ago

#54510 reviewing enhancement

Add a GitHub Action workflow which alerts contributors if they propose changes to third party files

Reported by: johnbillion's profile johnbillion Owned by: johnbillion's profile johnbillion
Milestone: 6.4 Priority: normal
Severity: normal Version:
Component: Build/Test Tools Keywords: good-first-bug has-patch
Focuses: Cc:

Description

WordPress core includes files from several third party libraries such as ID3, SimplePie, and Requests. Changes to these libraries shouldn't be made directly in core, they should be made upstream.

If a contributor opens a pull request proposing changes to these files it would be great if a comment was automatically posted to the PR explaining that they've proposed changes to a third party library and they should visit the corresponding project's repo for info about contributing to it.

While there's not much we can do about this when a contributor submits a patch to a file in an affected path, it should be possible to do this when a PR is submitted via GitHub. A GitHub Action workflow could use the path keyword to post a comment to the PR whenever a file in an affected path is changed.

There are also files that get copied from Gutenberg and can clobber those in core, I opened https://github.com/WordPress/gutenberg/issues/36868 to discuss that.

Change History (7)

#1 @desrosj
8 months ago

  • Milestone changed from Awaiting Review to Future Release

I think that this is a great idea. +1.

#2 @johnbillion
5 months ago

  • Keywords good-first-bug added

#3 @abhi3315
3 months ago

Please help me find out what paths (libraries) we should look for in the GitHub action.

I have created the following list for such 3rd party libraries-

  • src/wp-includes/ID3
  • src/wp-includes/IXR
  • src/wp-includes/PHPMailer
  • src/wp-includes/Requests
  • src/wp-includes/SimplePie
  • src/wp-includes/sodium_compat
  • src/wp-includes/Text

Please add more such libraries.

#4 @johnbillion
3 months ago

Let's go with that list for now, we can always add to it at a later date.

We've already got the "Welcome New Contributors" workflow which can post a comment on a PR, it should be a good starting point for this new workflow.

Edit: Actually maybe not, that action is specific to new contributors.

Last edited 3 months ago by johnbillion (previous) (diff)

This ticket was mentioned in PR #4775 on WordPress/wordpress-develop by @abhi3315.


3 months ago
#5

  • Keywords has-patch added; needs-patch removed

Trac ticket: 54510

#6 @abhi3315
3 months ago

@johnbillion Please review the PR

Check the demo comment here

If no third-party files are changed then the job will be skipped.

#7 @johnbillion
6 weeks ago

  • Milestone changed from Future Release to 6.4
  • Owner set to johnbillion
  • Status changed from new to reviewing
Note: See TracTickets for help on using tickets.