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: GPL Compatible license declared #436

Closed
davidperezgar opened this issue Mar 16, 2024 · 4 comments · Fixed by #454
Closed

Check: GPL Compatible license declared #436

davidperezgar opened this issue Mar 16, 2024 · 4 comments · Fixed by #454
Assignees
Labels
Good First Issue Issue particularly suitable to be worked on by new contributors [Team] Plugin Review Issues owned by Plugin Review Team [Type] Enhancement A suggestion for improvement of an existing feature

Comments

@davidperezgar
Copy link
Member

The plugins must be GPL compatible, so we have to warn to developers to fix this issue.

It has to be declared in readme and plugin. And we have to check if they are the same in both files.

This is the text that we are using to warn users.

## No GPL-compatible license declared

It is necessary to declare the license of this plugin. You can do this using the fields available both in the plugin readme and in the plugin headers.

Remember that all code, data, and images — anything stored in the plugin directory hosted on WordPress.org — must comply with the GPL or a GPL-Compatible license. Included third-party libraries, code, images, or otherwise, must be also compatible

For a specific list of compatible licenses, [please read the GPL-Compatible license list on gnu.org](https://www.gnu.org/licenses/license-list.html#GPLCompatibleLicenses).

The license declared on this plugin is either no present or it's not GPL compatible:

ERROR: License declaration not found on tiqq-shop.php
Please check the header requirements in order to correctly declare the license of the plugin: https://developer.wordpress.org/plugins/plugin-basics/header-requirements/
It is necessary to configure the "License: " field in the plugin header with a valid, GPL-compliant license name.
@swissspidy swissspidy added the [Type] Enhancement A suggestion for improvement of an existing feature label Mar 16, 2024
@swissspidy
Copy link
Member

The current license check is a bit limited:

  • Only checks the readme, not the plugin header
  • Only checks if missing or not valid SPDX format

Should be trivial to add an allowlist of compatible licenses and then check for those in both files (and ensure both files use the same one, of course)

@swissspidy swissspidy added the Good First Issue Issue particularly suitable to be worked on by new contributors label Mar 19, 2024
@davidperezgar
Copy link
Member Author

Assign me this issue, I'll start to do it.

@davidperezgar
Copy link
Member Author

Hey, What would be the best approach for this issue?
What I'm thinking is creating a new file check Checks/Plugin_License_Check.php and that file could process Readme License check and Plugin Header Check and compare both of them.

@davidperezgar
Copy link
Member Author

Done in the #454

@davidperezgar davidperezgar self-assigned this Apr 10, 2024
davidperezgar added a commit that referenced this issue Jun 9, 2024
@davidperezgar davidperezgar added the [Team] Plugin Review Issues owned by Plugin Review Team label Jun 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Good First Issue Issue particularly suitable to be worked on by new contributors [Team] Plugin Review Issues owned by Plugin Review Team [Type] Enhancement A suggestion for improvement of an existing feature
2 participants