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

Websocket progress doesn't update to success at 100% #65

Open
PazimGoyal opened this issue Nov 2, 2020 · 3 comments
Open

Websocket progress doesn't update to success at 100% #65

PazimGoyal opened this issue Nov 2, 2020 · 3 comments
Labels
bug Something isn't working

Comments

@PazimGoyal
Copy link

when I use ProgressRecorder the progress bar updates at 100% and even the custom function is called but when I use WebsocketProgressRecorder with channels==2.2.0 and redis at reaches 100% and stays their. on further debug the status remains (in event in js) remains pending.

@EJH2
Copy link
Collaborator

EJH2 commented Nov 3, 2020

That's certainly not good. If you could provide the code for the task as well as more information about your python install/operating system, I'll go ahead and take a look at this. If you run your celery instance with the log level set to debug, does it error at all?

@EJH2 EJH2 changed the title Websocker progress doesn't update to success at 100% Websocket progress doesn't update to success at 100% Nov 3, 2020
@PazimGoyal
Copy link
Author

PazimGoyal commented Nov 3, 2020

try:
progress_recorder = WebSocketProgressRecorder(self)
# progress_recorder=ProgressRecorder(self)
processed_results = processing_data.process_data(request, progress_recorder)
return processed_results

I am using channels==2.2.0 / 2.1.2 ( testing on both) , daphne==2.5.0 redis/rabbitMQ as broker ( again testing both) , Everything runs on Docker composition. (nginx + uwsgi + daphne )
When I use Process Recorder and send http requests with task ID everything works fine but if using WebsocketProcessRecorder ,status always remain pending even if I do more then 100%.
image

@EJH2
Copy link
Collaborator

EJH2 commented Nov 3, 2020

The only possibility that I can think of as to why the success event wouldn't fire is if the websocket post-run handler hasn't been properly connected. In your INSTALLED_APPS, can you confirm that celery_progress.websockets is present?

@EJH2 EJH2 added the bug Something isn't working label Nov 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants