I'm a beginner at Python, and I'm currently mainly learning languages.
We used anaconda 4.1.1 (Python 3.5.2) to create a Python environment.
I heard Python 3.6 is out, so I'm going to study the environment, but I don't understand it.
First, we built the Python 3.6 environment as follows:
c:\conda create-npy36 python=3.6 anaconda
-
# conditions:
#
py36 C:\Users\(uname)\AppData\Local\Continuum\Anaconda3\envs\py36
root* C:\Users\(uname)\AppData\Local\Continuum\Anaconda3
I have a question.
1. I heard that activate py36 can switch between virtual environments, but I can't.
Please tell me how to switch.
メインThe main shell uses powershell.
シェルShell switched when using the command prompt.
2. I was able to switch at the command prompt, but
The prompt changed to y(py36)c:> と.
in python 3.6 while (py36) is displayed
I can guess that it will be a virtual environment, but is it possible to set the default to Python 3.6?
For example, update the root version to 3.6 and then
Are you going to build 3.5.2?
3. I was looking online to switch between virtual environments, but virtualenv is also
I heard that there is one, but how is it different from the activate command?
It is a known problem that Powershell cannot switch between Anaconda's virtual environment.This issue aggregates information.
As of March 2018, the following workaround is known:
Use pscondaenvs.
conda install-not root-cpscondaenvs pscondaenvs
Launch cmd
in Powershell, activate and then return to Powershell.
(To set the default to Python 3.6) Is it to update the root version to 3.6 and then build a new 3.5.2?
Yes, the virtual environment is used for temporary changes, so if you want the default to 3.6, you can update it in the default environment.If you don't want to lose your current default environment at this time, you can copy (clone) your virtual environment.
For more information about Anaconda's virtual environment, see the official document.
Roughly speaking, the conda command integrates the virtualenv and pip commands.There is a comparison here in the official Anaconda document Virtualenv alone cannot install the package in a virtual environment (using pip).Also, to use the Anaconda Cloud package in the first place, you have to use the conda command.
Python's virtual environment tool is also called pyenv.There are several posts on our Stack Overflow comparing the three parties, so please take a look.
610 GDB gets version error when attempting to debug with the Presense SDK (IDE)
912 When building Fast API+Uvicorn environment with PyInstaller, console=False results in an error
617 Uncaught (inpromise) Error on Electron: An object could not be cloned
572 rails db:create error: Could not find mysql2-0.5.4 in any of the sources
© 2024 OneMinuteCode. All rights reserved.