Ich bin mitPython "import random" erzeugen "Import: kann nicht Namen importieren 'Method'"
- Visual Studio 2017
- Python 3.6 64-Bit-
Wenn ich das Visual Studio gebaut interaktive Umgebung, ich bin dabei, "zufällig zu importieren" keine Probleme
Wenn ich den Code (ohne den Debugger) Ich bekomme den folgenden Fehler
Traceback (most recent call last):
File "C:\Users\Andy Slater\github\Introduction to Python Fundamentals\Introduction to Python Fundamentals\sorting.py", line 149, in <module>
import random
File "C:\Program Files\Python36\lib\random.py", line 41, in <module>
from types import MethodType as _MethodType, BuiltinMethodType as _BuiltinMethodType
ImportError: cannot import name 'MethodType'
Können Sie bitte eine [MCVE]? –