# Is there a call to read task id?

**URL:** <https://discourse.julialang.org/t/is-there-a-call-to-read-task-id/72906>\
**Category:** Internals & Design\
**Created:** [December 10, 2021, 6:06pm UTC](https://discourse.julialang.org/t/is-there-a-call-to-read-task-id/72906 "2021-12-10T18:06:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Tomas\_Pevny](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tomas_pevny/32/25466_2.png) [@Tomas\_Pevny](https://discourse.julialang.org/u/Tomas_Pevny)\
**Post date:** [December 10, 2021, 6:06pm UTC](https://discourse.julialang.org/t/is-there-a-call-to-read-task-id/72906/1 "2021-12-10T18:06:49Z")

</div>

Dear All,

from a toy school demonstration project on IRTools, I have started to work on [https://github.com/pevnak/LoggingProfiler.jl](https://github.com/pevnak/LoggingProfiler.jl), which surrounds every call by a logging its start and its end. I want to create something like parallel heatmap as is on this figure  
[https://github.com/pevnak/LoggingProfiler.jl/blob/main/docs/src/multi\_threadded\_luxor.png](https://github.com/pevnak/LoggingProfiler.jl/blob/main/docs/src/multi_threadded_luxor.png)

But in Julia 1.7 The task migration complicates reconstruction of the flamegraph. Is there a call, which would tell me which task is being executed?

Thanks a lot in advance,  
Tomas

---

<div class="post-metadata">

**Author:** ![Tomas\_Pevny](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tomas_pevny/32/25466_2.png) [@Tomas\_Pevny](https://discourse.julialang.org/u/Tomas_Pevny)\
**Post date:** [December 10, 2021, 6:13pm UTC](https://discourse.julialang.org/t/is-there-a-call-to-read-task-id/72906/2 "2021-12-10T18:13:12Z")

</div>

I might have find it, current\_task()
