web_socket_client_protocol is re-defining a name which is already available in the outer-scope (previously defined on line 13).
It is generally a bad practice to shadow variables from the outer-scope. In most
cases, this is done unintentionally and might lead to unexpected behavior:
param=5classFoo:def__init__(self,param):# "param" would be flagged hereself.param=param
web_socket_client_protocol is re-defining a name which is already available in the outer-scope (previously defined on line 13).
It is generally a bad practice to shadow variables from the outer-scope. In most
cases, this is done unintentionally and might lead to unexpected behavior:
param=5classFoo:def__init__(self,param):# "param" would be flagged hereself.param=param