diff options
Diffstat (limited to 'websocket/_wsdump.py')
-rwxr-xr-x | websocket/_wsdump.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/websocket/_wsdump.py b/websocket/_wsdump.py index 860ac34..757c359 100755 --- a/websocket/_wsdump.py +++ b/websocket/_wsdump.py @@ -160,7 +160,7 @@ def main(): except websocket.WebSocketException: return websocket.ABNF.OPCODE_CLOSE, None if not frame: - raise websocket.WebSocketException("Not a valid frame %s" % frame) + raise websocket.WebSocketException("Not a valid frame {frame}".format(frame=frame)) elif frame.opcode in OPCODE_DATA: return frame.opcode, frame.data elif frame.opcode == websocket.ABNF.OPCODE_CLOSE: @@ -193,7 +193,7 @@ def main(): data = repr(data) if args.verbose: - msg = "%s: %s" % (websocket.ABNF.OPCODE_MAP.get(opcode), data) + msg = "{opcode}: {data}".format(opcode=websocket.ABNF.OPCODE_MAP.get(opcode), data=data) else: msg = data |