From 0367334aab94aa888449c6b66f83bcc9746c81bf Mon Sep 17 00:00:00 2001 From: hanhxiao Date: Thu, 26 Sep 2019 15:34:56 +0800 Subject: [PATCH] fix(service): fix error message --- gnes/proto/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnes/proto/__init__.py b/gnes/proto/__init__.py index 7e3073aa..47f91380 100644 --- a/gnes/proto/__init__.py +++ b/gnes/proto/__init__.py @@ -155,14 +155,14 @@ def check_msg_version(msg: 'gnes_pb2.Message'): msg.envelope.proto_version, __proto_version__)) if hasattr(msg.envelope, 'vcs_version'): - if not msg.envelope.vcs_version or not os.environ.get('GNES_VCS_VERSION', ''): + if not msg.envelope.vcs_version or not os.environ.get('GNES_VCS_VERSION'): default_logger.warning('incoming message contains empty "vcs_version", ' 'you may ignore it in debug/unittest mode, ' 'or if you run gnes OUTSIDE docker container where GNES_VCS_VERSION is unset' 'otherwise please check if frontend service set correct version') elif os.environ.get('GNES_VCS_VERSION') != msg.envelope.vcs_version: raise AttributeError('mismatched vcs version! ' - 'incoming message has protobuf version %s, whereas local protobuf version %s' % ( + 'incoming message has vcs_version %s, whereas local environment vcs_version is %s' % ( msg.envelope.vcs_version, os.environ.get('GNES_VCS_VERSION'))) if not hasattr(msg.envelope, 'proto_version') and not hasattr(msg.envelope, 'gnes_version'):