diff --git a/paddlehub/config.py b/paddlehub/config.py index 5d0bfa70114f062be17959f80128a6f61641d615..26b6f19beaaea2727e7906552a86cc15e58ebca8 100644 --- a/paddlehub/config.py +++ b/paddlehub/config.py @@ -113,7 +113,7 @@ def _load_old_config(config: HubConfig): with open(old_cfg_file) as file: try: cfg = json.loads(file.read()) - config.server = cfg['server_url'] + config.server = cfg['server_url'][0] config.log_level = cfg['log_level'] except: ... diff --git a/paddlehub/server/server.py b/paddlehub/server/server.py index c015db8d8c561b47bd43eeb3075c6d586f91af12..a3fd822fbcbda8333405679c860d56dd80bd0dbe 100644 --- a/paddlehub/server/server.py +++ b/paddlehub/server/server.py @@ -109,7 +109,7 @@ class HubServer(object): '''Get the version compatibility information of the model.''' sources = self.sources.values() if not source else [self._generate_source(source)] for source in sources: - result = source.get_module_info(name=name) + result = source.get_module_compat_info(name=name) if result: return result return {}