Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

map and starmap should log a name based on the original task name #7962

Open
2 of 4 tasks
TauPan opened this issue Dec 15, 2022 · 1 comment
Open
2 of 4 tasks

map and starmap should log a name based on the original task name #7962

TauPan opened this issue Dec 15, 2022 · 1 comment

Comments

@TauPan
Copy link

TauPan commented Dec 15, 2022

Checklist

  • I have checked the issues list
    for similar or identical enhancement to an existing feature.
  • I have checked the pull requests list
    for existing proposed enhancements.
  • I have checked the commit log
    to find out if the if the same enhancement was already implemented in the
    master branch.
  • I have included all related issues and possible duplicate issues in this issue
    (If there are none, check this box anyway).

Related Issues and Possible Duplicates

Related Issues

  • None

Possible Duplicates

  • None

Brief Summary

If I use task.chunks(...).group() etc. to run tasks, all I see in the logs will be "celery.starmap" and the information about the original task name is completely lost.

I'd like to see e.g. a task name derived on the original one, such as: original_task_name.starmap.

Design

It might be possible to turn the _task_name class attribute into a class property maybe?

Architectural Considerations

I don't know if this might break other parts of celery.

None

Proposed Behavior

I'd like to see e.g. a task name derived on the original one, such as: original_task_name.starmap.

Proposed UI/UX

No change.

Diagrams

N/A

Alternatives

  1. Currently one alternative seems to be to override methods and classes in multiple places, see https://gitter.im/celery/celery?at=639b204db9b687534196b04f which is cumbersome, so a direct change in celery core seems cleaner.

  2. Maybe a method on the Task and/or Signature classes that can be overridden? That one could trivially return celery.starmap for now in order to remain compatible with existing installations.

@open-collective-bot
Copy link

Hey @TauPan 👋,
Thank you for opening an issue. We will get back to you as soon as we can.
Also, check out our Open Collective and consider backing us - every little helps!

We also offer priority support for our sponsors.
If you require immediate assistance please consider sponsoring us.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant