I upload module
example-framework.python.egg
via Jenkins in JFrog Artifactory.
Upload completed good without errors.
I checked in Artifactory, in repository browser saw in properties
pypi.name - example-framework
Tried to install module via artifactory.
pip install example-framework
pip returned error:
Collecting example-framework
Could not find a version that satisfies the requirement example-framework (from versions: )
No matching distribution found for example-framework
How solve this problem?
For the user running pip, make sure you have correctly setup your ~/.pip/pip.conf file to point to Artifactory. You can see an example of this in the Set Me Up box for the pipy repo.
Related
I have already defined a class which I want to use in my code.
in order to import it I know I have to install it first.(I am using google's colab)
to install first I uploaded the .py file into my drive which is mounted and no problem with that.
but still there is problem with installing the package.
how can I use this predefined class correctly in my code?
!pip install robotdef.py
Collecting robotdef.py
ERROR: Could not find a version that satisfies the requirement robotdef.py (from versions: none)
ERROR: No matching distribution found for robotdef.py
I think I overlooked one thing.
If "I uploaded the .py file into my drive which is mounted and no problem with that." is the situation, you don't have to run pip, but you'll need to expand the Python path to the directory where your package(class) is installed.
I hope this may help.
import sys
sys.path.append('/foo/bar/your-modules-path')
pip fetches a package from the Python Package Index (PyPI) repository. This means that the package must be registered on the repository first.
I tried to find 'robotdef.py' or 'robotdef' using a search form on the PyPI website, but it seems that 'robotdef.py' hasn't been registered yet...
If it's on the repository, !pip install <package name> will work fine on the Colab.
Supplement
Sorry, my answer was incomplete.
It's not necessary a package to be registered on the PyPI repository, but you can install a package from local archives, etc.
This question already has answers here:
Pip install from pypi works, but from testpypi fails (cannot find requirements)
(2 answers)
Closed 2 years ago.
TL;DR Even though I've specified dependencies with install_requires in setup.py, the install through pip fails because some dependencies can't be found.
I've developed a package which I intend to distribute via PyPi. I've created a built distribution wheel and uploaded it to testPyPI to see if everything is working with the upload and if the package can be installed from a user perspective.
However, when I try to pip install the package inside a vanilla python 2.7 environment, the installation process fails while installing the dependencies.
My package depends on these packages (which I added to the setup.py file accordingly):
...
install_requires=['numpy','gdal','h5py','beautifulsoup4','requests','tables','progress'],
...
So when I run pip install, everything looks normal for a moment, until I receive this error:
Could not find a version that satisfies the requirement progress (from #NAME#) (from versions: )
No matching distribution found for progress (from #NAME#)
When I remove the progress dependency (I could live without it), same thing happens for pytables:
Could not find a version that satisfies the requirement tables (from #NAME#) (from versions: )
No matching distribution found for tables (from #NAME#)
If I run pip install tables and pip install progress manually beforehand, everything works as expected.
So how can I assure that if someone downloads my package, all missing dependencies are installed with it?
Related bonus question:
Can I include a wheel file in my package (maybe through MANIFEST.in) and install it as dependency if the module is not available? If so, how?
And I think I've found the answer to my question myself.
When installing a package from testPyPI, the dependencies are also installed from there. And it seems, that while there are many packages available, pytables and progress are apparently missing. This caused the installation to fail.
Naturally, manually installing with pip install gets the package from the "normal" PyPi, which of course works. This obviously added to my confusion.
Here's a look at the output from pip install when installing the package from the testPyPi:
Downloading https://test-files.pythonhosted.org/packages/4f/96/b3329750a04fcfc316f15f658daf6d81acc3ac61e3db390abe8954574c18/nump
y-1.9.3.tar.gz (4.0MB)
while installing the wheel directly, it looks slightly different:
Downloading https://files.pythonhosted.org/packages/2e/91/504e434d3b95d943caab926f33dee5691768fbb622bc290a0fa6df77e1d8/numpy-1.1
4.2-cp27-none-win32.whl (9.8MB)
Additionally, running
pip install --index-url https://test.pypi.org/simple/ tables
produces the same error as described in my question.
I'm having difficulty installing modules using pip for python. The exact error message is:
Could not find a version that satisfies the requirement shapefile (from versions: DistributionNotFound: No matching distribution found for shapefile
When I type:
pip install -vvv shapefile
I get a 404 status code saying:
Could not fetch URL https://pypi.python.org/simple/shapefile/: 404 Client Error
I've browsed around and have seen there is a config file that allows you to change where pip installs modules from. However, I can't find this file in my /.pip folder.
Does anyone know how I would go about fixing my pip configuration so that I can install packages?
Here is a list that matches your module name: PyPI search result for shapefile
Maybe the module is called pyshapefile not just shapefile.
pip install pyshapefile
I have been struggling with --find-links for an entire day, and I will be very grateful if sb could help me out here.
I have been developing using python3.4 and one of the new features I added uses Azure Storage( the most recent version) and it requires cryptograph, which requires cffi, idna, etc...
However, when I try to test it against Azure Webapp, the deployment failes, saying 'error : unable to find vcvarsall.bat'
With some research, I figured putting --find-links wheelhouse at the top of my requirements.txt and have wheels(cffi-1.8.2-cp34-cp34m-win32.whl (md5) and cryptography-1.5-cp34-cp34m-win32.whl (md5)) located at wheelhouse folder in the root should work. This was not helping at all, and I was running into same problems.
I tried --no-index and it gives "Could not find any downloads that satisfy the requirement cffi==1.8.2". Somebody says if I want to use --no-index, then I should have all wheels located in wheelhouse; otherwise, i will get that error.
With this, I would like to use my wheels for cffi and cryptograph and the rest download from pypi. Anyone have any clue...? HELP!
You are not the only one in that situation:
https://github.com/Azure/azure-storage-python/issues/219
It seems for an unknown reason that the version of pip on the WebApp machine does not detect the platform tag as "win32" (it's why it does not find your wheel).
Several solutions:
Move to Py3.5:
https://blogs.msdn.microsoft.com/pythonengineering/2016/08/04/upgrading-python-on-azure-app-service/
Use a deploy script to easy_install your wheel:
https://azure.microsoft.com/en-us/documentation/articles/web-sites-python-configure/#troubleshooting---package-installation
Force the version of storage to 0.32.0 in your requirements.txt file (does not require cryptography) if you don't need the latest features. Read the release note of storage 0.33.0 to figure out if you need it:
https://github.com/Azure/azure-storage-python/releases/tag/v0.33.0
SOLVED
forgot to run command
python setup.py sdist upload
I have just uploaded a python module at pypi and it has been successfully updated in pypi database. However when i try to install it through pip it throws this message :
Downloading/unpacking textprocess
Could not find any downloads that satisfy the requirement textprocess
Cleaning up...
No distributions at all found for textprocess
Storing complete log in /Users/mayankbhola/.pip/pip.log
package is hosted at : https://pypi.python.org/pypi/textprocess/0.1