zblz / naima

Derivation of non-thermal particle distributions through MCMC spectral fitting
http://naima.readthedocs.io
BSD 3-Clause "New" or "Revised" License
43 stars 54 forks source link

python setup.py install fails because distribute is not found #1

Closed cdeil closed 11 years ago

cdeil commented 11 years ago

I get this error when I try to install your package on my Mac (Python from Macports):

$ python setup.py install --user
Traceback (most recent call last):
  File "setup.py", line 9, in <module>
    distribute = pkg_resources.get_distribution('distribute')
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources.py", line 342, in get_distribution
    if isinstance(dist,Requirement): dist = get_provider(dist)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources.py", line 214, in get_provider
    return working_set.find(moduleOrReq) or require(str(moduleOrReq))[0]
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources.py", line 698, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources.py", line 597, in resolve
    raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: distribute

Maybe you have to update to the latest astropy affiliated package template infrastructure? https://github.com/astropy/package-template/blob/master/setup.py

zblz commented 11 years ago

Commit e52bb4d54bdcaa7f765f093e20f83a3dd5aa5537 should fix this issue. Can you test it again?

cdeil commented 11 years ago
$ python setup.py build
  File "setup.py", line 17
    use_setuptools()
    ^
IndentationError: unexpected indent

You need travis-ci. :-)

zblz commented 11 years ago

Indeed... check 9cfda4bbe86cdd7bd51b43a6e82fb2e3dc5eec61

cdeil commented 11 years ago

Thanks! This issue is fixed. Now I get #2 .