How do I find the full path of the currently running Python interpreter from within the currently executing Python script?
Advertisement
Answer
sys.executable
contains full path of the currently running Python interpreter.
import sys print(sys.executable)
which is now documented here