Issue1456
Created on 2009-09-02.16:21:28 by thijs, last changed 2010-04-11.22:21:44 by pjenvey.
msg5088 (view) |
Author: Thijs Triemstra (thijs) |
Date: 2009-09-02.16:21:28 |
|
While testing Jython 2.5.1rc1 with PyAMF 0.5 trunk (r2754) I'm getting unexpected
errors that don't show up in CPython:
$ jython
Jython 2.5.1rc1 (Release_2_5_1rc1:6736:6741, Sep 1 2009, 10:37:37)
[Java HotSpot(TM) 64-Bit Server VM (Apple Inc.)] on java1.6.0_13
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> import pyamf
>>> pyamf.register_package(sys, 'com.example.test')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "pyamf/__init__.py", line 1680, in register_package
classes = filter(check_attr, [get(x) for x in keys])
File "pyamf/__init__.py", line 1647, in <lambda>
get = lambda x: getattr(module, x)
AttributeError: write-only attr: trace
$ python
Python 2.5.1 (r251:54863, Feb 6 2009, 19:02:12)
[GCC 4.0.1 (Apple Inc. build 5465)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> import pyamf
>>> pyamf.register_package(sys, 'com.example.test')
{}
|
msg5089 (view) |
Author: Thijs Triemstra (thijs) |
Date: 2009-09-02.16:30:43 |
|
Note that the same thing happens with Jython 2.5 final:
$ ../jython2.5.0/bin/jython
Jython 2.5.0 (Release_2_5_0:6476, Jun 16 2009, 13:33:26)
[Java HotSpot(TM) 64-Bit Server VM (Apple Inc.)] on java1.6.0_13
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> import pyamf
>>> pyamf.register_package(sys, 'com.example.test')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "pyamf/__init__.py", line 1680, in register_package
classes = filter(check_attr, [get(x) for x in keys])
File "pyamf/__init__.py", line 1647, in <lambda>
get = lambda x: getattr(module, x)
AttributeError: write-only attr: trace
|
msg5673 (view) |
Author: Philip Jenvey (pjenvey) |
Date: 2010-04-11.22:21:43 |
|
This was due to our sys module being a weird Java integration object and the Java integration layer making set-only shorthand bean properties for the sys.settrace/profile functions. I disabled the props in r7020 with a hack
Hopefully one day we can redo sys to be a simpler real Python module
|
|
Date |
User |
Action |
Args |
2010-04-11 22:21:44 | pjenvey | set | status: open -> closed resolution: invalid messages:
+ msg5673 nosy:
+ pjenvey title: AttributeError: write-only attr: trace -> sys.trace/profile attributes cause: AttributeError: write-only attr: trace in PyAMF |
2009-09-11 20:08:54 | fwierzbicki | set | nosy:
+ fwierzbicki |
2009-09-07 20:30:08 | njoyce | set | nosy:
+ njoyce |
2009-09-02 16:30:44 | thijs | set | messages:
+ msg5089 |
2009-09-02 16:21:28 | thijs | create | |
|