pip3 cannot install packages - cannot find a version on embedded system

1

1

I'm running python pip3 on TinkerOS (for Asus embedded computer Tinkerboard). TinkerOS is based on Debian.

linaro@chione:~$ uname -a
Linux chione 4.4.132+ #1 SMP Tue Oct 23 18:03:49 CST 2018 armv7l GNU/Linux 

linaro@chione:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 9.11 (stretch)
Release:        9.11
Codename:       stretch 

Unfortunately, I cannot install any packages using pip3. Here is the error.

linaro@chione:~$ sudo pip3 install pyserial
Collecting pyserial
  Could not find a version that satisfies the requirement pyserial (from versions: )
No matching distribution found for pyserial

This is the same error for all packages with pip. Another example is given below.

linaro@chione:~$ sudo pip3 install wheel 0.33.6
Collecting wheel
  Could not find a version that satisfies the requirement wheel (from versions: )
No matching distribution found for wheel

I've tried removing and purging pip and python3 using apt-get but the errors still persist. What is happening here?

Also, trying to install a package such as pyserial from git does not work well either.

linaro@chione:~/install$ git clone https://github.com/pyserial/pyserial.git
Cloning into 'pyserial'...
fatal: unable to access 'https://github.com/pyserial/pyserial.git/': server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none

Nicholas Kinar

Posted 2020-01-20T16:30:04.877

Reputation: 131

Answers

1

It turns out that the date of the sytem was set to a time in the past.

linaro@chione:~/install$ date -R
Thu, 03 Nov 2016 11:29:19 -0600

This was fixed with:

sudo apt-get install ntp

Now, the time is okay:

linaro@chione:~/install$ date
Mon Jan 20 10:47:07 CST 2020

In addition, pip now works:

linaro@chione:~/install$ sudo pip3 install wheel
Collecting wheel
  Downloading https://files.pythonhosted.org/packages/00/83/b4a77d044e78ad1a45610eb88f745be2fd2c6d658f9798a15e384b7d57c9/wheel-0.33.6-py2.py3-none-any.whl
Installing collected packages: wheel
Successfully installed wheel-0.33.6

This appears to be a problem with certificates and the time that has been set.

Nicholas Kinar

Posted 2020-01-20T16:30:04.877

Reputation: 131