Wie zu verwenden wxPython Python 3?

Ich installiert wxPython 3.0.1.1, aber ich bin nicht in der Lage zu import wx mit Python 3.4.1. Ich erhalte die folgende Fehlermeldung:

Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 00:54:21) 
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import wx
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named 'wx'

Trotzdem kann ich import wx wenn ich Python 2.7 (die Standard-installation in meinem OS X 10.9):

Python 2.7.5 (default, Mar  9 2014, 22:15:05) 
[GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.0.68)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import wx
>>>

Wie kann ich mit wxPython Python 3, die speziell für Python 3.4.1?

  • Vielleicht müssen Sie das Modul, den Standort manuell auf Ihre sys.path: sys.path.insert("/location/of/wx") Hier ist eine detaillierte Beschreibung: stackoverflow.com/questions/279237/...
  • Wie kann ich es tun, so wird es dauerhaft sein?
  • stackoverflow.com/questions/3402168/...
  • Dies ist nur ein workaround, aber. Also ich nicht poste es als Antwort. Entnehmen Sie dem Paket den Händler, wenn Sie brauchen eine saubere Lösung. Installation es sollten die Pakete in der richtigen Lage oder erweitern Sie die Pfade korrekt.
  • danke, das problem ist, ich weiß nicht, den richtigen Speicherort zu installieren, wx für python 3. Haben Sie eine Idee?
  • Standardmäßig arbeiten soll, soll er zur Unterstützung von Python 3. Aber es ist nicht. Siehe meine Antwort.

InformationsquelleAutor Nick | 2014-10-08
Schreibe einen Kommentar