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

Include LICENSE in the generated wheels #255

Closed
pradyunsg opened this issue Oct 14, 2021 · 7 comments · Fixed by #266
Closed

Include LICENSE in the generated wheels #255

pradyunsg opened this issue Oct 14, 2021 · 7 comments · Fixed by #266

Comments

@pradyunsg
Copy link
Contributor

See https://github.com/cython/cython/pull/3982/files for an example of how to do so.

This is necessary since pip’s vendoring logic is being changed to allow using wheels preferentially. This means it would need to use a hard-coded URL for the license of this package, until this package adds a license directly.

@itamarst
Copy link
Contributor

I will try to open PR for this today.

@itamarst
Copy link
Contributor

Actually, looks like this was fixed? setup.cfg now has:

[metadata]
license_files =
   LICENSES/*

@itamarst
Copy link
Contributor

itamarst commented Nov 4, 2021

However, pip's vendoring still didn't seem happy? Will investigate at some point since I suspect pip will want this as part of the update.

@pradyunsg
Copy link
Contributor Author

pradyunsg commented Nov 5, 2021

IANAL but it seems like #226 removed the license text and added incorrect content in the Licenses/ directory.

Right now, there's no copyright assignment line in the repository's license. Further, instead of using the license text that Apache provides (see https://www.apache.org/licenses/LICENSE-2.0#apply), that PR seems to have copied the raw license text -- which is not how you apply the license IIUC.

I think removing LICENSES/* files, adding a single LICENSE file (with the same content as removed in #226) and updating the setup.cfg would make the tooling work, as well as be the right thing to do.

@ionrock
Copy link
Contributor

ionrock commented Nov 5, 2021

@pradyunsg Do you have a way to verify if #266 fixes the License bits?

@pradyunsg
Copy link
Contributor Author

The easiest way would be to build a wheel with that commit, unzip it (wheels are zip files, with additional structure) and see whether there's a LICENSE.txt file in there.

As long as the licence file has COPYING or LICENSE in the name, it'll work just fine with the automation that pip uses.

@pradyunsg
Copy link
Contributor Author

Thanks @ionrock! ^>^

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 a pull request may close this issue.

3 participants