Message2038
Let's create file:
---qq.py
import sys
if hasattr(sys, 'exit'):
print 'first if'
del sys.exit
if hasattr(sys, 'exit'):
print 'second if'
del sys.exit
print 'done'
---cut
Now let's run it in standard python:
# python qq.py
first if
done
And now in jython:
# jython qq.py
first if
second if
Traceback (innermost last):
File "qq.py", line 7, in ?
KeyError: exit
Example from standard library:
# jython Lib/site.py
should output sys.path, but failes with following error:
Traceback (innermost last):
File "Lib\site.py", line 254, in ?
KeyError: setdefaultencoding |
|
Date |
User |
Action |
Args |
2008-02-20 17:18:08 | admin | link | issue1847091 messages |
2008-02-20 17:18:08 | admin | create | |
|