Rename protocol muxer initiator flags
This commit is contained in:
parent
021c92ea25
commit
4bda366bb8
@ -84,14 +84,14 @@ class Multiselect(IMultiselectMuxer):
|
|||||||
except MultiselectCommunicatorError as error:
|
except MultiselectCommunicatorError as error:
|
||||||
raise MultiselectError(error)
|
raise MultiselectError(error)
|
||||||
|
|
||||||
if not validate_handshake(handshake_contents):
|
if not is_valid_handshake(handshake_contents):
|
||||||
raise MultiselectError(
|
raise MultiselectError(
|
||||||
"multiselect protocol ID mismatch: "
|
"multiselect protocol ID mismatch: "
|
||||||
f"received handshake_contents={handshake_contents}"
|
f"received handshake_contents={handshake_contents}"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
def validate_handshake(handshake_contents: str) -> bool:
|
def is_valid_handshake(handshake_contents: str) -> bool:
|
||||||
"""
|
"""
|
||||||
Determine if handshake is valid and should be confirmed
|
Determine if handshake is valid and should be confirmed
|
||||||
:param handshake_contents: contents of handshake message
|
:param handshake_contents: contents of handshake message
|
||||||
|
@ -33,7 +33,7 @@ class MultiselectClient(IMultiselectClient):
|
|||||||
except MultiselectCommunicatorError as error:
|
except MultiselectCommunicatorError as error:
|
||||||
raise MultiselectClientError(str(error))
|
raise MultiselectClientError(str(error))
|
||||||
|
|
||||||
if not validate_handshake(handshake_contents):
|
if not is_valid_handshake(handshake_contents):
|
||||||
raise MultiselectClientError("multiselect protocol ID mismatch")
|
raise MultiselectClientError("multiselect protocol ID mismatch")
|
||||||
|
|
||||||
async def select_one_of(
|
async def select_one_of(
|
||||||
@ -86,7 +86,7 @@ class MultiselectClient(IMultiselectClient):
|
|||||||
raise MultiselectClientError("unrecognized response: " + response)
|
raise MultiselectClientError("unrecognized response: " + response)
|
||||||
|
|
||||||
|
|
||||||
def validate_handshake(handshake_contents: str) -> bool:
|
def is_valid_handshake(handshake_contents: str) -> bool:
|
||||||
"""
|
"""
|
||||||
Determine if handshake is valid and should be confirmed
|
Determine if handshake is valid and should be confirmed
|
||||||
:param handshake_contents: contents of handshake message
|
:param handshake_contents: contents of handshake message
|
||||||
|
Loading…
x
Reference in New Issue
Block a user