-
Notifications
You must be signed in to change notification settings - Fork 91
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
Implement WebSockets #17
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally this looks great - thanks for the PR!
I'm a bit wary about introducing the additional dependencies for everyone that uses the lib. Do you have any thoughts/suggestions on how best to handle that? Part of me was wondering whether this should actually be a separate project, although that's probably overkill.
Also do you have any suggestions on how I can test/play with this? In full transparency I've never used channels
before.
In complete honesty, I discovered |
Thanks for the super quick response. I do want to prioritize getting this supported in some way but I'm a bit swamped at the moment so I'm going to be a bit slow. 🙈 I have no idea how much work this is because I've never done it, but I think the ideal would be if this was implemented as a bundle, kind of like celery does: https://docs.celeryproject.org/en/latest/getting-started/introduction.html#bundles If you think you can take a crack at that that'd be amazing! Else I'll put it on my backlog and revisit it as soon as I'm able. |
Sorry for the late response, I had a bunch of things going on and this got lost on my to-do list! I've added the Edit: A bare-bones example can be found here. |
this is awesome! thanks so much. confirming it's ready for review/testing? |
I've identified an issue where failed tasks seem to have an issue propagating to the frontend, and I'm investigating it before I give the all clear. |
Both this pull request and the example project have been updated, and I believe they are ready for testing! One thing I want your opinion on though, if people have not installed the websockets part of the package, should |
One thing I noticed is that (at least in my testing) I couldn't get |
Awesome, thank so much! I'll test and report back in the next couple days |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great, thanks. I haven't actually been able to test it out apart from your project, but I've confirmed that it doesn't break anything else so I'm going to merge it in, add some short docs, and then bump the version.
Thanks for the help!
I'm a bit torn on this. I added logging in #19 but I can see the case for failing harder. Since you're deliberately using the |
This is a rudimentary attempt at implementing websockets as requested in #16. As a caveat to this, users will have to install the
channels
library for the websockets portion to function. A guide on what to add to your project can be found here. I didn't know how you wanted this to be documented, so I've left it alone. I have tested this on a Windows 10 machine with Python 3.6, Django 2.2, and Celery 4.3 running with Gevent. Any recommendations are welcome and heavily encouraged.