phac-nml / sistr_cmd

SISTR (Salmonella In Silico Typing Resource) command-line tool
Apache License 2.0
25 stars 9 forks source link

Pip install does not work #11

Closed andersgs closed 7 years ago

andersgs commented 8 years ago

Here is the output for pip install -vvv sistr-cmd:

Collecting sistr-cmd
  1 location(s) to search for versions of sistr-cmd:
  * https://pypi.python.org/simple/sistr-cmd/
  Getting page https://pypi.python.org/simple/sistr-cmd/
  Looking up "https://pypi.python.org/simple/sistr-cmd/" in the cache
  Current age based on date: 325
  Freshness lifetime from max-age: 600
  Freshness lifetime from request max-age: 600
  The response is "fresh", returning cached response
  600 > 325
  Analyzing links from page https://pypi.python.org/simple/sistr-cmd/
  Could not find a version that satisfies the requirement sistr-cmd (from versions: )
Cleaning up...
No matching distribution found for sistr-cmd
Exception information:
Traceback (most recent call last):
  File "/home/linuxbrew/.linuxbrew/Cellar/python/2.7.12_1/lib/python2.7/site-packages/pip/basecommand.py", line 215, in main
    status = self.run(options, args)
  File "/home/linuxbrew/.linuxbrew/Cellar/python/2.7.12_1/lib/python2.7/site-packages/pip/commands/install.py", line 310, in run
    wb.build(autobuilding=True)
  File "/home/linuxbrew/.linuxbrew/Cellar/python/2.7.12_1/lib/python2.7/site-packages/pip/wheel.py", line 750, in build
    self.requirement_set.prepare_files(self.finder)
  File "/home/linuxbrew/.linuxbrew/Cellar/python/2.7.12_1/lib/python2.7/site-packages/pip/req/req_set.py", line 370, in prepare_files
    ignore_dependencies=self.ignore_dependencies))
  File "/home/linuxbrew/.linuxbrew/Cellar/python/2.7.12_1/lib/python2.7/site-packages/pip/req/req_set.py", line 522, in _prepare_file
    finder, self.upgrade, require_hashes)
  File "/home/linuxbrew/.linuxbrew/Cellar/python/2.7.12_1/lib/python2.7/site-packages/pip/req/req_install.py", line 268, in populate_link
    self.link = finder.find_requirement(self, upgrade)
  File "/home/linuxbrew/.linuxbrew/Cellar/python/2.7.12_1/lib/python2.7/site-packages/pip/index.py", line 491, in find_requirement
    'No matching distribution found for %s' % req
DistributionNotFound: No matching distribution found for sistr-cmd

My guess it has something to do with the fact that the package is registered as sister-cmd but in setup.py it is called sistr_cmd (note the different use of - and _).

Note this inconsistent use of - and _ seems appear throughout the README too.

Cheers.

Anders.

peterk87 commented 8 years ago

Hi Anders,

I uploaded the source build to PyPI, but shortly afterwards it was removed without notification. I haven't been able to find any info about it on the PyPI website or elsewhere on the web. I also can't re-upload the files I had uploaded. I get an error saying "This filename has previously been used, you should use a different version."

When I make a new release, I'll upload it to PyPI, but one workaround for now is to install directly from the github repo:

pip install git+https://github.com/peterk87/sistr_cmd.git@0.1.1

Hope that helps!

peterk87 commented 7 years ago

sistr_cmd can now be installed using pip (https://pypi.python.org/pypi/sistr-cmd) or conda (https://bioconda.github.io/recipes/sistr_cmd/README.html)