Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pip install pendulum fails on raspbery pi 4 (arm7) #504

Open
2 tasks done
Fabs opened this issue Oct 16, 2020 · 13 comments
Open
2 tasks done

pip install pendulum fails on raspbery pi 4 (arm7) #504

Fabs opened this issue Oct 16, 2020 · 13 comments
Labels
Packaging Related to system-specific package building issues.

Comments

@Fabs
Copy link

Fabs commented Oct 16, 2020

  • I am on the latest Pendulum version.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • OS version and name: Linux pi 5.4.51-v7l+ #1333 SMP armv7l GNU/Linux
  • Pendulum version: 2.1.2

Issue

Can't install it on raspbery pi 4.

(venv) pi@pi:~/lunos/samurai $ uname -a
Linux pi 5.4.51-v7l+ #1333 SMP Mon Aug 10 16:51:40 BST 2020 armv7l GNU/Linux
(venv) pi@pi:~/lunos/samurai $ python --version
Python 3.7.3
(venv) pi@pi:~/lunos/samurai $ pip --version
pip 18.1 from /home/pi/lunos/samurai/venv/lib/python3.7/site-packages/pip (python 3.7)
(venv) pi@pi:~/lunos/samurai $ pip install pendulum
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting pendulum
  Using cached https://files.pythonhosted.org/packages/db/15/6e89ae7cde7907118769ed3d2481566d05b5fd362724025198bb95faf599/pendulum-2.1.2.tar.gz
  Installing build dependencies ... done
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/usr/lib/python3.7/tokenize.py", line 447, in open
        buffer = _builtin_open(filename, 'rb')
    FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pip-install-1d2npdqh/pendulum/setup.py'
    
    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-1d2npdqh/pendulum/
@ner0tic
Copy link

ner0tic commented Nov 1, 2020

I also encountered this problem.

 $ uname -a
Linux powerPi 4.19.75-v7+ #1270 SMP Tue Sep 24 18:45:11 BST 2019 armv7l GNU/Linux
$ python3 -m pip --version
pip 20.2.4 from /home/pi/.local/lib/python3.7/site-packages/pip (python 3.7)
 $ python3 --version
Python 3.7.3
$ sudo python3 -m pip install pendulum
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting pendulum
  Using cached https://files.pythonhosted.org/packages/db/15/6e89ae7cde7907118769ed3d2481566d05b5fd362724025198bb95faf599/pendulum-2.1.2.tar.gz
  Installing build dependencies ... done
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/usr/lib/python3.7/tokenize.py", line 447, in open
        buffer = _builtin_open(filename, 'rb')
    FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pip-install-i7fjc_45/pendulum/setup.py'
    
    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-i7fjc_45/pendulum/

My current installation workaround.

$ sudo python3 -m pip install pendulum==2.1.1
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting pendulum==2.1.1
  Downloading https://files.pythonhosted.org/packages/9a/0d/e503011d347e2d41f4fb05c6b3d7fbfcc8b2c25baba13e1804597e7d2412/pendulum-2.1.1.tar.gz (84kB)
    100% |████████████████████████████████| 92kB 297kB/s 
  Installing build dependencies ... done
Collecting python-dateutil<3.0,>=2.6 (from pendulum==2.1.1)
  Downloading https://files.pythonhosted.org/packages/d4/70/d60450c3dd48ef87586924207ae8907090de0b306af2bce5d134d78615cb/python_dateutil-2.8.1-py2.py3-none-any.whl (227kB)
    100% |████████████████████████████████| 235kB 285kB/s 
Collecting pytzdata>=2020.1 (from pendulum==2.1.1)
  Downloading https://files.pythonhosted.org/packages/e0/4f/4474bda990ee740a020cbc3eb271925ef7daa7c8444240d34ff62c8442a3/pytzdata-2020.1-py2.py3-none-any.whl (489kB)
    100% |████████████████████████████████| 491kB 210kB/s 
Requirement already satisfied: six>=1.5 in /usr/lib/python3/dist-packages (from python-dateutil<3.0,>=2.6->pendulum==2.1.1) (1.12.0)
Building wheels for collected packages: pendulum
  Running setup.py bdist_wheel for pendulum ... done
  Stored in directory: /root/.cache/pip/wheels/f4/11/39/94053df467afd002cf669ac033b9cc1f1f33e6f4e97a02475c
Successfully built pendulum
Installing collected packages: python-dateutil, pytzdata, pendulum
Successfully installed pendulum-2.1.1 python-dateutil-2.8.1 pytzdata-2020.1

$ python3 -m pip install pendulum --upgrade
Defaulting to user installation because normal site-packages is not writeable
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting pendulum
  Downloading https://www.piwheels.org/simple/pendulum/pendulum-2.1.2-cp37-cp37m-manylinux2014_armv7l.whl (168 kB)
     |████████████████████████████████| 168 kB 106 kB/s 
Requirement already satisfied, skipping upgrade: pytzdata>=2020.1 in /usr/local/lib/python3.7/dist-packages (from pendulum) (2020.1)
Requirement already satisfied, skipping upgrade: python-dateutil<3.0,>=2.6 in /usr/local/lib/python3.7/dist-packages (from pendulum) (2.8.1)
Requirement already satisfied, skipping upgrade: six>=1.5 in /home/pi/.local/lib/python3.7/site-packages (from python-dateutil<3.0,>=2.6->pendulum) (1.15.0)
Installing collected packages: pendulum
Successfully installed pendulum-2.1.2

@mghurd
Copy link

mghurd commented Nov 11, 2020

This workaround is not working for me.

~# python3 -m pip install pendulum --upgrade
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting pendulum
Using cached https://files.pythonhosted.org/packages/db/15/6e89ae7cde7907118769ed3d2481566d05b5fd362724025198bb95faf599/pendulum-2.1.2.tar.gz
Installing build dependencies ... done
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "", line 1, in
File "/usr/lib/python3.7/tokenize.py", line 447, in open
buffer = _builtin_open(filename, 'rb')
FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pip-install-b7gqf5ij/pendulum/setup.py'

----------------------------------------

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-b7gqf5ij/pendulum/

@mghurd
Copy link

mghurd commented Nov 11, 2020

OK. Had to upgrade my pip3 and could then manually download the whl file and performed the upgrade.

@irdroid3
Copy link

I have just had this on a RPi Zero. (OS and not RPi4 related then...) :

$ pip3 install pendulum
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting pendulum
  Using cached https://files.pythonhosted.org/packages/db/15/6e89ae7cde7907118769ed3d2481566d05b5fd362724025198bb95faf599/pendulum-2.1.2.tar.gz`
`  Installing build dependencies ... done`
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/usr/lib/python3.7/tokenize.py", line 447, in open
        buffer = _builtin_open(filename, 'rb')
    FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pip-install-hpo82ats/pendulum/setup.py'

I also got around this with :
sudo python3 -m pip install pendulum==2.1.1

It appears that the file downloaded for v2.1.2 -
https://files.pythonhosted.org/packages/db/15/6e89ae7cde7907118769ed3d2481566d05b5fd362724025198bb95faf599/pendulum-2.1.2.tar.gz - Is MISSING the setup.py file, where as v2.1.1 -
https://files.pythonhosted.org/packages/9a/0d/e503011d347e2d41f4fb05c6b3d7fbfcc8b2c25baba13e1804597e7d2412/pendulum-2.1.1.tar.gz - HAS a setup.py file.
SO, is this a package build problem in v2.1.2 ?

Regards, Ian
.

@RemBrandNL
Copy link

  • Linux raspberrypi 5.4.83+ #1379 Mon Dec 14 13:06:05 GMT 2020 armv6l

Setting up a clean install on a RPI 0 based on 2021-01-11-raspios-buster-armhf-lite.zip. Ran into this issue running sudo pip3 install results. Just being new, I was happy that @ner0tic 's work-around works like a charm, thanks!
Remco

@fransimo
Copy link

fransimo commented Mar 5, 2021

For me
pip install -U pip
worked fine (on a virtual env)

@jeremyehack
Copy link

Also had this issue on a Raspberry pi 3b+ running 5.10.17-v7+

The 2.1.2 build was failing so I specified 2.1.1. in my requirements.txt and the pi installed it just fine. Seems like an issue with the setup.py file for this version. Not sure what about the issue is specific to the pi OS.

2.1.2

 Installing build dependencies ... done
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/usr/lib/python3.7/tokenize.py", line 447, in open
        buffer = _builtin_open(filename, 'rb')
    FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pip-install-0h4qvms8/pendulum/setup.py'

2.1.1

Building wheels for collected packages: pendulum
  Running setup.py bdist_wheel for pendulum ... error
  Complete output from command /home/.../venv/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-mlhoxes9/pendulum/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/pip-wheel-2gp8i9o8 --python-tag cp37:
  usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
     or: -c --help [cmd1 cmd2 ...]
     or: -c --help-commands
     or: -c cmd --help

  error: invalid command 'bdist_wheel'

  ----------------------------------------
  Failed building wheel for pendulum
  Running setup.py clean for pendulum
Failed to build pendulum
Installing collected packages: pytzdata, pendulum
  Running setup.py install for pendulum ... done

@kimaero
Copy link

kimaero commented Jul 15, 2021

Same here. 2.1.1 was successfully installed while 2.1.2 gave the same errors as people higher in the thread was having

@AetherUnbound
Copy link

It seems like this is also showing up on the Apple M1 computers since that's also ARM-based. The manylinux wheel appears to have the setup.py file present for v2.1.2.

@spacemanspiff2007
Copy link

Installation still fails on a raspberry pi:

Collecting pendulum==2.1.2 (from habapp)
  Using cached https://files.pythonhosted.org/packages/db/15/6e89ae7cde7907118769ed3d2481566d05b5fd362724025198bb95faf599/pendulum-2.1.2.tar.gz
  Installing build dependencies ... done
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/usr/lib/python3.7/tokenize.py", line 447, in open
        buffer = _builtin_open(filename, 'rb')
    FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pip-install-lscf1s_f/pendulum/setup.py'

@spacemanspiff2007
Copy link

@sdispater
I created a small python application that allows you to create home automation rules in python.
I've shared it, so other people can use it too and don't have to start from scratch.
However 95% of my support questions in the forum have been about the failing installation of pendulum and the real frustrating part is not the amount of cries for help but that I can't properly help since the workarounds above work for some people and for some they just fail.

Could you please fix the setup issues?
A simple fix could be to just include a setup.py until it's clear why the installation is failing.

@niwla23
Copy link

niwla23 commented Jan 21, 2022

@sdispater I created a small python application that allows you to create home automation rules in python. I've shared it, so other people can use it too and don't have to start from scratch. However 95% of my support questions in the forum have been about the failing installation of pendulum and the real frustrating part is not the amount of cries for help but that I can't properly help since the workarounds above work for some people and for some they just fail.

Could you please fix the setup issues? A simple fix could be to just include a setup.py until it's clear why the installation is failing.

@spacemanspiff2007

I am trying to install HABApp rn too. The workarround works for me but the version is fixed so it tries to install a broken version.

@spacemanspiff2007
Copy link

The workarround works for me but the version is fixed so it tries to install a broken version.

What do you mean?

@Secrus Secrus added the Packaging Related to system-specific package building issues. label Aug 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Packaging Related to system-specific package building issues.
Projects
None yet
Development

No branches or pull requests