Python – many to many fields in Django channels

my signals.py:

@receiver (post_save, sender = HubNotify)
def create_task_verification_notification (sender, instance, created,
** Kwargs):
if instance:
channel_layer = get_channel_layer ()
async_to_sync (channel_layer.group_send) (
"gossip", {"type": "hub.notify",
"event": "Hub Notify",
"Sender": instance.sender.id,
"accept_hub_url": resol_url ("student: accept_hub")
pk = instance.receiver.hub.id, notify = instance.sender.id),
"reject_hub_url": resol_url ("student: reject_hub")
pk = instance.rceiver.hub.id, notify = instance.sender.id),
"Notification": Instance.message

})

My customers.py:

    async def hub_notify (self, event):
Expect self.send_json (event)
print ("Got message {} at {}". format (event, self.channel_name))

My views.py where to create in the HubNotify object:

        excoms = User.objects.filter (hub_position = "E") |
User.objects.filter (hub_position = "L")
obj = HubNotify.objects
.create (sender = user, notification = request.user.username + & # 39; willing to
Join Hub & # 39;
messages.warning (request, & # 39; request sent & # 39;)
obj.receiver.add (* excoms)
obj.save ()

I'm trying to create real-time notifications using Django channels. It uses signals to check if a notification is being generated and to send data to the frontend. This is basically a hub join request, where a user can send a request to the hub, which is sent to multiple users, and anyone can accept or reject it. The parameter pk in accept_hub_url is essentially request.user.hub.id. HOW can I access request.user here?