Home > other >  Help: Python with Tribon interference? Python3 after installation cannot run..
Help: Python with Tribon interference? Python3 after installation cannot run..

Time:10-21

Python is a great god,

Found after installation Python3, unable to run, as shown in the figure below, what reason be excuse me? How to solve?

Thank you first!

CodePudding user response:

Tribon built-in python, two python version at the same time there is only one effective, but also may conflict,
There is only one way,

CodePudding user response:

What way? Please express

CodePudding user response:

1. Delete the original including python3 any system environment variables, why you have so many python environment variable
2. Keep the following code for python3. Bat and excluding python related documents on the arbitrary folder
3. Add the path variable system environment for the above folder

The first sentence must get the method of use: the console input python3 instead of python
Such as input: python3 or python3 test. Py and so on after an arbitrary command is python3 environment
Can replace with python python3 after, of course, also can continue to use python3,
Can operate in its usual way: PIP install SomePackage installation package, of course you can also
The first sentence using: python3 PIP install SomePackage
 @ echo off 
Set the path=c: \ python3; C: \ python3 \ Scripts. % ~ dp0
Python % 1% 2% 3% 4% 5% 6% 7% 8% 9

CodePudding user response:

update code, forget to % ~ dp0; Added after the original path environment variable
Your path variable to add original to remove contains m3 item (i.e. the Tribon path environment variable)
 @ echo off 
Set the path=c: \ python3; C: \ python3 \ Scripts. % ~ dp0; C: \ Windows \ system32; C: \ Windows; C: \ Windows \ System32 \ Wbem; C: \ Windows \ System32 \ WindowsPowerShell \ v1.0 \; C: \ Windows \ System32 \ OpenSSH \; C: \ Users \ lee \ AppData \ Local \ Microsoft \ WindowsApps
Python % 1% 2% 3% 4% 5% 6% 7% 8% 9

CodePudding user response:

My m3 variables in the system PYTHONPATH inside, see below:



Please change the PATH or PYTHONPATH?

Thank you very much!

CodePudding user response:

Is if C:/Python3 your Python3 installation directory, only contains C:/Python3, delete all, including the user in the path variable, the following system and in the path variable PYTHONPATH variable, then update code:
 @ echo off 
The set PYTHONPATH=
Set the path=c: \ python3; C: \ python3 \ Scripts. C: \ python3 \ Dlls. C: \ python3 \ lib. % ~ dp0; C: \ Windows \ system32; C: \ Windows; C: \ Windows \ System32 \ Wbem; C: \ Windows \ System32 \ WindowsPowerShell \ v1.0 \; C: \ Windows \ System32 \ OpenSSH \; C: \ Users \ lee \ AppData \ Local \ Microsoft \ WindowsApps
Python % 1% 2% 3% 4% 5% 6% 7% 8% 9

CodePudding user response:

Is equivalent to remove Python3 variables in your computer, remove the Tribon variables in the code I gave you,

CodePudding user response:

% ~ dp0
Python % 1% 2% 3% 4% 5% 6% 7% 8% 9

What those words mean?

CodePudding user response:

% ~ dp0
Represents the current batch file python3. Bat is a complete directory
Python % 1% 2% 3% 4% 5% 6% 7% 8% 9
Will all pass python3. The parameters of the bat to python. Exe
So python3. Bat the Tribon environment variables are eliminated, set up a new environment variable, and pass parameters to the Python implementation,



CodePudding user response:

The
my great god reply: 666, 9/f, reference
% ~ dp0
Represents the current batch file python3. Bat is a complete directory
Python % 1% 2% 3% 4% 5% 6% 7% 8% 9
Will all pass python3. The parameters of the bat to python. Exe
So python3. Bat the Tribon environment variables are eliminated, set up the new environment variable, and pass parameters to the Python implementation,



Great god

If I want to run under the TRIBON secondary development program, what method?

Thank you very much!

CodePudding user response:

I want to see you the following icon in the red line of the three variable values

CodePudding user response:

11 references, my great god reply: 666
I want to see you the following icon in the red line of the three variable values



Please find:


CodePudding user response:

delete the first map in front of 2, 2 picture from the back of 2, 3 picture from the front 11,
installed Tribon and Python3 today and have tried it on, so want to a better way:


The cmd3. Bat with the following code to save and dragged into Windows folder, called before you save the python3. Bat out,
 @ echo off 
The set PYTHONPATH=
Set the path=c: \ python3; C: \ python3 \ Scripts. % % path
If "% 1"=="" (CMD)

CodePudding user response:

The
reference 13 floor my great god reply: 666
delete the first map in front of 2, 2 picture from the back of 2, 3 picture from the front 11,
installed Tribon and Python3 today and have tried it on, so want to a better way:


The cmd3. Bat with the following code to save and dragged into Windows folder, called before you save the python3. Bat out,
 @ echo off 
The set PYTHONPATH=
Set the path=c: \ python3; C: \ python3 \ Scripts. nullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnull
Next:Python
  • Related