1

I have created a python module, i2cdev.

When I try to install it through pip, I get that it cannot find it:

$ pip3 search "i2cdev"  # finds it fine
i2cdev                    - Simple I2C Library for linux
$ pip3 install i2cdev
Collecting i2cdev
  Could not find any downloads that satisfy the requirement i2cdev
  No distributions at all found for i2cdev

What is going on?

vitiral
  • 8,446
  • 8
  • 29
  • 43

2 Answers2

4

wow, I'm an idiot. Apparently you have to use setup.py sdist upload to actually upload the code onto python. I thought just registering it was enough.

vitiral
  • 8,446
  • 8
  • 29
  • 43
2

You have to setup download link for the tarball/zip file which is uploaded.You can check it by

http://pypi.python.org/simple/<package name>

Because pip searches in this above url.If There is no download links, You have to add download_link as metadata.That is something like

in setup.py

setup(...,
     download_url = 'http://pypi/path/to/package.tar.gz',

     )

I found out, your's is

https://pypi.python.org/packages/source/i/i2cdev/i2cdev-1.2.4.tar.gz
itzMEonTV
  • 19,851
  • 4
  • 39
  • 49
  • I wonder if this would have worked as well... I think the solution I posted is the best though because it will keep track of version information. Thanks though! – vitiral Mar 23 '15 at 22:45