IBM / pyflowgraph

Flow graphs for Python
Apache License 2.0
25 stars 8 forks source link

Cannot trace builtin functions #10

Closed epatters closed 6 years ago

epatters commented 6 years ago

The tracer does not pick up builtin functions and methods. To be clear, "builtin" means implemented in C, not necessarily restricted to functions built into the Python language itself:

https://docs.python.org/3/library/types.html#types.BuiltinFunctionType

Thus, builtins include third-party C extensions not wrapped at the Python level, e.g., numpy.random.rand.

epatters commented 6 years ago

I don't think it's possible to fix this issue solely through sys.settrace or sys.setprofile. References:

https://stackoverflow.com/q/16115027 https://bugs.python.org/issue17799 https://mail.python.org/pipermail/python-list/2010-March/571322.html