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

Distribute license on pypi #72

Merged
merged 1 commit into from
Nov 14, 2019
Merged

Distribute license on pypi #72

merged 1 commit into from
Nov 14, 2019

Conversation

scarabeusiv
Copy link
Contributor

The license should be distributed with the archive on pypi.

The license should be distributed with the archive on pypi.
@altendky
Copy link
Member

I'm confused now... I agree that the license should go with the code. On PyPi, in the .whl, in the .zip, etc. So I see that the PyPI .zip/sdist does not contain LICENSE.

altendky@lt:~/pytest-twisted$ wget https://files.pythonhosted.org/packages/14/a2/9ee6475c39166c42e885e3147a779d17aa9c07874320473b3f4c5448fff2/pytest-twisted-1.12.zip
--2019-11-14 13:30:46--  https://files.pythonhosted.org/packages/14/a2/9ee6475c39166c42e885e3147a779d17aa9c07874320473b3f4c5448fff2/pytest-twisted-1.12.zip
Resolving files.pythonhosted.org (files.pythonhosted.org)... 151.101.201.63, 2a04:4e42:2f::319
Connecting to files.pythonhosted.org (files.pythonhosted.org)|151.101.201.63|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 15996 (16K) [binary/octet-stream]
Saving to: ‘pytest-twisted-1.12.zip’

pytest-twisted-1.12.zip                    100%[======================================================================================>]  15.62K  --.-KB/s    in 0.03s   

2019-11-14 13:30:47 (556 KB/s) - ‘pytest-twisted-1.12.zip’ saved [15996/15996]

altendky@lt:~/pytest-twisted$ unzip -l pytest-twisted-1.12.zip 
Archive:  pytest-twisted-1.12.zip
  Length      Date    Time    Name
---------  ---------- -----   ----
        0  2019-09-26 23:54   pytest-twisted-1.12/
        0  2019-09-26 23:54   pytest-twisted-1.12/pytest_twisted.egg-info/
        0  2019-09-26 23:54   pytest-twisted-1.12/testing/
     7738  2019-09-26 23:54   pytest-twisted-1.12/PKG-INFO
     5391  2019-09-26 23:46   pytest-twisted-1.12/README.rst
       90  2019-09-26 23:54   pytest-twisted-1.12/setup.cfg
      174  2018-09-19 11:39   pytest-twisted-1.12/MANIFEST.in
      573  2019-09-26 23:11   pytest-twisted-1.12/tox.ini
     1251  2019-09-26 23:46   pytest-twisted-1.12/setup.py
     8598  2019-09-26 23:18   pytest-twisted-1.12/pytest_twisted.py
        1  2019-09-26 23:54   pytest-twisted-1.12/pytest_twisted.egg-info/dependency_links.txt
     7738  2019-09-26 23:54   pytest-twisted-1.12/pytest_twisted.egg-info/PKG-INFO
      339  2019-09-26 23:54   pytest-twisted-1.12/pytest_twisted.egg-info/SOURCES.txt
       15  2019-09-26 23:54   pytest-twisted-1.12/pytest_twisted.egg-info/top_level.txt
       37  2019-09-26 23:54   pytest-twisted-1.12/pytest_twisted.egg-info/entry_points.txt
       55  2019-09-26 23:54   pytest-twisted-1.12/pytest_twisted.egg-info/requires.txt
    17895  2019-09-26 23:18   pytest-twisted-1.12/testing/test_basic.py
       36  2018-09-19 11:39   pytest-twisted-1.12/testing/conftest.py
---------                     -------
    49931                     18 files

So I tried rebuilding the sdist from v1.12 91812c1 and... huh? It contains the LICENSE file now too.

altendky@lt:~/pytest-twisted$ git rev-parse HEAD
91812c10fa6be6318982697535a75c198c8bd25e
altendky@lt:~/pytest-twisted$ git status
On branch master
Your branch is up to date with 'upstream/master'.

nothing to commit, working tree clean
altendky@lt:~/pytest-twisted$ cat MANIFEST.in
include MANIFEST.in
include README.rst
include pytest_twisted.py
include setup.cfg
include setup.py
include testing/conftest.py
include testing/test_basic.py
include tox.ini
altendky@lt:~/pytest-twisted$ python3 setup.py sdist
running sdist
running egg_info
writing pytest_twisted.egg-info/PKG-INFO
writing dependency_links to pytest_twisted.egg-info/dependency_links.txt
writing entry points to pytest_twisted.egg-info/entry_points.txt
writing requirements to pytest_twisted.egg-info/requires.txt
writing top-level names to pytest_twisted.egg-info/top_level.txt
reading manifest file 'pytest_twisted.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'pytest_twisted.egg-info/SOURCES.txt'
running check
creating pytest-twisted-1.12
creating pytest-twisted-1.12/pytest_twisted.egg-info
creating pytest-twisted-1.12/testing
copying files to pytest-twisted-1.12...
copying LICENSE -> pytest-twisted-1.12
copying MANIFEST.in -> pytest-twisted-1.12
copying README.rst -> pytest-twisted-1.12
copying pytest_twisted.py -> pytest-twisted-1.12
copying setup.cfg -> pytest-twisted-1.12
copying setup.py -> pytest-twisted-1.12
copying tox.ini -> pytest-twisted-1.12
copying pytest_twisted.egg-info/PKG-INFO -> pytest-twisted-1.12/pytest_twisted.egg-info
copying pytest_twisted.egg-info/SOURCES.txt -> pytest-twisted-1.12/pytest_twisted.egg-info
copying pytest_twisted.egg-info/dependency_links.txt -> pytest-twisted-1.12/pytest_twisted.egg-info
copying pytest_twisted.egg-info/entry_points.txt -> pytest-twisted-1.12/pytest_twisted.egg-info
copying pytest_twisted.egg-info/requires.txt -> pytest-twisted-1.12/pytest_twisted.egg-info
copying pytest_twisted.egg-info/top_level.txt -> pytest-twisted-1.12/pytest_twisted.egg-info
copying testing/conftest.py -> pytest-twisted-1.12/testing
copying testing/test_basic.py -> pytest-twisted-1.12/testing
Writing pytest-twisted-1.12/setup.cfg
creating 'dist/pytest-twisted-1.12.zip' and adding 'pytest-twisted-1.12' to it
adding 'pytest-twisted-1.12'
adding 'pytest-twisted-1.12/pytest_twisted.egg-info'
adding 'pytest-twisted-1.12/testing'
adding 'pytest-twisted-1.12/PKG-INFO'
adding 'pytest-twisted-1.12/README.rst'
adding 'pytest-twisted-1.12/setup.cfg'
adding 'pytest-twisted-1.12/MANIFEST.in'
adding 'pytest-twisted-1.12/LICENSE'
adding 'pytest-twisted-1.12/tox.ini'
adding 'pytest-twisted-1.12/setup.py'
adding 'pytest-twisted-1.12/pytest_twisted.py'
adding 'pytest-twisted-1.12/pytest_twisted.egg-info/dependency_links.txt'
adding 'pytest-twisted-1.12/pytest_twisted.egg-info/PKG-INFO'
adding 'pytest-twisted-1.12/pytest_twisted.egg-info/SOURCES.txt'
adding 'pytest-twisted-1.12/pytest_twisted.egg-info/top_level.txt'
adding 'pytest-twisted-1.12/pytest_twisted.egg-info/entry_points.txt'
adding 'pytest-twisted-1.12/pytest_twisted.egg-info/requires.txt'
adding 'pytest-twisted-1.12/testing/test_basic.py'
adding 'pytest-twisted-1.12/testing/conftest.py'
removing 'pytest-twisted-1.12' (and everything under it)
altendky@lt:~/pytest-twisted$ unzip -l dist/pytest-twisted-1.12.zip 
Archive:  dist/pytest-twisted-1.12.zip
  Length      Date    Time    Name
---------  ---------- -----   ----
        0  2019-11-14 13:32   pytest-twisted-1.12/
        0  2019-11-14 13:32   pytest-twisted-1.12/pytest_twisted.egg-info/
        0  2019-11-14 13:32   pytest-twisted-1.12/testing/
     7738  2019-11-14 13:32   pytest-twisted-1.12/PKG-INFO
     5391  2019-11-14 13:21   pytest-twisted-1.12/README.rst
       90  2019-11-14 13:32   pytest-twisted-1.12/setup.cfg
      174  2019-11-14 13:31   pytest-twisted-1.12/MANIFEST.in
     1512  2019-11-14 13:21   pytest-twisted-1.12/LICENSE
      573  2019-11-14 13:21   pytest-twisted-1.12/tox.ini
     1251  2019-11-14 13:21   pytest-twisted-1.12/setup.py
     8598  2019-11-14 13:21   pytest-twisted-1.12/pytest_twisted.py
        1  2019-11-14 13:32   pytest-twisted-1.12/pytest_twisted.egg-info/dependency_links.txt
     7738  2019-11-14 13:32   pytest-twisted-1.12/pytest_twisted.egg-info/PKG-INFO
      347  2019-11-14 13:32   pytest-twisted-1.12/pytest_twisted.egg-info/SOURCES.txt
       15  2019-11-14 13:32   pytest-twisted-1.12/pytest_twisted.egg-info/top_level.txt
       37  2019-11-14 13:32   pytest-twisted-1.12/pytest_twisted.egg-info/entry_points.txt
       55  2019-11-14 13:32   pytest-twisted-1.12/pytest_twisted.egg-info/requires.txt
    17895  2019-11-14 13:21   pytest-twisted-1.12/testing/test_basic.py
       36  2018-09-19 11:39   pytest-twisted-1.12/testing/conftest.py
---------                     -------
    51451                     19 files

Alrighty, so it seems that setuptools changed this 'recently' and that I was not running the latest version when I released v1.12.

pypa/setuptools#357
pypa/setuptools#1636

So theoretically this change is unneeded. But I'm good with being explicit about it.

@altendky
Copy link
Member

@scarabeusiv, thanks for caring about this and helping out. Do you need a release for something you are working on or is this just a 'this should change for the next release' sort of thing?

@altendky altendky merged commit 16abc59 into pytest-dev:master Nov 14, 2019
@scarabeusiv
Copy link
Contributor Author

We are atm grabbing the license from the git, so it is fine for us even without release.

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 this pull request may close these issues.

3 participants