microsoft / MLOpsPython

MLOps using Azure ML Services and Azure DevOps
MIT License
1.21k stars 1.1k forks source link

Ci pipeline fails during determine if evaluation succeeded and new model is registered (CLI) (cannot import name 'PROFILE_METADATA_CPU_KEY' from 'azureml._model_management._constants') #330

Closed mouhannadali closed 4 years ago

mouhannadali commented 4 years ago

the ci pipeline is failing at the step (determine if evaluation succeeded and new model is registered (CLI) ) reason: cannot import name 'PROFILE_METADATA_CPU_KEY' from 'azureml._model_management._constants'

image

cannot import name 'PROFILE_METADATA_CPU_KEY' from 'azureml._model_management._constants' (/usr/local/envs/mlopspython_ci/lib/python3.7/site-packages/azureml/_model_management/_constants.py) Traceback (most recent call last): File "/usr/local/envs/mlopspython_ci/lib/python3.7/site-packages/knack/cli.py", line 215, in invoke cmd_result = self.invocation.execute(args) File "/usr/local/envs/mlopspython_ci/lib/python3.7/site-packages/azure/cli/core/commands/init.py", line 546, in execute self.commands_loader.load_arguments(command) File "/usr/local/envs/mlopspython_ci/lib/python3.7/site-packages/azure/cli/core/init.py", line 330, in load_arguments command_table[command].load_arguments() # this loads the arguments via reflection File "/usr/local/envs/mlopspython_ci/lib/python3.7/site-packages/azure/cli/core/commands/init.py", line 309, in load_arguments super(AzCliCommand, self).load_arguments() File "/usr/local/envs/mlopspython_ci/lib/python3.7/site-packages/knack/commands.py", line 105, in load_arguments cmd_args = self.arguments_loader() File "/usr/local/envs/mlopspython_ci/lib/python3.7/site-packages/azure/cli/core/init.py", line 534, in default_arguments_loader op = handler or self.get_op_handler(operation, operation_group=kwargs.get('operation_group')) File "/usr/local/envs/mlopspython_ci/lib/python3.7/site-packages/azure/cli/core/init.py", line 574, in get_op_handler op = import_module(mod_to_import) File "/usr/local/envs/mlopspython_ci/lib/python3.7/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1006, in _gcd_import File "", line 983, in _find_and_load File "", line 967, in _find_and_load_unlocked File "", line 677, in _load_unlocked File "", line 728, in exec_module File "", line 219, in _call_with_frames_removed File "/__w/_temp/.azclitask/cliextensions/azure-cli-ml/azext_ml/model.py", line 17, in from azureml._model_management._constants import ACI_WEBSERVICE_TYPE, AKS_ENDPOINT_TYPE, AKS_WEBSERVICE_TYPE, \ ImportError: cannot import name 'PROFILE_METADATA_CPU_KEY' from 'azureml._model_management._constants' (/usr/local/envs/mlopspython_ci/lib/python3.7/site-packages/azureml/_model_management/_constants.py)

j-so commented 4 years ago

I have updated the public docker image and updated the ci_dependencies. Please run again and reopen if you're still seeing the issue!