It does not tell you if running code is currently being JITted, however. sys._jit.is_active(): Lets you know if the topmost Python stack frame is currently executing JITted code. However, this is not ...