You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fromhelloimportsay_helloimportasynciofromice.traceimporttrace, enable_traceif__name__=='__main__':
enable_trace()
@traceasyncdefmain_wrapper():
# A traced function cannot be called until the event loop is running.returnawaitsay_hello()
print(asyncio.run(main_wrapper()))
This code performs tracing when started with python test.py
I tried running an example recipe with
python hello.py
- and it works perfectly.However, I can not find any instructions on how to use tracing functionality not as a standalone demonstration, but inside other applications.
A simplest example would be:
Which does not work when run with
python test.py
- no traces being recorded.Could anyone please point me towards a way to achieve this?
The text was updated successfully, but these errors were encountered: