Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 1587

Python • Libraries not installing properly

$
0
0
So, I had a working code in an old venv which used the following imports:

import time
impott board
import busio
import adafruit_ads1x15.ads1115
from adafruit_ads1x15.analog_in import AnalogIn

However, when I made a new venv just with the required packages, I have the following error when trying to run it:

Traceback (most recent call last):
File "/home/name/Desktop/test/test/OLD/old.py", line 2, in <module>
import board
File "/home/name/Desktop/test/.test_venv/lib/python3.11/site-packages/board.py", line 21, in <module>
import board
File "/home/name/Desktop/test/.test_venv/lib/python3.11/site-packages/board.py", line 21, in <module>
from adafruit_blinka.agnostic import board_id, detector
ModuleNotFoundError: No module named 'adafruit_blinka

I have no idea why this is happening, or how to fix it... For added context, I'm working on a Raspberry Pi 5. Thank you in advance for anyone who chimes in.

EDIT: I've failed to mention exactly the libraries that I have installed on my venv:
pip install adafruit-blinka
pip install adafruit-circuitpython-ads1x15
That's it, just those two. Previously, for other older venvs I ended up deleting, I had also tried installing libraries with pip3 and/or --upgrade, combinations with other libraries (RPi.GPIO, lgpio, pip, setuptools, wheel). Sadly, nothing works.

Statistics: Posted by MTR20XX — Thu Jun 19, 2025 1:42 am



Viewing all articles
Browse latest Browse all 1587

Trending Articles