I'm trying to install my package using pip from github repository. All actions i do in venv (w/ --no-site-packages).
In package i use pbr. I can't install one of my requirements that located in private repository (i use ssh link), i'm getting strange message:
Requirement already satisfied: python>=lpcclient in
/usr/lib/python2.7/lib-dynload (from ansible-lpc-
modules==0.0.1.dev168)
setup.py:
from setuptools import setup
setup(setup_requires=['pbr>=1.8'], pbr=True)
setup.cfg:
[metadata]
name = ansible-lpc-modules
author = Petr
version = 0.0.1
classifier =
Environment :: OpenStack
Intended Audience :: Information Technology
Intended Audience :: System Administrators
Development Status :: In Progress
Operating System :: POSIX :: Linux
Programming Language :: Python
Programming Language :: Python :: 2.7
[pbr]
skip_authors = True
skip_changelog = True
[files]
packages =
ansible/modules/lpc_mdls
ansible/module_utils/lpc_utils
requirements.txt:
ansible
-e git+ssh://git#git.lpc.org/vpc/python-lpcclient.git#develop#egg=python-lpcclient
What i do wrong? I don't have 'lpcclient' installed globally.
Related
I'm trying to create my first python package. To not bungle the whole deal, I've been attempting to upload it to the testpypi servers. That seems to go fine (sdist creates and upload doesn't show any errors). However, when I try to install it to a new virtualenv from https://testpypi.python.org/pypi, it complains about my install requirements, e.g.:
pip install -i https://testpypi.python.org/pypi poirot
Collecting poirot
Downloading https://testpypi.python.org/packages/source/p/poirot/poirot-0.0.15.tar.gz
Collecting tqdm==3.4.0 (from poirot)
Could not find a version that satisfies the requirement tqdm==3.4.0 (from poirot) (from versions: )
No matching distribution found for tqdm==3.4.0 (from poirot)
tqdm and Jinja2 are my only requirements. I tried specifying the versions, not specifying—error each way.
It appears that it's trying to find tqdm and Jinja2 on the testpypi server and not finding them (because they're only available at regular pypi). Uploading the package to the non-test server and running pip install worked.
What do I need to add to the setup.py file (below) to get it to find the requirements when uploaded to testpypi?
Thanks!
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
setup(name='poirot',
version='0.0.15',
description="Search a git repository's revision history for text patterns.",
url='https://github.com/dcgov/poirot',
license='https://raw.githubusercontent.com/DCgov/poirot/master/LICENSE.md',
packages=['poirot'],
install_requires=['tqdm==3.4.0', 'Jinja2==2.8'],
test_suite='nose.collector',
tests_require=['nose-progressive'],
classifiers=[
'Environment :: Console',
'Intended Audience :: Developers',
'Programming Language :: Python',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5'
],
include_package_data=True,
scripts=['bin/big-grey-cells', 'bin/little-grey-cells'],
zip_safe=False)
Update
PyPI has upgraded its site. According to the docs, the new advice is:
python -m pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple poirot
--index-url points to your package on TestPyPI.
--extra-index-url points to dependencies on PyPI.
poirot is your package.
Caution: despite this recommendation from the official docs, using --extra-index-url can be unsafe in certain situations, particularly on private servers. See also A. Sottile's video demonstrating the risks related to option ordering and mixing public with private PyPI servers. Use with caution and assess your own risks.
Out-dated
Try pip install --extra-index-url https://testpypi.python.org/pypi poirot.
See also a reference post.
Trying in Jan 2021, the update in the accepted answer didn't work for me. This worked:
pip install -i https://test.pypi.org/pypi/ --extra-index-url https://pypi.org/simple <your_package_in_testpypi>
Note that the first URL is test.pypi.org/pypi, and the second is pypi.org/simple.
Their official page should be updated, its instruction shows:
pip install -i https://test.pypi.org/simple/ <your_package_in_testpypi>
which does not work.
I'm trying to create my first python package. To not bungle the whole deal, I've been attempting to upload it to the testpypi servers. That seems to go fine (sdist creates and upload doesn't show any errors). However, when I try to install it to a new virtualenv from https://testpypi.python.org/pypi, it complains about my install requirements, e.g.:
pip install -i https://testpypi.python.org/pypi poirot
Collecting poirot
Downloading https://testpypi.python.org/packages/source/p/poirot/poirot-0.0.15.tar.gz
Collecting tqdm==3.4.0 (from poirot)
Could not find a version that satisfies the requirement tqdm==3.4.0 (from poirot) (from versions: )
No matching distribution found for tqdm==3.4.0 (from poirot)
tqdm and Jinja2 are my only requirements. I tried specifying the versions, not specifying—error each way.
It appears that it's trying to find tqdm and Jinja2 on the testpypi server and not finding them (because they're only available at regular pypi). Uploading the package to the non-test server and running pip install worked.
What do I need to add to the setup.py file (below) to get it to find the requirements when uploaded to testpypi?
Thanks!
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
setup(name='poirot',
version='0.0.15',
description="Search a git repository's revision history for text patterns.",
url='https://github.com/dcgov/poirot',
license='https://raw.githubusercontent.com/DCgov/poirot/master/LICENSE.md',
packages=['poirot'],
install_requires=['tqdm==3.4.0', 'Jinja2==2.8'],
test_suite='nose.collector',
tests_require=['nose-progressive'],
classifiers=[
'Environment :: Console',
'Intended Audience :: Developers',
'Programming Language :: Python',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5'
],
include_package_data=True,
scripts=['bin/big-grey-cells', 'bin/little-grey-cells'],
zip_safe=False)
Update
PyPI has upgraded its site. According to the docs, the new advice is:
python -m pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple poirot
--index-url points to your package on TestPyPI.
--extra-index-url points to dependencies on PyPI.
poirot is your package.
Caution: despite this recommendation from the official docs, using --extra-index-url can be unsafe in certain situations, particularly on private servers. See also A. Sottile's video demonstrating the risks related to option ordering and mixing public with private PyPI servers. Use with caution and assess your own risks.
Out-dated
Try pip install --extra-index-url https://testpypi.python.org/pypi poirot.
See also a reference post.
Trying in Jan 2021, the update in the accepted answer didn't work for me. This worked:
pip install -i https://test.pypi.org/pypi/ --extra-index-url https://pypi.org/simple <your_package_in_testpypi>
Note that the first URL is test.pypi.org/pypi, and the second is pypi.org/simple.
Their official page should be updated, its instruction shows:
pip install -i https://test.pypi.org/simple/ <your_package_in_testpypi>
which does not work.
I'm trying to create my first python package. To not bungle the whole deal, I've been attempting to upload it to the testpypi servers. That seems to go fine (sdist creates and upload doesn't show any errors). However, when I try to install it to a new virtualenv from https://testpypi.python.org/pypi, it complains about my install requirements, e.g.:
pip install -i https://testpypi.python.org/pypi poirot
Collecting poirot
Downloading https://testpypi.python.org/packages/source/p/poirot/poirot-0.0.15.tar.gz
Collecting tqdm==3.4.0 (from poirot)
Could not find a version that satisfies the requirement tqdm==3.4.0 (from poirot) (from versions: )
No matching distribution found for tqdm==3.4.0 (from poirot)
tqdm and Jinja2 are my only requirements. I tried specifying the versions, not specifying—error each way.
It appears that it's trying to find tqdm and Jinja2 on the testpypi server and not finding them (because they're only available at regular pypi). Uploading the package to the non-test server and running pip install worked.
What do I need to add to the setup.py file (below) to get it to find the requirements when uploaded to testpypi?
Thanks!
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
setup(name='poirot',
version='0.0.15',
description="Search a git repository's revision history for text patterns.",
url='https://github.com/dcgov/poirot',
license='https://raw.githubusercontent.com/DCgov/poirot/master/LICENSE.md',
packages=['poirot'],
install_requires=['tqdm==3.4.0', 'Jinja2==2.8'],
test_suite='nose.collector',
tests_require=['nose-progressive'],
classifiers=[
'Environment :: Console',
'Intended Audience :: Developers',
'Programming Language :: Python',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5'
],
include_package_data=True,
scripts=['bin/big-grey-cells', 'bin/little-grey-cells'],
zip_safe=False)
Update
PyPI has upgraded its site. According to the docs, the new advice is:
python -m pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple poirot
--index-url points to your package on TestPyPI.
--extra-index-url points to dependencies on PyPI.
poirot is your package.
Caution: despite this recommendation from the official docs, using --extra-index-url can be unsafe in certain situations, particularly on private servers. See also A. Sottile's video demonstrating the risks related to option ordering and mixing public with private PyPI servers. Use with caution and assess your own risks.
Out-dated
Try pip install --extra-index-url https://testpypi.python.org/pypi poirot.
See also a reference post.
Trying in Jan 2021, the update in the accepted answer didn't work for me. This worked:
pip install -i https://test.pypi.org/pypi/ --extra-index-url https://pypi.org/simple <your_package_in_testpypi>
Note that the first URL is test.pypi.org/pypi, and the second is pypi.org/simple.
Their official page should be updated, its instruction shows:
pip install -i https://test.pypi.org/simple/ <your_package_in_testpypi>
which does not work.
I'm trying to create my first python package. To not bungle the whole deal, I've been attempting to upload it to the testpypi servers. That seems to go fine (sdist creates and upload doesn't show any errors). However, when I try to install it to a new virtualenv from https://testpypi.python.org/pypi, it complains about my install requirements, e.g.:
pip install -i https://testpypi.python.org/pypi poirot
Collecting poirot
Downloading https://testpypi.python.org/packages/source/p/poirot/poirot-0.0.15.tar.gz
Collecting tqdm==3.4.0 (from poirot)
Could not find a version that satisfies the requirement tqdm==3.4.0 (from poirot) (from versions: )
No matching distribution found for tqdm==3.4.0 (from poirot)
tqdm and Jinja2 are my only requirements. I tried specifying the versions, not specifying—error each way.
It appears that it's trying to find tqdm and Jinja2 on the testpypi server and not finding them (because they're only available at regular pypi). Uploading the package to the non-test server and running pip install worked.
What do I need to add to the setup.py file (below) to get it to find the requirements when uploaded to testpypi?
Thanks!
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
setup(name='poirot',
version='0.0.15',
description="Search a git repository's revision history for text patterns.",
url='https://github.com/dcgov/poirot',
license='https://raw.githubusercontent.com/DCgov/poirot/master/LICENSE.md',
packages=['poirot'],
install_requires=['tqdm==3.4.0', 'Jinja2==2.8'],
test_suite='nose.collector',
tests_require=['nose-progressive'],
classifiers=[
'Environment :: Console',
'Intended Audience :: Developers',
'Programming Language :: Python',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5'
],
include_package_data=True,
scripts=['bin/big-grey-cells', 'bin/little-grey-cells'],
zip_safe=False)
Update
PyPI has upgraded its site. According to the docs, the new advice is:
python -m pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple poirot
--index-url points to your package on TestPyPI.
--extra-index-url points to dependencies on PyPI.
poirot is your package.
Caution: despite this recommendation from the official docs, using --extra-index-url can be unsafe in certain situations, particularly on private servers. See also A. Sottile's video demonstrating the risks related to option ordering and mixing public with private PyPI servers. Use with caution and assess your own risks.
Out-dated
Try pip install --extra-index-url https://testpypi.python.org/pypi poirot.
See also a reference post.
Trying in Jan 2021, the update in the accepted answer didn't work for me. This worked:
pip install -i https://test.pypi.org/pypi/ --extra-index-url https://pypi.org/simple <your_package_in_testpypi>
Note that the first URL is test.pypi.org/pypi, and the second is pypi.org/simple.
Their official page should be updated, its instruction shows:
pip install -i https://test.pypi.org/simple/ <your_package_in_testpypi>
which does not work.
This question already has answers here:
Pip install from pypi works, but from testpypi fails (cannot find requirements)
(2 answers)
Closed 2 years ago.
I am building a Python package and my package has some install requirements. This is my setup.py file code:
import setuptools
with open("README.md", "r") as fh:
long_description = fh.read()
setuptools.setup(
name="simpleEDA",
version="0.0.1",
author="Muhammad Shahid Sharif",
author_email="chshahidhamdam#gmail.com",
description="A wrapper around Pandas to perform Simple EDA with less code.",
long_description=long_description,
long_description_content_type="text/markdown",
url="github link here",
packages=['simple_eda'],
install_requires = ['matplotlib',
'numpy',
'numpydoc',
'pandas',
'scikit-image',
'scikit-learn',
'scipy',
'seaborn'],
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independen.t",
],
python_requires='>=3.5',
)
I have created the whl file and uploaded it on test PyPI. here is the link
pip install -i https://test.pypi.org/simple/ simpleEDA==0.0.1
If I try to install it, it gives me this error.
Could not find a version that satisfies the requirement numpydoc (from simpleEDA==0.0.1) (from versions: )
No matching distribution found for numpydoc (from simpleEDA==0.0.1)
Why is my install_requires is not working? Why it is not installing libraries?
You're attempting to install using TestPyPI as the index:
pip install -i https://test.pypi.org/simple/ simpleEDA==0.0.1
However most of your subdependencies don't exist on TestPyPI, for example https://test.pypi.org/project/numpydoc/ is 404.
Depending on what you're using TestPyPI for, you might be better off making a pre-release on PyPI instead.