Re: Status report on python2 transition (possible solution)
D-Man <dsh8290@rit.edu> writes:
> Say, ..., is there a way for a python script to find out where the
> python binary executing it is? If so, then the "real" script could be
> run via os.system by the Debian script that uses #! deb_py_ver.
sys.executable, which comes from argv[0] in Py_Main(), looking in
$PATH if necessary.
os.system isn't the best in terms of signal handling and return
values; you'd probably want os.execv.
--
Carey Evans http://home.clear.net.nz/pages/c.evans/
"Quiet, you'll miss the humorous conclusion."
Reply to: