PS E:\Python and Data Science\PythonDatabase> conda activate base
conda : The term 'conda' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling    
of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ conda activate base
+ ~~~~~
    + CategoryInfo          : ObjectNotFound: (conda:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException
PS E:\Python and Data Science\PythonDatabase> & C:/Users/Lenovo/Anaconda3/python.exe "e:/Python and Data Science/PythonDatabase/CourseHelper.py" …Run Code Online (Sandbox Code Playgroud) 我有一个 Raspberry,我正在尝试连接到 Ubidots IOT 云,但出现以下错误:
pi@raspberrypi:~/Downloads/raspbiDaniela/Ver 2016/ZonrProject $ python main.py
    Traceback (most recent call last):
      File "main.py", line 124, in <module>
        main()
      File "main.py", line 21, in main
        ser = serial.Serial(port=port, baudrate=baud)
      File "/usr/lib/python2.7/dist-packages/serial/serialutil.py", line 261, in __init__
        self.open()
      File "/usr/lib/python2.7/dist-packages/serial/serialposix.py", line 278, in open
        raise SerialException("could not open port %s: %s" % (self._port, msg))
    serial.serialutil.SerialException: could not open port /dev/ttyAMA0: [Errno 13] Permission denied: '/dev/ttyAMA0'
Run Code Online (Sandbox Code Playgroud) 尝试在系统中安装具有不同版本的django,它向我显示:
Installing collected packages: Django
Found existing installation: Django 1.7.11
Not uninstalling django at /home/user/lib/python2.7, outside environment /home/user/webapps/v2_dev/venv
Run Code Online (Sandbox Code Playgroud)
成功安装Django-1.8.19
但实际上有旧版本
尝试了不同的命令:
./venv/bin/pip install Django==1.8.11
pip install Django==1.8.11
Run Code Online (Sandbox Code Playgroud)
更新:安装软件包时,它显示:
The required version of setuptools (>=16.0) is not available,
and can't be installed while this script is running. Please
install a more recent version first, using
'easy_install -U setuptools'.
(Currently using setuptools 3.1 (/home/user/lib/python2.7/setuptools-3.1-py2.7.egg))
Run Code Online (Sandbox Code Playgroud)
升级时:
venv/bin/pip install --upgrade setuptools
Requirement already up-to-date: setuptools in ./venv/lib/python2.7/site-packages (40.5.0)
Run Code Online (Sandbox Code Playgroud) python ×3
conda ×1
django ×1
pip ×1
pyserial ×1
python-3.x ×1
raspberry-pi ×1
raspbian ×1
serial-port ×1
webfaction ×1