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

check-licenses: GPLv3 isn't recognized as a compatible license #20701

Open
cliffordp opened this issue Mar 8, 2020 · 10 comments
Open

check-licenses: GPLv3 isn't recognized as a compatible license #20701

cliffordp opened this issue Mar 8, 2020 · 10 comments
Labels
Good First Issue An issue that's suitable for someone looking to contribute for the first time [Tool] WP Scripts /packages/scripts [Type] Developer Documentation Documentation for developers

Comments

@cliffordp
Copy link
Contributor

cliffordp commented Mar 8, 2020

Re: https://github.com/WordPress/gutenberg/blob/%40wordpress/scripts%407.1.2/packages/scripts/scripts/check-licenses.js#L36

May be related: #7821

Describe the bug

GPLv3+ should be recognized as compatible, per:
A)
https://github.com/WordPress/WordPress/blob/5.3.2/readme.html#L94-L95

WordPress is free software, and is released under the terms of the GPL (GNU General Public License) version 2 or (at your option) any later version.

and

B)
https://www.gnu.org/licenses/license-list.en.html#GNUGPL

Please note that GPLv3 is not compatible with GPLv2 by itself. However, most software released under GPLv2 allows you to use the terms of later versions of the GPL as well. When this is the case, you can use the code under GPLv3 to make the desired combination.
... links to https://www.gnu.org/licenses/gpl-faq.html#AllCompatibility
... screenshot of it:

image

To reproduce

In your plugin's package.json, set "license": "GPL-3.0-or-later", then run wp-scripts check-licenses and you'll get this message:

ERROR Module your-plugin has an incompatible license 'GPL-3.0-or-later'.

Change the package.json to "license": "GPL-2.0-or-later", re-run, and no messages.

Expected behavior

No error message with GPLv3+.

See comment from @pento to learn about the proposed solution:
#20701 (comment).

@gziolo gziolo added [Tool] WP Scripts /packages/scripts [Type] Bug An existing feature does not function as intended Needs Testing Needs further testing to be confirmed. labels Mar 8, 2020
@gziolo
Copy link
Member

gziolo commented Apr 20, 2020

@ntwb or @pento – do we need a fix in @wordress/scripts?

@ntwb
Copy link
Member

ntwb commented Apr 20, 2020

I don’t think so, there’s a prior discussion on this subject, I’ll try dig this out tomorrow and follow up

@cliffordp
Copy link
Contributor Author

Checking in... would be really curious if this is determined not to be an issue. Thanks!

@kevin940726
Copy link
Member

@ntwb @cliffordp Do we have an update on this? Do we still want to fix this?

@kevin940726 kevin940726 added [Status] Needs More Info Follow-up required in order to be actionable. and removed Needs Testing Needs further testing to be confirmed. labels Sep 29, 2020
@cliffordp
Copy link
Contributor Author

awaiting @ntwb's research from April 20

@ntwb
Copy link
Member

ntwb commented Oct 11, 2020

I'm still unsure of this, search WP Slack for GPLv3 and there are numerous discussions in the theme and plugin channels on the subject, need to extract out this conversation

Possibly @Otto42 could weigh in here also

@github-actions
Copy link

Help us move this issue forward. Since it has no activity after 15 days of requesting more information, a bot is marking the issue as stale. Please add additional information as a comment or this issued will be closed in 5 days.

@github-actions github-actions bot added the [Status] Stale Gives the original author opportunity to update before closing. Can be reopened as needed. label Jan 17, 2021
@ntwb
Copy link
Member

ntwb commented Jan 18, 2021

@pento Any thoughts on this?

@pento
Copy link
Member

pento commented Jan 18, 2021

check-licenses is a somewhat WordPress-specific tool: it assumes that the software is being released as GPLv2. Historically, WordPress hasn't used libraries, as defined in GPLv3: we've copied entire libraries, but we often modify them, which means they're considered copies, rather than libraries.

Gutenberg is better about this: libraries it uses are actually included as libraries, so GPLv3 could be added to otherOssLicenses. As I understand @cliffordp's original report, this would likely solve his particular issue, assuming he isn't using the --gpl2 option.

It may also be worth being more explicit about the check-licenses behaviour in the @wordpress/scripts/ readme: in particular, noting that this is a WordPress-specific tool, and isn't guaranteed to produce correct results in other use cases: licenses are usually only added the list when Gutenberg needs it.

Given that the plugin directory allows plugins to have any GPL-compatible license, not just a GPL-based license, it would be a challenging problem to maintain a licenses compatibility matrix that works in this more general case.

@github-actions github-actions bot removed the [Status] Stale Gives the original author opportunity to update before closing. Can be reopened as needed. label Jan 23, 2021
@gziolo gziolo added Good First Issue An issue that's suitable for someone looking to contribute for the first time Needs Dev Ready for, and needs developer efforts and removed [Status] Needs More Info Follow-up required in order to be actionable. labels Feb 1, 2021
@gziolo gziolo added [Type] Developer Documentation Documentation for developers and removed Needs Dev Ready for, and needs developer efforts [Type] Bug An existing feature does not function as intended labels Feb 11, 2022
@ryanwelcher
Copy link
Contributor

What needs to be done here from a docs point of view?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Good First Issue An issue that's suitable for someone looking to contribute for the first time [Tool] WP Scripts /packages/scripts [Type] Developer Documentation Documentation for developers
Projects
None yet
Development

No branches or pull requests

6 participants