提交 1ed226af 编写于 作者: W wuzewu

Solve the version identification problem

上级 4dc6f237
...@@ -17,7 +17,7 @@ import sys ...@@ -17,7 +17,7 @@ import sys
from easydict import EasyDict from easydict import EasyDict
__version__ = '2.0.0a0' __version__ = '2.0.0-alpha0'
from paddlehub.config import config from paddlehub.config import config
from paddlehub.utils import log, parser, utils from paddlehub.utils import log, parser, utils
......
...@@ -71,8 +71,8 @@ class ServerSource(object): ...@@ -71,8 +71,8 @@ class ServerSource(object):
# Delay module loading to improve command line speed # Delay module loading to improve command line speed
import paddle import paddle
params['hub_version'] = paddlehub.__version__ params['hub_version'] = paddlehub.__version__.split('-')[0]
params['paddle_version'] = paddle.__version__ params['paddle_version'] = paddle.__version__.split('-')[0]
result = self.request(path='search', params=params) result = self.request(path='search', params=params)
if result['status'] == 0 and len(result['data']) > 0: if result['status'] == 0 and len(result['data']) > 0:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册