When tracing(using sys.settrace) python .egg execution by Python 2.7 interpreter frame.f_code.co_filename instead of <path-to-egg>/<path-inside-egg> eqauls to something like build/bdist.linux-x86_64/egg/<path-inside-egg>

Is it a bug? And how to reveal real path to egg?

In Python 2.6 and Python 3 everything works as expected.

有帮助吗?

解决方案

No, that is not a bug. Eggs, when being created, have their bytecode compiled in a build/bdist.<platform>/egg/ path, and you see that reflected in the co_filename variable. The bdist stands for binary distribution.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top