Open OlegInsait opened 1 week ago
Hi @OlegInsait! Thanks for the issue. I'm having trouble reproducing this with your MRE (or perhaps I am misunderstanding your issue?).
I'm running on Prefect 2.19.6 (and also checked on Prefect 3) and I see the following task run name in the UI:
Could you try upgrading and see if things work as you expect? Or could you give more detail about what you are seeing and what you expect to see? Thank you!
@zhen0
Thank you for the response.
I updated the prefect version to 2.19.6 as you suggested and got still the same results.
Since I usually did not use UI, the problem was seen in the logs. This time I decided to go to the prefect UI and see what happens there.
Now it is even more frustrating: the task name in the flow run timeline chart is indeed customized, but logs are still untouched...
Ah! That is odd but I can reproduce the logs vs timeline difference in 2.19.6. In Prefect 3 the logs are also updated (as in my screenshot). I'll add to our backlog and if this is important to you and you are ok with using a release candidate, you can try this out with 3.0.
Thank you @zhen0 ! I don't think we are ready to change prefect major version in our production, yet... Meanwhile I will use this:
from prefect import task
def my_task(arg):
...
task(lambda: my_task(my_arg)).with_options(name="my_fancy_name")
Totally fair!! Thanks for sharing the workaround. That'll be helpful to others who see this issue.
First check
Bug summary
I tried to make my task names more descriptive using
task_run_name
option but it did not do any changes. To understand where the problem is I tried to run the toy example from the prefect documentation but it also did not work as expected...Reproduction
Error
Versions (
prefect version
output)Additional context
No response