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 file in the generated wheel package #102

Closed
wants to merge 1 commit into from

Conversation

@jdufresne
Copy link
Contributor

@jdufresne jdufresne commented Nov 26, 2017

The wheel package format supports including the license file. This is done using the [metadata] section in the setup.cfg file. For additional information on this feature, see:

https://wheel.readthedocs.io/en/stable/index.html#including-the-license-in-the-generated-wheel-file

Distributing the wheel now complies with the license:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

@ingydotnet
Copy link
Member

@ingydotnet ingydotnet commented Apr 11, 2018

@jdufresne I'm planning to release pyyaml soon. As this will be the first release since taking over ownership of this important package, do you have pointers on what needs to happen?

Questions:

  • Are wheels generated automatically by pypi?
  • Is there a normal practice of putting out dev/trial/RC releases?

Any help would be appreciated.

Loading

@ingydotnet ingydotnet mentioned this pull request Apr 11, 2018
The wheel package format supports including the license file. This is
done using the [metadata] section in the setup.cfg file. For additional
information on this feature, see:

https://wheel.readthedocs.io/en/stable/index.html#including-the-license-in-the-generated-wheel-file

Distributing the wheel now complies with the license:

> The above copyright notice and this permission notice shall be
> included in all copies or substantial portions of the Software.
@jdufresne
Copy link
Contributor Author

@jdufresne jdufresne commented Apr 11, 2018

Are wheels generated automatically by pypi?

No they are not. They are generated and then uploaded to PyPI. When you'd normally run python setup.py sdist upload, run instead python setup.py sdist bdist_wheel upload.

Although as PyYAML is not a pure Python package (contains compiled code), it may be slightly more complicated. Unfortunately, I don't have much experience maintaining non-pure Python packages, so you may need to look elsewhere for documentation. One good starting point is:

https://pythonwheels.com/

Is there a normal practice of putting out dev/trial/RC releases?

That probably depends on the preferences of the package maintainers. I'm not sure what that is for PyYAML.

Loading

@samuelcolvin
Copy link

@samuelcolvin samuelcolvin commented Apr 11, 2018

Generating wheels correctly for packages including compiled code is far from trivial.

The number 1 piece of advice I would give would be setup travis to manage deploys to pypi. Then when you want to release it's as simple as creating a release in github and everything else is taken care of. It's slightly more complicated the first time, but it's massively easier in 6 months when you come to deploy and don't have to set everything up and remember what the heck you did last time.

The basic setup of travis to deploy to pypi is fairly easy and well documented, generating wheels for manylinux and macos is more complicated, this is a good resource, but you might also look at aiohttp's travis setup which deals with building manylinux and macos wheels.

I believe aiohttp has also managed to automate the generation of wheels for windows which can't be done with travis.

Loading

@webknjaz
Copy link

@webknjaz webknjaz commented Jul 3, 2018

In fact, it doesn't have to be as complex as I did for aiohttp. I've done some refactoring in #172 and if @ingydotnet agrees I'll help with autodeployment and wheel generation parts as well.

Loading

Copy link

@webknjaz webknjaz left a comment

@ingydotnet please merge this PR. It's completely valid and adds value to binary dists.

Loading

@ingydotnet
Copy link
Member

@ingydotnet ingydotnet commented Jul 5, 2018

@nitzmahone please review this when you have time.

Loading

@ingydotnet ingydotnet added this to To Do in 5.1 Release Feb 20, 2019
@ingydotnet ingydotnet moved this from Possible PRs and To Do items to Added to release/5/1 branch in 5.1 Release Feb 23, 2019
@jdufresne jdufresne closed this Mar 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
5.1 Release
Added to release/5/1 branch
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants