The same approach could be used to make a program that explictly loads eg. 
python3.4 execuable with correct $PYTHONPATH based on
for example $PYTHON_VERSION environment variable setting .
Another approach might be to convert all scripts that require python3+ to 
explicitly start with
'#!/usr/bin/python3.4
'
, but you'd have to update them each time you upgrade python .
Yet another approach, which might be best in the long term, would be to update 
the kernel to handle more sophisticated 
'#!' lines like: 
'#!python>=3
'
meaning : find the file under any directory in $PATH  that ends with a decimal 
label string consisting of numbers and '.' or '_' chars only
that compares >= to the label '3' , and then run it as the interpreter.
Or you could make a program based on the python.c program in the link above 
which interprets special arguments , and all scripts could
start with something like :
 '#!/usr/bin/python_launcher >= 3
'

These issues and many other syntax ambiguities and many other attributes make 
Python IMHO a moving target to develop for and not suitable for 
use in reliable production quality systems .

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1398033

Title:
  python breaks gdb

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apport/+bug/1398033/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to