Excuse me, but this is a serious issue regarding server security.
Suppose one mallicious client just sent a meaningless websocket message as big as 4GB to the django server, how can the server stops it from sending more websocket frames after realizing it has breached the size limit?
Also, I would like this error to be catched by upper functions and block this client from further logging in after kicking it offline, and record this attack.
Related discussions on stackovervlow: