[BUG] ValueError: Enum ErrorCode has no value defined for name '403' in mlflow.set_experiment()
See original GitHub issueWillingness to contribute
Yes. I would be willing to contribute a fix for this bug with guidance from the MLflow community.
MLflow version
1.19.0
System information
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Windows
- Python version: 3.10.4
- databricks-connect version: 7.3.45
Describe the problem
I am trying to run some code to train a model, while logging my results to MLflow on Databricks. I am using Databricks Connect to achieve this.
However, before I get to that step, the given error pops up when I try to make a call to mlflow.set_experiment()
.
What exactly is going on here?
I was able to run my code without an issue a while ago, but when I came back to it, I encountered this error.
Tracking information
No response
Code to reproduce issue
# set the mlflow registry and tracking URIs
mlflow.set_registry_uri(remote_server_uri)
mlflow.set_tracking_uri(remote_server_uri)
# create the MLflow client
client = MlflowClient(remote_server_uri)
# set base path for experiment
base_path = '/base/path/to/mlflow/experiments'
# set experiment to log mlflow runs
mlflow.set_experiment(base_path + experiment_name)
Note: The value set for the variable remote_server_uri
is ‘databricks’.
Stack trace
mlflow.set_experiment(base_path + experiment_name)
File "C:\Users\minurap\Anaconda3\envs\oct_use_case_2\lib\site-packages\mlflow\tracking\fluent.py", line 84, in set_experiment
experiment = client.get_experiment_by_name(experiment_name)
File "C:\Users\minurap\Anaconda3\envs\oct_use_case_2\lib\site-packages\mlflow\tracking\client.py", line 463, in get_experiment_by_name
return self._tracking_client.get_experiment_by_name(name)
File "C:\Users\minurap\Anaconda3\envs\oct_use_case_2\lib\site-packages\mlflow\tracking\_tracking_service\client.py", line 155, in get_experiment_by_name
return self.store.get_experiment_by_name(name)
File "C:\Users\minurap\Anaconda3\envs\oct_use_case_2\lib\site-packages\mlflow\store\tracking\rest_store.py", line 321, in get_experiment_by_name
response_proto = self._call_endpoint(GetExperimentByName, req_body)
File "C:\Users\minurap\Anaconda3\envs\oct_use_case_2\lib\site-packages\mlflow\store\tracking\rest_store.py", line 56, in _call_endpoint
return call_endpoint(self.get_host_creds(), endpoint, method, json_body, response_proto)
File "C:\Users\minurap\Anaconda3\envs\oct_use_case_2\lib\site-packages\mlflow\utils\rest_utils.py", line 170, in call_endpoint
response = verify_rest_response(response, endpoint)
File "C:\Users\minurap\Anaconda3\envs\oct_use_case_2\lib\site-packages\mlflow\utils\rest_utils.py", line 122, in verify_rest_response
raise RestException(json.loads(response.text))
File "C:\Users\minurap\Anaconda3\envs\oct_use_case_2\lib\site-packages\mlflow\exceptions.py", line 75, in __init__
super().__init__(message, error_code=ErrorCode.Value(error_code))
File "C:\Users\minurap\Anaconda3\envs\oct_use_case_2\lib\site-packages\google\protobuf\internal\enum_type_wrapper.py", line 82, in Value
raise ValueError('Enum {} has no value defined for name {!r}'.format(
ValueError: Enum ErrorCode has no value defined for name '403'
Other info / logs
No response
What component(s) does this bug affect?
-
area/artifacts
: Artifact stores and artifact logging -
area/build
: Build and test infrastructure for MLflow -
area/docs
: MLflow documentation pages -
area/examples
: Example code -
area/model-registry
: Model Registry service, APIs, and the fluent client calls for Model Registry -
area/models
: MLmodel format, model serialization/deserialization, flavors -
area/pipelines
: Pipelines, Pipeline APIs, Pipeline configs, Pipeline Templates -
area/projects
: MLproject format, project running backends -
area/scoring
: MLflow Model server, model deployment tools, Spark UDFs -
area/server-infra
: MLflow Tracking server backend -
area/tracking
: Tracking Service, tracking client APIs, autologging
What interface(s) does this bug affect?
-
area/uiux
: Front-end, user experience, plotting, JavaScript, JavaScript dev server -
area/docker
: Docker use across MLflow’s components, such as MLflow Projects and MLflow Models -
area/sqlalchemy
: Use of SQLAlchemy in the Tracking Service or Model Registry -
area/windows
: Windows support
What language(s) does this bug affect?
-
language/r
: R APIs and clients -
language/java
: Java APIs and clients -
language/new
: Proposals for new client languages
What integration(s) does this bug affect?
-
integrations/azure
: Azure and Azure ML integrations -
integrations/sagemaker
: SageMaker integrations -
integrations/databricks
: Databricks integrations
Issue Analytics
- State:
- Created a year ago
- Comments:5
Top Results From Across the Web
ValueError: Enum ErrorCode has no value defined for name ...
It looks like the reason I was not able to log my experiments to MLflow is because I have missed the configuration steps...
Read more >[BUG] mlflow run MLproject failed but same python command ...
Describe the problem. I have set up a MLproject like this. name: Same as project folder name conda_env: conda.yaml entry_points: main: command ...
Read more >MLflow 'invalid access token' error - Databricks Knowledge Base
Problem You have long-running MLflow tasks in your notebook or job and the tasks are not completed. Instead, they return a (403) Invalid ......
Read more >enum errorcode has no value defined for name '403' in mlflow ...
I am trying to run some code to train a model, while logging my results to MLflow on Databricks. I keep getting the...
Read more >Source code for mlflow.tracking.client
Internal package providing a Python CRUD interface to MLflow experiments, runs, registered models, and model versions. This is a lower level API than...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Since you are a Databricks customer and this issue is related to DBConnect (and perhaps your account), could you contact your support team (or file a support ticket with Databricks) for resolution and assistance in troubleshooting?
@BenWilson2 I just tried restarting my computer and running it again. No change.