Hey guys, I notice that PyPy doesn't offer a `sys.gettrace` function, given that it is an implementation detail. Is there any other way to do the equivalent of `sys.gettrace` in PyPy? Thanks, Ram.
2011/10/5 Ram Rachum <ram@rachum.com>:
Hey guys, I notice that PyPy doesn't offer a `sys.gettrace` function, given that it is an implementation detail. Is there any other way to do the equivalent of `sys.gettrace` in PyPy?
Hum, it was probably ovelooked. Seems trivial to implement, will give a try. -- Amaury Forgeot d'Arc
Hi Amaury, On Wed, Oct 5, 2011 at 21:54, Amaury Forgeot d'Arc <amauryfa@gmail.com> wrote:
Is there any other way to do the equivalent of `sys.gettrace` in PyPy?
Hum, it was probably ovelooked. Seems trivial to implement, will give a try.
Indeed, sys.gettrace() and sys.getprofile() were added in Python 2.6, with proper unit tests in test_sys_settrace.py. We should try to understand why this test didn't fail so far on PyPy... Do we run it at all? If not, it's kind of bad. Armin
2011/10/5 Armin Rigo <arigo@tunes.org>:
Indeed, sys.gettrace() and sys.getprofile() were added in Python 2.6, with proper unit tests in test_sys_settrace.py. We should try to understand why this test didn't fail so far on PyPy... Do we run it at all? If not, it's kind of bad.
test_sys_settrace.py runs correctly, but the function is named "set_and_retrieve_func"... without the test_ prefix! Fixed in revision 383ca802ba07, will fix in cpython as well. -- Amaury Forgeot d'Arc
participants (3)
-
Amaury Forgeot d'Arc -
Armin Rigo -
Ram Rachum