1

I found this to try to help me install pypy3 https://stackoverflow.com/questions/55703832/install-pypy3-on-raspberry-pi However the download command no longer works. I tried:

sudo apt-get install pypy3

but I got this:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  pypy3-lib
Suggested packages:
  pypy3-doc pypy3-tk
The following NEW packages will be installed:
  pypy3 pypy3-lib
0 upgraded, 2 newly installed, 0 to remove and 20 not upgraded.
Need to get 9,908 kB of archives.
After this operation, 54.4 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://mirror.umd.edu/raspbian/raspbian buster/main armhf pypy3-lib armhf 7.0.0+dfsg-3 [2,333 kB]
Get:2 http://mirror.umd.edu/raspbian/raspbian buster/main armhf pypy3 armhf 7.0.0+dfsg-3 [7,574 kB]
Fetched 9,908 kB in 2s (4,321 kB/s)
Selecting previously unselected package pypy3-lib:armhf.
(Reading database ... 145466 files and directories currently installed.)
Preparing to unpack .../pypy3-lib_7.0.0+dfsg-3_armhf.deb ...
Unpacking pypy3-lib:armhf (7.0.0+dfsg-3) ...
Selecting previously unselected package pypy3.
Preparing to unpack .../pypy3_7.0.0+dfsg-3_armhf.deb ...
Unpacking pypy3 (7.0.0+dfsg-3) ...
Setting up pypy3-lib:armhf (7.0.0+dfsg-3) ...
Setting up pypy3 (7.0.0+dfsg-3) ...
running pypy3 rtupdate hooks for 7.0
Traceback (most recent call last):
  File "/usr/bin/pypy3compile", line 160, in <module>
    main()
  File "/usr/bin/pypy3compile", line 152, in main
    py_compile.compile(module, doraise=True)
  File "/usr/lib/pypy3/lib-python/3/py_compile.py", line 122, in compile
    source_bytes = loader.get_data(file)
  File "<builtin>/frozen importlib._bootstrap_external", line 839, in get_data
OSError: [Errno 117] Structure needs cleaning: '/usr/lib/python3/dist-packages/lxml/sax.py'
error running pypy3 rtupdate hook public_modules.rtupdate
dpkg: error processing package pypy3 (--configure):
 installed pypy3 package post-installation script subprocess returned error exit status 4
Processing triggers for man-db (2.8.5-2) ...
Errors were encountered while processing:
 pypy3
E: Sub-process /usr/bin/dpkg returned an error code (1)

When I tried to run pypy3 it was unable to import a module installed for python3. My guess is that the errors during install are the cause. Can anyone help?

3
  • There are a few hits on the OS error pointing to faulty disk structure - maybe fsck (check mode) may show something?
    – user115418
    Nov 20 '20 at 23:01
  • @Andyroo Can you tell me how to use "fsck".
    – UNKNOWN
    Nov 20 '20 at 23:54
  • Not really one for comments - its a complex command linuxhandbook.com/fsck-command but I would try Ingos answer - I missed that line :-(
    – user115418
    Nov 21 '20 at 12:54
2

One line of the output shows:

0 upgraded, 2 newly installed, 0 to remove and 20 not upgraded.

20 not upgraded means you have old packages and old dependencies. You should update it with:

rpi ~$ sudo apt update        # updates package lists
rpi ~$ sudo apt full-upgrade  # upgrades old packages
rpi ~$ sudo apt install pypy3
1
  • It installed without any errors this time, but I'm still getting the same problem. Guess I have more research to do :)
    – UNKNOWN
    Nov 22 '20 at 12:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.