You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The MLflow Community encourages bug fix contributions. Would you or another member of your organization be willing to contribute a fix for this bug to the MLflow code base?
Yes. I can contribute a fix for this bug independently.
Yes. I would be willing to contribute a fix for this bug with guidance from the MLflow community.
No. I cannot contribute a bug fix at this time.
System information
Have I written custom code (as opposed to using a stock example script provided in MLflow): No
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Linux Ubuntu 20.04.3 LTS
MLflow installed from (source or binary): binary (pip)
MLflow version (run mlflow --version): 1.22.0
Python version: 3.9.5
npm version, if running the dev UI: -
Exact command to reproduce: -
Describe the problem
If you pass a dictionary variable to the start_run() function, it may modify the dictionary. On child runs, the mlflow.parentRunId tag is set and updated on the variable, making it persistent for later (non-nested) runs.
Code to reproduce issue
importmlflowGLOBAL_TAGS= {'custom': 'tag'}
withmlflow.start_run(tags=GLOBAL_TAGS) asrun:
run_id=run.info.run_idassertrun.data.tags.get('mlflow.parentRunId') isNone# Should be Nonewithmlflow.start_run(tags=GLOBAL_TAGS, nested=True) aschild_run:
assertchild_run.data.tags.get('mlflow.parentRunId') ==run_idwithmlflow.start_run(tags=GLOBAL_TAGS) asrun:
assertrun.data.tags.get('mlflow.parentRunId') isNone# Should be None
This code raises the following error on my machine:
Traceback (most recent call last):
File "/home/matheus/mlflow_bug/bug.py", line 14, in <module>
assert run.data.tags.get('mlflow.parentRunId') is run_id
AssertionError
Other info / logs
I believe the issue can be fixed by changing the following lines:
tags is a parameter of the start_run() function; it should not be overwritten. By changing the variable name to something else, the problem will hopefully be solved. I will investigate further and open a PR if I'm able to fix the issue.
What component(s), interfaces, languages, and integrations does this bug affect?
Components
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/projects: MLproject format, project running backends
area/scoring: MLflow Model server, model deployment tools, Spark UDFs
Willingness to contribute
The MLflow Community encourages bug fix contributions. Would you or another member of your organization be willing to contribute a fix for this bug to the MLflow code base?
System information
mlflow --version
): 1.22.0Describe the problem
If you pass a dictionary variable to the
start_run()
function, it may modify the dictionary. On child runs, themlflow.parentRunId
tag is set and updated on the variable, making it persistent for later (non-nested) runs.Code to reproduce issue
This code raises the following error on my machine:
Other info / logs
I believe the issue can be fixed by changing the following lines:
mlflow/mlflow/tracking/fluent.py
Lines 287 to 289 in 0fa849a
tags
is a parameter of thestart_run()
function; it should not be overwritten. By changing the variable name to something else, the problem will hopefully be solved. I will investigate further and open a PR if I'm able to fix the issue.What component(s), interfaces, languages, and integrations does this bug affect?
Components
area/artifacts
: Artifact stores and artifact loggingarea/build
: Build and test infrastructure for MLflowarea/docs
: MLflow documentation pagesarea/examples
: Example codearea/model-registry
: Model Registry service, APIs, and the fluent client calls for Model Registryarea/models
: MLmodel format, model serialization/deserialization, flavorsarea/projects
: MLproject format, project running backendsarea/scoring
: MLflow Model server, model deployment tools, Spark UDFsarea/server-infra
: MLflow Tracking server backendarea/tracking
: Tracking Service, tracking client APIs, autologgingInterface
area/uiux
: Front-end, user experience, plotting, JavaScript, JavaScript dev serverarea/docker
: Docker use across MLflow's components, such as MLflow Projects and MLflow Modelsarea/sqlalchemy
: Use of SQLAlchemy in the Tracking Service or Model Registryarea/windows
: Windows supportLanguage
language/r
: R APIs and clientslanguage/java
: Java APIs and clientslanguage/new
: Proposals for new client languagesIntegrations
integrations/azure
: Azure and Azure ML integrationsintegrations/sagemaker
: SageMaker integrationsintegrations/databricks
: Databricks integrationsThe text was updated successfully, but these errors were encountered: