Include LICENSE file in Python distribution#4048
Conversation
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
|
Also in pyproject.toml (since |
|
Just checking -- is that a request to convert to using pyproject.toml for packaging instead of setup.py in this PR, or are you simply pointing out that doing this in pyproject.toml is a possibility in case that's used in this project in the future? |
AFAIK setup.py is slowly being deprecated so it is good to know that this LICENSE stuff is also compliant with the toml approach so the day we [have to] migrate we already have a clean shape. |
I have tooling in place to pull the license text from packages using
pip-licenses. I noticed, however, thatortoolsdoes not include the license file in its Python distribution, and as a result, it is difficult to pull in the license file from the project, especially since there is no link back to the Github repo in the Python package (https://developers.google.com/optimization/is listed as the package URL).I am proposing including the
LICENSEfile in the Python distribution by copying the License in as part of thepython.cmakefile. By doing so, it will get picked up bysetuptoolssince it defaults to including files that match the following patterns:'LICEN[CS]E*', 'COPYING*', 'NOTICE*', 'AUTHORS*'as described in code here or in the docs here (underlicense_files).In addition, I removed the
setup_data.pysince it seemed like an outdated version ofsetup.py.inwhich appears to be what has been used recently. Please correct me if I shouldn't have removed this.I will note that I have yet to be able to test this since I don't have the full toolchain set up.