Hi I am deploying a website with a live discussion feature. But people
cannot send nor receive messages on this discussion page. In the console it
shows: "WebSocket connection to 'ws:///room1/' failed: Error during
WebSocket handshake: Unexpected response code: 200"
I don't know where t
I'm not quite sure what you mean - Channels will still serve Django views
as well unless you override HTTP serving as well as WebSocket, and even
then, you can follow the URLRouter docs to keep it working fine:
http://channels.readthedocs.io/en/latest/topics/routing.html#urlrouter
Andrew
On Thu,
On zondag 24 juni 2018 15:45:47 CEST Dejan Spasić wrote:
> def post_save_user(**kwargs: Dict[str, Any]) -> None:
> if kwargs['created']:
> return None
So for new users, you bail out and do nothing. Your code works exactly as you
wrote it.
--
Melvyn Sopacua
-
I'm not quite sure - WebSockets do have browser differences. You could also
try adding a delay between the accept and the close to see if that changes
how they handle it.
Andrew
On Sun, 24 Jun 2018, 06:02 Kirill Tyushchakov,
wrote:
> Hi, Andrew! Thanks a lot for your response.
> I've changed my
Hi,
Weirdly, I've just been doing this. What do you have in your settings
INSTALLED_APPS?
One of them should be something like 'employer.apps.EmployerConfig'
alternatively in your employer module's __init__.py file you need to say
default_app_config = 'employer.apps.EmployerConfig'
Dan
On 24 Ju
I don't wont to bother you with a long text and will first show you the
code. I think this should be self explanatory. If not, let me know :)
#
from typing import Any, Dict
from django.apps import AppConfig
from django.db.models.signals import post_save
from django.contrib.
I wish to add radio buttons fill in each parameter of my model and also to
convert it to integer on the backend. But somehow its not changing. Kindly
help.
Thanks and regards,
Saloni
*Forms.py*
class PostForm(forms.ModelForm):
class Meta:
fields = ("teacher","subject","param1","para
Alright! Thanks much!
On Sun, 24 Jun 2018, 6:56 pm Melvyn Sopacua, wrote:
> On zaterdag 23 juni 2018 21:10:27 CEST Saloni Kalra wrote:
> > Thank you for your reply. I removes all the migrations and dropped the
> > database. Now when I try to make migrations i get the following error in
> my
> >
On zaterdag 23 juni 2018 21:10:27 CEST Saloni Kalra wrote:
> Thank you for your reply. I removes all the migrations and dropped the
> database. Now when I try to make migrations i get the following error in my
> terminal.
> Thanks and regards,
> Saloni
>
> *Error:*
> accounts.User.user_ptr: (field
Hi, Andrew! Thanks a lot for your response.
I've changed my consumer's connect method like this:
def connect(self):
user = self.scope.get('user')
super(NotificationsConsumer, self).connect()
if user.is_anonymous:
self.close(code=4003)
I've tested it in Chrome, Firefox, Safar
Thanks much!
On Sun, 24 Jun 2018, 5:50 pm Daniel Ale, wrote:
> Great.
>
> On Sun, Jun 24, 2018, 13:18 Saloni Kalra
> wrote:
>
>> Yes it did! Thanks much!
>>
>> On Sunday, 24 June 2018 17:14:31 UTC+5, Daniel Ale wrote:
>>>
>>> Override the get_success_url(self) instead... That will work
>>>
>>>
Great.
On Sun, Jun 24, 2018, 13:18 Saloni Kalra wrote:
> Yes it did! Thanks much!
>
> On Sunday, 24 June 2018 17:14:31 UTC+5, Daniel Ale wrote:
>>
>> Override the get_success_url(self) instead... That will work
>>
>> On Sun, Jun 24, 2018, 07:13 Saloni Kalra wrote:
>>
>>> *DeleteView:*
>>>
>>> c
Yes it did! Thanks much!
On Sunday, 24 June 2018 17:14:31 UTC+5, Daniel Ale wrote:
>
> Override the get_success_url(self) instead... That will work
>
> On Sun, Jun 24, 2018, 07:13 Saloni Kalra > wrote:
>
>> *DeleteView:*
>>
>> class DeletePost(LoginRequiredMixin, SelectRelatedMixin,
>> generic.
Override the get_success_url(self) instead... That will work
On Sun, Jun 24, 2018, 07:13 Saloni Kalra wrote:
> *DeleteView:*
>
> class DeletePost(LoginRequiredMixin, SelectRelatedMixin,
> generic.DeleteView):
> username = self.object.user.username
> model = models.Post
> select_relat
On 23/06/2018 6:17 PM, Melvyn Sopacua wrote:
On zaterdag 23 juni 2018 02:01:06 CEST Mike Dewhirst wrote:
Is there a python singleton pattern which might work?
No, cause the startup is done in 2 different processes which do not share
state. So both processes will have a "new singleton".
This is
15 matches
Mail list logo