PATH hinzufügen lief schief (Mac, Homebrew)
Verfasst: Donnerstag 7. Mai 2020, 09:43
Mac: 10.15.1
Python: 3.8.2
Homebrew
Das wollte ich tun:
Mein Programm lief, wenn ich den Befehl eingab:
Gemäß der Anleitung [1], fügte ich den Pfad zum PATH hinzu (/usr/local/Cellar/python@3.8/3.8.2/bin/python3)
[1]
https://www.educative.io/edpresso/how-t ... ble-in-mac
Das passiert:
Wenn ich jetzt kompilieren erhalte ich
bzw.:
Das sind die aktuellen Pfade, die ich erreiche über "sudo nano /etc/paths"
Irgendetwas muss schief gelaufen sein, da ich ja über die ursprüngliche Methode mit Pfadangabe auch nicht mehr kompilieren kann.
Möglicher weiterer Lösungsansatz
Soll ich dies noch zum Pfad hinzufügen:
"/usr/local/Cellar/python@3.8/3.8.2/bin/python3/usr/local/bin"
?
Python: 3.8.2
Homebrew
Das wollte ich tun:
Mein Programm lief, wenn ich den Befehl eingab:
Code: Alles auswählen
/usr/local/Cellar/python@3.8/3.8.2/bin/python3 __init__.py
[1]
https://www.educative.io/edpresso/how-t ... ble-in-mac
Das passiert:
Wenn ich jetzt kompilieren erhalte ich
Code: Alles auswählen
Laptop:Anwendung_Python username$ python3 __init__.py
Traceback (most recent call last):
File "__init__.py", line 5, in <module>
from PyQt5 import QtCore, QtGui, QtWidgets
ModuleNotFoundError: No module named 'PyQt5'
Code: Alles auswählen
Laptop-JCL:Anwendung_Python XXX$ /usr/local/Cellar/python@3.8/3.8.2/bin/python3 __init__.py
/usr/local/Cellar/python@3.8/3.8.2/bin/python3: line 1: /usr/local/Cellar/python@3.8/3.8.2/bin/python3/usr/local/bin: Not a directory
/usr/local/Cellar/python@3.8/3.8.2/bin/python3: line 2: /usr/bin: is a directory
/usr/local/Cellar/python@3.8/3.8.2/bin/python3: line 3: /bin: is a directory
/usr/local/Cellar/python@3.8/3.8.2/bin/python3: line 4: /usr/sbin: is a directory
/usr/local/Cellar/python@3.8/3.8.2/bin/python3: line 5: /sbin: is a directory
Code: Alles auswählen
GNU nano 2.0.6 File: /etc/paths
/usr/local/bin
/usr/bin
/bin
/usr/sbin
/sbin
Möglicher weiterer Lösungsansatz
Soll ich dies noch zum Pfad hinzufügen:
"/usr/local/Cellar/python@3.8/3.8.2/bin/python3/usr/local/bin"
?