'What should happen if a disconnect is detected?  The return
value of this function is returned from read functions in case
the client went away.  By default a
:exc:`~werkzeug.exceptions.ClientDisconnected` exception is raised.'

def on_disconnect(self):

    from werkzeug.exceptions import ClientDisconnected
    raise ClientDisconnected()
