pip install ok, but "insecure and unverifiable files" on travis.ci - python

I created and uploaded a package callled pdfminer.six on PyPi
It installs correctly through "pip install pdfminer.six" on my PC (Windows)
and passes tests on travis-ci
Since I need this package for my other project (Goulib), I added "pdfminer.six" it to its requirements.txt, but Travis.ci fails importing this package ) :
Downloading/unpacking pdfminer.six (from -r requirements.txt (line 7))
Could not find any downloads that satisfy the requirement pdfminer.six
(from -r requirements.txt (line 7)) Some insecure and unverifiable
files were ignored (use --allow-unverified pdfminer.six to allow).
Cleaning up... No distributions at all found for pdfminer.six (from -r
requirements.txt (line 7))
Tried to add --allow-unverified and version number ==20140915 in all possible ways, no change ...
What should I do to make pdfminer.six "secure and verifiable" on Travis-ci ?

Related

ERROR: Could not find a version that satisfies the requirement apturl==0.5.2 (from versions: none)-- [duplicate]

I am currently trying to install a requirements and it is telling me that it is not found when I try and comment them out it happens for others.
I just deployed a Ubuntu 18.04 server. Made the virtual env by the following command python3 -m venv --system-site-packages env but every single time I try and run pip install -r requirements.txt it fails with
Collecting apparmor==2.12 (from -r requirements.txt (line 1))
Could not find a version that satisfies the requirement apparmor==2.12 (from -r requirements.txt (line 1)) (from versions: )
No matching distribution found for apparmor==2.12 (from -r requirements.txt (line 1))
if I try and install say pip install apparmor it tells me
Collecting apparmor
Could not find a version that satisfies the requirement apparmor (from versions: )
No matching distribution found for apparmor
But then if I comment out apparmor it tells me this
Collecting apturl==0.5.2 (from -r requirements.txt (line 2))
Could not find a version that satisfies the requirement apturl==0.5.2 (from -r requirements.txt (line 2)) (from versions: )
No matching distribution found for apturl==0.5.2 (from -r requirements.txt (line 2))
and it goes on for others randomly. The requirements was made on my local which is also ubuntu 18 so unsure why this works on local but not on a new deploy.
I have also made sure that it's the newest version of pip
apparmor and apturl are Ubuntu packages, you can safely ignore them if your code doesn't use their code; just remove them from requirements.txt. If your code depends on them, ensure they are installed via apt:
apt install -y apparmor apturl && pip install -r requirements.txt
This is a common problem when you don't use virtual enviroment for work with python, so your requirements.txt lists all the packages pythons of your system or OS, when you must have only the packages from your project. In some moment you update your requirements.txt with pip freeze > requirements.txt, without a virtual environment and you updated the requirements.txt with all python packages in your OS and from your project, and maybe uploaded to a repository. So when you want to run in another computer and install all packages you got this kind of error...
Python is installed by default in ubuntu, you must consider this and in other system too.
First rule is work every time with virtual enviroment "virtual env documentation"
I know it's hard work, but you can backup that requirements.txt and clean it. Then try to run your program without any package (a clean install) and when errors occurs from missing packages you add it and update with pip freeze > requirements.txt

Python library can be found in PyPi but can't be installed by 'pip install'

I got django project code and tried to install all the requirements by 'pip install -r requiremets.txt' but somehow it doesn't work.
occurred error is below
Could not find a version that satisfies the requirement mkl-fft==1.0.9 (from -r requirements.txt (line 14)) (from versions: 1.0.0.17, 1.0.2, 1.0.6)
No matching distribution found for mkl-fft==1.0.9 (from -r requirements.txt (line 14))
I tried to upgrade pip but it didnt work.
I should change my question..
I just tried 'pip install mkl-fft' and it worked.. still don't know why 'pip install -r requirements.txt' doesn't work.
Latest version of your package mkl-fft is 1.0.6 but you tried out mkl-fft==1.0.9
refer this link
you can change your version in requirements.txt file and run 'pip install -r requiremets.txt' it will works.

How to get mod_wsgi-express from pip using Dockerfile

I can't recall how I installed mod_wsgi-express, but I'm almost certain that I used pip.
I've got this line in my requirements.txt file:
mod_wsgi-express==4.5.15
Collecting mod_wsgi-express==4.5.15 (from -r /usr/src/app/requirements.txt (line 16))
Could not find a version that satisfies the requirement mod_wsgi-express==4.5.15 (from -r /usr/src/app/requirements.txt (line 16)) (from versions: )
No matching distribution found for mod_wsgi-express==4.5.15 (from -r /usr/src/app/requirements.txt (line 16))
You are using pip version 9.0.0, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Is the naming different here? Or am I just not seeing that package?
$ pip list | grep mod
mod-wsgi (4.5.15)
mod-wsgi-httpd (2.4.23.2)
In requirements.txt: mod_wsgi==4.5.15
The package information can be found on PyPi at:
https://pypi.python.org/pypi/mod_wsgi

Unable to install python packages from remote repo

I am trying to download deendencies from artifactory in the fllowing way
requirements.txt
--index-url https://artifactory.company.com/artifactory/api/pypi/pypi-repos
django-rss-plugin==0.0.9
nltk==3.0.1
And then running
pip install -r requirements.txt
This results in the follwoing error
Collecting django-rss-plugin==0.0.9 (from -r requirements.txt (line 3))
Could not find a version that satisfies the requirement django-rss-plugin==0.0.9 (from -r requirements.txt (line 3)) (from versions: )
No matching distribution found for django-rss-plugin==0.0.9 (from -r requirements.txt (line 3))
This is true for any dependency. I am using the version 9.0.1 for pip.Also https://artifactory.company.com/artifactory/api/pypi/pypi-repos is the virtual repository that proxies the remote repo
You can specify the index in your command and remove from the file:
pip install -r requirement.txt -i https://artifactory.company.com/artifactory/api/pypi/pypi-repos
File:
django-rss-plugin==0.0.9
nltk==3.0.1
EDIT
The error is from the index URL itself.

Pip Wheel and coverage: command not found error

I want to use wheels on my Linux server as it seems much faster, but when I do:
pip install wheel
pip wheel -r requirements_dev.txt
Which contains the following packages
nose
django_coverage
coverage
I get coverage: command not found, it's like it is not being installed.
Is there a fallback if a wheel is not found to pip install or have I not understood/setup this correctly?
Can you try this?
virtualenv venv
source venv/bin/activate
pip -r install requirement.txt
Also getting this with using wheel:-
pip wheel -r check.txt
Collecting nose (from -r check.txt (line 1))
Using cached nose-1.3.7-py2-none-any.whl
Saved ./nose-1.3.7-py2-none-any.whl
Collecting django_coverage (from -r check.txt (line 2))
Saved ./django_coverage-1.2.4-cp27-none-any.whl
Collecting coverage (from -r check.txt (line 3))
Using cached coverage-4.2-cp27-cp27m-macosx_10_10_x86_64.whl
Saved ./coverage-4.2-cp27-cp27m-macosx_10_10_x86_64.whl
Skipping nose, due to already being wheel.
Skipping django-coverage, due to already being wheel.
Skipping coverage, due to already being wheel.
Installing from wheels is what pip already does by default. pip wheel is for creating wheels from your requirements file.

Categories

Resources