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

Is alive_progress celery compatible? #262

Open
HappyCthulhu opened this issue Jan 20, 2024 · 1 comment
Open

Is alive_progress celery compatible? #262

HappyCthulhu opened this issue Jan 20, 2024 · 1 comment
Labels
improvement It does work, but there's this little thing
Milestone

Comments

@HappyCthulhu
Copy link

Im wondering, can i get some logging, if alive_bar working inside of celery worker?

With this code:

import time

from alive_progress import alive_bar

for x in 1000, 1500, 700, 0:
    with alive_bar(x) as bar:
        for i in range(1000):
            time.sleep(0.005)
            bar()

Im getting this error:
image

If im trying to disable it in celery with arg disable=True, it doesnt work too. Can i do smth with this?

@rsalmei
Copy link
Owner

rsalmei commented Jan 20, 2024

It should. However, I see in the celery logging code that they, unfortunately, didn't include a fileno method here, which has broken my file validation. That's why alive_progress is throwing ValueError: Invalid config value.
I can fix it so it won't break, and can include this fix in the next minor version soon 👍.

But, why would you want to put alive_progress in a background async task worker anyway? You won't be able to see it running...

@rsalmei rsalmei added this to the 3.2 milestone Jan 28, 2024
@rsalmei rsalmei added the improvement It does work, but there's this little thing label Jan 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement It does work, but there's this little thing
Projects
None yet
Development

No branches or pull requests

2 participants