Skip to content

CherryPy, how to pass parameters into the websocket class #164

Open
@nicklasb

Description

@nicklasb

Hi,
I have a problem, and I cannot find this information anywhere in the documentation.
I need to pass credentials into each WebSocket subclass instance, and I can find out how to.

It doesn't seem to be possible to read anything useful from the request.wsgi_environ being passed
I am not sure I understand why the request itself isn't being passed instead? self.environ isn't being used anywhere by the WebSocket itself as far as I can see, so there should be no problems with sending the request instead.

Either that, or is there a way to cut in and be the one that instantiates my web socket descendant?

Because it would seem as an unnecessary round trip to having to resend the credentials again.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions