Closed prjemian closed 8 years ago
wrong version number when installing from PyPi correct version number when installing from local directory
prjemian@poof ~/.../eclipse/punx $ pip install .
Processing /home/prjemian/Documents/eclipse/punx
Requirement already satisfied (use --upgrade to upgrade): h5py in /home/prjemian/Apps/anaconda/lib/python2.7/site-packages (from punx==0.0.5+18.g0821e39)
Requirement already satisfied (use --upgrade to upgrade): lxml in /home/prjemian/Apps/anaconda/lib/python2.7/site-packages (from punx==0.0.5+18.g0821e39)
Requirement already satisfied (use --upgrade to upgrade): numpy in /home/prjemian/Apps/anaconda/lib/python2.7/site-packages (from punx==0.0.5+18.g0821e39)
Requirement already satisfied (use --upgrade to upgrade): pyRestTable in /home/prjemian/Apps/anaconda/lib/python2.7/site-packages (from punx==0.0.5+18.g0821e39)
Requirement already satisfied (use --upgrade to upgrade): six in /home/prjemian/Apps/anaconda/lib/python2.7/site-packages (from h5py->punx==0.0.5+18.g0821e39)
Installing collected packages: punx
Running setup.py install for punx ... done
verified the problem is with installing from PyPI on linux mint OS
PS C:\Users\Pete\Documents\eclipse\punx> pip install -U --no-deps .
Processing c:\users\pete\documents\eclipse\punx
Installing collected packages: punx
Found existing installation: punx 0.0.6
Uninstalling punx-0.0.6:
Successfully uninstalled punx-0.0.6
Running setup.py install for punx ... done
Successfully installed punx-0.0.6
PS C:\Users\Pete\Documents\eclipse\punx> pip uninstall -y punx
Uninstalling punx-0.0.6:
Successfully uninstalled punx-0.0.6
PS C:\Users\Pete\Documents\eclipse\punx> pip install punx
Collecting punx
Downloading punx-0.0.6.zip (355kB)
100% |################################| 358kB 1.2MB/s
Requirement already satisfied (use --upgrade to upgrade): h5py in d:\apps\anaconda\lib\site-packages (from punx)
Requirement already satisfied (use --upgrade to upgrade): lxml in d:\apps\anaconda\lib\site-packages (from punx)
Requirement already satisfied (use --upgrade to upgrade): numpy in d:\apps\anaconda\lib\site-packages (from punx
Requirement already satisfied (use --upgrade to upgrade): pyRestTable in d:\apps\anaconda\lib\site-packages (fro
Requirement already satisfied (use --upgrade to upgrade): Cython>=0.17 in d:\apps\anaconda\lib\site-packages (fr
>punx)
Requirement already satisfied (use --upgrade to upgrade): six in d:\apps\anaconda\lib\site-packages (from h5py->
Building wheels for collected packages: punx
Running setup.py bdist_wheel for punx ... done
Stored in directory: C:\Users\Pete\AppData\Local\pip\Cache\wheels\6b\b3\91\49595da1b372b14f10c957afe1389ca7211
2018999
Successfully built punx
Installing collected packages: punx
Successfully installed punx-0.0.6
mintadmin@mintadmin-VirtualBox ~/.../eclipse/punx $ pip install -U --no-deps .
Processing /home/mintadmin/Documents/eclipse/punx
Installing collected packages: punx
Found existing installation: punx 0-unknown
Uninstalling punx-0-unknown:
Successfully uninstalled punx-0-unknown
Running setup.py install for punx ... done
Successfully installed punx-0.0.6
mintadmin@mintadmin-VirtualBox ~/.../eclipse/punx $ pip uninstall -y punx
Uninstalling punx-0.0.6:
Successfully uninstalled punx-0.0.6
mintadmin@mintadmin-VirtualBox ~/.../eclipse/punx $ pip install punx
Collecting punx
Downloading punx-0.0.6.zip (355kB)
100% |¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦| 358kB 3.5MB/s
Requirement already satisfied (use --upgrade to upgrade): h5py in /home/mintadmin/Apps/anaconda/lib/python2.7/site-packages (from punx)
Requirement already satisfied (use --upgrade to upgrade): lxml in /home/mintadmin/Apps/anaconda/lib/python2.7/site-packages (from punx)
Requirement already satisfied (use --upgrade to upgrade): numpy in /home/mintadmin/Apps/anaconda/lib/python2.7/site-packages (from punx)
Requirement already satisfied (use --upgrade to upgrade): pyRestTable in /home/mintadmin/Apps/anaconda/lib/python2.7/site-packages (from punx)
Requirement already satisfied (use --upgrade to upgrade): six in /home/mintadmin/Apps/anaconda/lib/python2.7/site-packages (from h5py->punx)
Building wheels for collected packages: punx
Running setup.py bdist_wheel for punx ... done
Stored in directory: /home/mintadmin/.cache/pip/wheels/6b/b3/91/49595da1b372b14f10c957afe1389ca7211465d80022018999
Successfully built punx
Installing collected packages: punx
Successfully installed punx-0-unknown
The problem is in the wheel on PyPI
prjemian@enoki /tmp/prj/punx-0+unknown.dist-info $ ll
total 40K
-rw-rw-r-- 1 prjemian prjemian 667 Jun 22 2016 DESCRIPTION.rst
-rw-rw-r-- 1 prjemian prjemian 41 Jun 22 2016 entry_points.txt
-rw-rw-r-- 1 prjemian prjemian 2.0K Jun 22 2016 METADATA
-rw-rw-r-- 1 prjemian prjemian 1.6K Jun 22 2016 metadata.json
-rw-rw-r-- 1 prjemian prjemian 14K Jun 22 2016 RECORD
-rw-rw-r-- 1 prjemian prjemian 5 Jun 22 2016 top_level.txt
-rw-rw-r-- 1 prjemian prjemian 93 Jun 22 2016 WHEEL
prjemian@enoki /tmp/prj/punx-0+unknown.dist-info $ more top_level.txt
punx
prjemian@enoki /tmp/prj/punx-0+unknown.dist-info $ more WHEEL
Wheel-Version: 1.0
Generator: bdist_wheel (0.29.0)
Root-Is-Purelib: true
Tag: cp27-none-any
prjemian@enoki /tmp/prj/punx-0+unknown.dist-info $ more metadata.json
{"classifiers": ["Development Status :: 3 - Alpha", "Environment :: Console", "Intended Audience :: Science/Research", "License :: Fre
ely Distributable", "License :: Public Domain", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming
Language :: Python :: 2.7", "Topic :: Scientific/Engineering", "Topic :: Scientific/Engineering :: Astronomy", "Topic :: Scientific/En
gineering :: Bio-Informatics", "Topic :: Scientific/Engineering :: Chemistry", "Topic :: Scientific/Engineering :: Information Analysi
s", "Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator", "Topic :: Scientific/Engineering :: Mathematics", "Topi
c :: Scientific/Engineering :: Physics", "Topic :: Scientific/Engineering :: Visualization", "Topic :: Software Development", "Topic :
: Utilities"], "extensions": {"python.commands": {"wrap_console": {"punx": "punx.main:main"}}, "python.details": {"contacts": [{"email
": "prjemian@gmail.com", "name": "Pete R. Jemian", "role": "author"}], "document_names": {"description": "DESCRIPTION.rst"}, "project_
urls": {"Home": "http://punx.readthedocs.io"}}, "python.exports": {"console_scripts": {"punx": "punx.main:main"}}}, "extras": [], "gen
erator": "bdist_wheel (0.29.0)", "keywords": ["NeXus", "HDF5"], "license": "Creative Commons Attribution 4.0 International Public Lice
nse (see LICENSE file)", "metadata_version": "2.0", "name": "punx", "platform": "any", "run_requires": [{"requires": ["h5py", "lxml",
"numpy", "pyRestTable"]}], "summary": "Python Utilities for NeXus", "version": "0+unknown"}
prjemian@enoki /tmp/prj/punx-0+unknown.dist-info $ cd ..
prjemian@enoki /tmp/prj $ ll
total 336K
drwxrwxr-x 4 prjemian prjemian 4.0K Jun 22 15:07 punx/
drwxrwxr-x 2 prjemian prjemian 4.0K Jun 22 15:07 punx-0+unknown.dist-info/
-rw-rw-r-- 1 prjemian prjemian 328K Jun 22 15:06 p.zip
prjemian@enoki /tmp/prj $
Versioneer re-writes the _version.py file with specific version info. In the packaging process, looks like it had problems:
prjemian@enoki /tmp/prj $ more punx/_version.py
# This file was generated by 'versioneer.py' (0.15) from
# revision-control system data, or from the parent directory name of an
# unpacked source archive. Distribution tarballs contain a pre-generated copy
# of this file.
import json
import sys
version_json = '''
{
"dirty": null,
"error": "unable to compute version",
"full-revisionid": null,
"version": "0+unknown"
}
''' # END VERSION_JSON
def get_versions():
return json.loads(version_json)
consider alternative to versioneer, as used in https://github.com/prjemian/pyRestTable/blob/master/src/pyRestTable/__init__.py