I am trying to setup a simple flow for notifications. Something like:
class NotificationRouter(ModelPubRouter):
route_name = 'notification-router'
valid_verbs = ['subscribe']
model = Notification
serializer_class = NotificationSerializer
def get_subscription_channels(self, **kwargs):
return ['notification']
route_handler.register(NotificationRouter)
The serializer is just a ModelSerializer that should return the id:
class NotificationSerializer(ModelSerializer):
class Meta:
model = 'notifications.models.Notification'
publish_fields = ('id', )
On javascript i am trying to subscribe, but all i am getting is c[3001,"Connection aborted"]. The subscribe() function is not even calling it's failure function.
swampdragon.ready is being reached tho.
I can't find the cause of this error anywhere, and the dragon server is quite silent, which does not help either. What's your approach to debugging issues like these?
I am trying to setup a simple flow for notifications. Something like:
The serializer is just a ModelSerializer that should return the id:
On javascript i am trying to subscribe, but all i am getting is c[3001,"Connection aborted"]. The subscribe() function is not even calling it's failure function. swampdragon.ready is being reached tho.
I can't find the cause of this error anywhere, and the dragon server is quite silent, which does not help either. What's your approach to debugging issues like these?