Package doesn't work if run from cmd or from the .py file… PYTHON
问题 I noticed a problem with python (windows). If I create a program (even simple) and I import a package, it works if I run it from the python shell but if I run it from the .py file or with the cmd (C:\Python34\program.py) it doesn't. Make it clear: Program 1 from selenium import webdriver print("have a good day") Program2 import pyautogui print("be happy") pyautogui.moveT(300,300) Error program 1 Traceback (most recent calls) File"C:\Python34\program.py" line 1, in <module> from selenium