Skip to content

Sync branch-2.0 with master#6510

Merged
harupy merged 83 commits intomlflow:branch-2.0from
harupy:sync-master
Aug 19, 2022
Merged

Sync branch-2.0 with master#6510
harupy merged 83 commits intomlflow:branch-2.0from
harupy:sync-master

Conversation

@harupy
Copy link
Copy Markdown
Member

@harupy harupy commented Aug 19, 2022

Related Issues/PRs

#xxx

What changes are proposed in this pull request?

Sync branch-2.0 with master

How is this patch tested?

  • I have written tests (not required for typo or doc fix) and confirmed the proposed feature/bug-fix/change works.

Does this PR change the documentation?

  • No. You can skip the rest of this section.
  • Yes. Make sure the changed pages / sections render correctly by following the steps below.
  1. Click the Details link on the Preview docs check.
  2. Find the changed pages / sections and make sure they render correctly.

Release Notes

Is this a user-facing change?

  • No. You can skip the rest of this section.
  • Yes. Give a description of this change to be included in the release notes for MLflow users.

(Details in 1-2 sentences. You can just refer to another PR with a description if this PR is part of a larger change.)

What component(s), interfaces, languages, and integrations does this PR 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/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

Interface

  • 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

Language

  • language/r: R APIs and clients
  • language/java: Java APIs and clients
  • language/new: Proposals for new client languages

Integrations

  • integrations/azure: Azure and Azure ML integrations
  • integrations/sagemaker: SageMaker integrations
  • integrations/databricks: Databricks integrations

How should the PR be classified in the release notes? Choose one:

  • rn/breaking-change - The PR will be mentioned in the "Breaking Changes" section
  • rn/none - No description will be included. The PR will be mentioned only by the PR number in the "Small Bugfixes and Documentation Updates" section
  • rn/feature - A new user-facing feature worth mentioning in the release notes
  • rn/bug-fix - A user-facing bug fix worth mentioning in the release notes
  • rn/documentation - A user-facing documentation change worth mentioning in the release notes

dbczumar and others added 30 commits July 27, 2022 11:41
…_runtime conf (mlflow#6337)

* Javafix

Signed-off-by: dbczumar <[email protected]>

* Resource fix

Signed-off-by: dbczumar <[email protected]>
* One commit

Signed-off-by: dbczumar <[email protected]>

* Submodule revert

Signed-off-by: dbczumar <[email protected]>

* Fix client tests

Signed-off-by: dbczumar <[email protected]>

* fix ci

Signed-off-by: dbczumar <[email protected]>

* Remove unused / invalid import

Signed-off-by: dbczumar <[email protected]>

* Put run summary back to end, fix tests

Signed-off-by: dbczumar <[email protected]>

* Use mocks instead

Signed-off-by: dbczumar <[email protected]>
* compute minTimestamp only once

Signed-off-by: harupy <[email protected]>

* fix method name

Signed-off-by: harupy <[email protected]>

* fix lint

Signed-off-by: harupy <[email protected]>

* return empty array

Signed-off-by: harupy <[email protected]>

* fix test

Signed-off-by: harupy <[email protected]>
* Add pool_recycle option to SQLAlchemy create_engine

Signed-off-by: Michal Karzynski <[email protected]>

* Add new option to unit test

Signed-off-by: Michal Karzynski <[email protected]>

* Add note in documentation

Signed-off-by: Michal Karzynski <[email protected]>
* Added BoxPlot

Signed-off-by: changyonglik <[email protected]>

* Fixed key error

Signed-off-by: changyonglik <[email protected]>

* Added default state

Signed-off-by: changyonglik <[email protected]>

* Fixed props passing

Signed-off-by: changyonglik <[email protected]>

* Fixed react hooks state

Signed-off-by: changyonglik <[email protected]>

* Added unit test

Signed-off-by: changyonglik <[email protected]>

* Added boxplot to CompareModelVersion

Signed-off-by: changyonglik <[email protected]>

* Changed keys numbering to reflect tab name

Signed-off-by: changyonglik <[email protected]>

* Made the ordering of tabs consistent accross CompareRunView and CompareModelVersion

Signed-off-by: changyonglik <[email protected]>

* Linted

Signed-off-by: changyonglik <[email protected]>

* Fixed FormattedMessage

Signed-off-by: changyonglik <[email protected]>

* refactoring

Signed-off-by: harupy <[email protected]>

* fix lint errors

Signed-off-by: harupy <[email protected]>

* i18n

Signed-off-by: harupy <[email protected]>

* minor comment fix

Signed-off-by: harupy <[email protected]>

Co-authored-by: harupy <[email protected]>
…lflow#6287)

* add script to update requirements.yaml

Signed-off-by: harupy <[email protected]>

* update both skinny and core requirements

Signed-off-by: harupy <[email protected]>

* remove base

Signed-off-by: harupy <[email protected]>

* clean up

Signed-off-by: harupy <[email protected]>

* add MLFLOW_CONDA_HOME

Signed-off-by: harupy <[email protected]>

* create create-pr job

Signed-off-by: harupy <[email protected]>

* fix syntax

Signed-off-by: harupy <[email protected]>

* remove redundant if

Signed-off-by: harupy <[email protected]>

* clean up

Signed-off-by: harupy <[email protected]>

* doc

Signed-off-by: harupy <[email protected]>

* dynamically determine python version

Signed-off-by: harupy <[email protected]>

* remove python version mock

Signed-off-by: harupy <[email protected]>

* use setup-ssh.sh in master.yml

Signed-off-by: harupy <[email protected]>

* simplify

Signed-off-by: harupy <[email protected]>

* update both core and skinny requirements

Signed-off-by: harupy <[email protected]>

* use env

Signed-off-by: harupy <[email protected]>

* remove action version

Signed-off-by: harupy <[email protected]>

* fix pandas dtypes issue

Signed-off-by: harupy <[email protected]>

* check if PR already exists

Signed-off-by: harupy <[email protected]>

* add semicolons

Signed-off-by: harupy <[email protected]>

* test PR creation

Signed-off-by: harupy <[email protected]>

* set base

Signed-off-by: harupy <[email protected]>

* use run_number

Signed-off-by: harupy <[email protected]>

* set result-encoding

Signed-off-by: harupy <[email protected]>

* revert changes for test

Signed-off-by: harupy <[email protected]>

* fix more tests

Signed-off-by: harupy <[email protected]>

* fix run URL

Signed-off-by: harupy <[email protected]>

* add dot

Signed-off-by: harupy <[email protected]>

* remove minimum_version

Signed-off-by: harupy <[email protected]>

* remove create-pr job

Signed-off-by: harupy <[email protected]>

* rename workflow

Signed-off-by: harupy <[email protected]>

* mutate dict approach

Signed-off-by: harupy <[email protected]>

* use ruamel

Signed-off-by: harupy <[email protected]>

* remove PYTHON_VERSION patch

Signed-off-by: harupy <[email protected]>

* add ruamel.yaml to requirements

Signed-off-by: harupy <[email protected]>

* skip update-requirements on PR

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* print new version

Signed-off-by: harupy <[email protected]>

* preserve quotes

Signed-off-by: harupy <[email protected]>

* fix badge

Signed-off-by: harupy <[email protected]>

* fix README

Signed-off-by: harupy <[email protected]>

* run ci

Signed-off-by: harupy <[email protected]>

* remove validate-requirements.yml

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* fix test_dataframe_from_json

Signed-off-by: harupy <[email protected]>
* Make model_uri optional for mlflow models build-docker

Signed-off-by: harupy <[email protected]>

* fix doc

Signed-off-by: harupy <[email protected]>

* Add generic

Signed-off-by: harupy <[email protected]>

* Add pythou_function flavor

Signed-off-by: harupy <[email protected]>

* fix doc

Signed-off-by: harupy <[email protected]>

* quotes

Signed-off-by: harupy <[email protected]>

* use longer options

Signed-off-by: harupy <[email protected]>
* Enable consider-using-dict-items

Signed-off-by: harupy <[email protected]>

* fix lint errors

Signed-off-by: harupy <[email protected]>
* Enable consider-using-from-import

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

* fix datasets import

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>
* update to run profiles on the first 100 dataframe columns

Signed-off-by: Sunish Sheth <[email protected]>

* Adding replace=True so we can sample rows twice

Signed-off-by: Sunish Sheth <[email protected]>

* Removing replace=true and fixing how the max_rows are calculated

Signed-off-by: Sunish Sheth <[email protected]>
… containing transformers (mlflow#6230)

* Fix with test case

Signed-off-by: dbczumar <[email protected]>

* Test fix

Signed-off-by: dbczumar <[email protected]>

* Fix and simplification

Signed-off-by: dbczumar <[email protected]>

* more fixes & better test coveragE

Signed-off-by: dbczumar <[email protected]>

* test

Signed-off-by: dbczumar <[email protected]>

* LGBM test

Signed-off-by: dbczumar <[email protected]>

* Format

Signed-off-by: dbczumar <[email protected]>

* Address comments

Signed-off-by: dbczumar <[email protected]>

* Fixes

Signed-off-by: dbczumar <[email protected]>

* Use py37-compatible call args syntax

Signed-off-by: dbczumar <[email protected]>
* Log runtime pipeline config to MLflow

Signed-off-by: Jin Zhang <[email protected]>

* Fixed lint

Signed-off-by: Jin Zhang <[email protected]>
* Added in name for ColSpec of pandas datatype

infer panda series name for ColSpec

Signed-off-by: Ryan Fogle <[email protected]>

* Added test for Series name inference

added one more pytest condition in test_schema:test_schema_inference_on_pandas_series

Signed-off-by: Ryan Fogle <[email protected]>

* Update test_schema.py

Added in one more assertion to test schema inference.

Signed-off-by: Ryan Fogle <[email protected]>

* ran black

Signed-off-by: Ryan Fogle <[email protected]>

* added in requested changes in issue mlflow#6361

Signed-off-by: Ryan Fogle <[email protected]>

* fix typo. changed hasattr to getattr

Signed-off-by: Ryan Fogle <[email protected]>
* remove

Signed-off-by: apurva-koti <[email protected]>

* fix

Signed-off-by: apurva-koti <[email protected]>
…odule (mlflow#6375)

* Migrate GCS environment variables to mlflow.environment_variables

Signed-off-by: harupy <[email protected]>

* add default

Signed-off-by: harupy <[email protected]>

* improve comments

Signed-off-by: harupy <[email protected]>
…ut/output dataframe contains unsupported data types (mlflow#6365)

* Avoid logging signatures

Signed-off-by: harupy <[email protected]>

* test

Signed-off-by: harupy <[email protected]>

* fix indent

Signed-off-by: harupy <[email protected]>

* check model output

Signed-off-by: harupy <[email protected]>

* fix warning message

Signed-off-by: harupy <[email protected]>

* todo

Signed-off-by: harupy <[email protected]>

* update test and doc

Signed-off-by: harupy <[email protected]>

* fix docstring

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>

* improve _assert_autolog_infers_model_signature_correctly

Signed-off-by: harupy <[email protected]>
* refacor set_matrix.py

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

* fix tests

Signed-off-by: harupy <[email protected]>

* tset for --no-dev

Signed-off-by: harupy <[email protected]>

* install pytest and pytest-cov

Signed-off-by: harupy <[email protected]>

* test for --changed-files

Signed-off-by: harupy <[email protected]>

* add pyyaml to requirements

Signed-off-by: harupy <[email protected]>

* fix is_matrix_empty

Signed-off-by: harupy <[email protected]>

* use raw string and re.match

Signed-off-by: harupy <[email protected]>
…mlflow#5897)

* allow mlflow-skinny's autolog() to succeed when no scipy is installed

Signed-off-by: Hannes Schulz <[email protected]>

* optional pyfunc scipy dependency

Signed-off-by: Hannes Schulz <[email protected]>

* fix linter-discovered issues

Signed-off-by: Hannes Schulz <[email protected]>

* add test case, autolog() should pass w/o scipy installed

Signed-off-by: Hannes Schulz <[email protected]>

* minor cleanup

Signed-off-by: Hannes Schulz <[email protected]>

* test creating _Example with / without scipy present

Signed-off-by: Hannes Schulz <[email protected]>

* docs: do not warn about sparse matrix classes

Signed-off-by: Hannes Schulz <[email protected]>

* linting

Signed-off-by: Hannes Schulz <[email protected]>

* address review comment

Signed-off-by: Hannes Schulz <[email protected]>

* run black

Signed-off-by: Hannes Schulz <[email protected]>

* allow mlflow-skinny's autolog() to succeed when no scipy is installed

Signed-off-by: Hannes Schulz <[email protected]>

* optional pyfunc scipy dependency

Signed-off-by: Hannes Schulz <[email protected]>

* fix linter-discovered issues

Signed-off-by: Hannes Schulz <[email protected]>

* add test case, autolog() should pass w/o scipy installed

Signed-off-by: Hannes Schulz <[email protected]>

* minor cleanup

Signed-off-by: Hannes Schulz <[email protected]>

* test creating _Example with / without scipy present

Signed-off-by: Hannes Schulz <[email protected]>

* docs: do not warn about sparse matrix classes

Signed-off-by: Hannes Schulz <[email protected]>

* linting

Signed-off-by: Hannes Schulz <[email protected]>

* address review comment

Signed-off-by: Hannes Schulz <[email protected]>

* run black

Signed-off-by: Hannes Schulz <[email protected]>

* remove redundant None check after import

Signed-off-by: Hannes Schulz <[email protected]>

* delete comment

Signed-off-by: Hannes Schulz <[email protected]>

* Revert "remove redundant None check after import"

This reverts commit f2e198c.

Signed-off-by: Hannes Schulz <[email protected]>

* review comments

Signed-off-by: Hannes Schulz <[email protected]>

* remove redundant test

Signed-off-by: Hannes Schulz <[email protected]>

* Apply suggestions from code review

Co-authored-by: Harutaka Kawamura <[email protected]>
Signed-off-by: Hannes Schulz <[email protected]>

* Autoformat: https://github.com/mlflow/mlflow/actions/runs/2779791161

Signed-off-by: mlflow-automation <[email protected]>

Co-authored-by: Harutaka Kawamura <[email protected]>
Co-authored-by: dbczumar <[email protected]>
Co-authored-by: mlflow-automation <[email protected]>
jonwiggins and others added 21 commits August 11, 2022 23:40
Signed-off-by: jonwiggins <[email protected]>

Signed-off-by: jonwiggins <[email protected]>
* Fix

Signed-off-by: dbczumar <[email protected]>

* Doc fix

Signed-off-by: dbczumar <[email protected]>

* Fix

Signed-off-by: dbczumar <[email protected]>

Signed-off-by: dbczumar <[email protected]>
Signed-off-by: Jenkins <[email protected]>

Signed-off-by: Jenkins <[email protected]>
Co-authored-by: Jenkins <[email protected]>
Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>
…#6460)

* Add environment variable for echo

Signed-off-by: harupy <[email protected]>

* use _BooleanEnvironmentVariable

Signed-off-by: harupy <[email protected]>

* address comments

Signed-off-by: harupy <[email protected]>

* address comments and add tests

Signed-off-by: harupy <[email protected]>

* fix comment

Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>
Signed-off-by: Мартынов Максим Сергеевич <[email protected]>

Signed-off-by: Мартынов Максим Сергеевич <[email protected]>
Signed-off-by: harupy <[email protected]>
Co-authored-by: harupy <[email protected]>
mlflow#6463)

* do not construct maven proxy options at top level

Signed-off-by: harupy <[email protected]>

* fix validation for port

Signed-off-by: harupy <[email protected]>

* unpack

Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>
* Fix

Signed-off-by: dbczumar <[email protected]>

* Fix

Signed-off-by: dbczumar <[email protected]>

* Reverts

Signed-off-by: dbczumar <[email protected]>

* Better fix

Signed-off-by: dbczumar <[email protected]>

* Format

Signed-off-by: dbczumar <[email protected]>

* Format

Signed-off-by: dbczumar <[email protected]>

* Lint

Signed-off-by: dbczumar <[email protected]>

* Clean up

Signed-off-by: dbczumar <[email protected]>

Signed-off-by: dbczumar <[email protected]>
* replace assertRaisesRegex with pytest.raises

Signed-off-by: harupy <[email protected]>

* fix message

Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>
* CLI command suggestion after running the pipeline

Signed-off-by: Hubert Zub <[email protected]>

* fix: added git commands to MLP CLI suggestion

* chore: lint fixes

Signed-off-by: Hubert Zub <[email protected]>

* chore: test fixes

Signed-off-by: Hubert Zub <[email protected]>

Signed-off-by: Hubert Zub <[email protected]>
…6478)

* Improve code-to-reproduce section

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

* problem -> issue

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>
* changes

Signed-off-by: apurva-koti <[email protected]>

* changes

Signed-off-by: apurva-koti <[email protected]>

* partial-test

Signed-off-by: apurva-koti <[email protected]>

* lint

Signed-off-by: apurva-koti <[email protected]>

* missed

Signed-off-by: apurva-koti <[email protected]>

* review

Signed-off-by: apurva-koti <[email protected]>

Signed-off-by: apurva-koti <[email protected]>
* Implement _download_file in hdfs_artifact_repo

Signed-off-by: bowen_who <[email protected]>

* add ut on _download_file in test_hdfs_artifact_repo

Signed-off-by: bowen_who <[email protected]>

* rewrite _download_artifact, change back _download_file in hdfs_artifact_repo

Signed-off-by: bowen_who <[email protected]>
Signed-off-by: harupy <[email protected]>

* rewrite test__download_file in test_hdfs_artifact_repo

Signed-off-by: bowen_who <[email protected]>

Signed-off-by: bowen_who <[email protected]>
Signed-off-by: harupy <[email protected]>
Co-authored-by: bowen_who <[email protected]>
* R bug fix

* Documentation fix

* Revert breaking change

* Updated doc file

* Doc fix

* Testing a broken test

* fix

* Revert test
* feat: return param value for mlflow.log_param

Signed-off-by: Xinyue Ruan <[email protected]>

* update docstring and return value for MlflowClient

Signed-off-by: Xinyue Ruan <[email protected]>

Signed-off-by: Xinyue Ruan <[email protected]>
Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>
* Migrated s3

Signed-off-by: changyonglik <[email protected]>

* Migrated s3 for local.py

Signed-off-by: changyonglik <[email protected]>

* Changed default values

Signed-off-by: changyonglik <[email protected]>

* Added var imports

Signed-off-by: changyonglik <[email protected]>

* Added MLFLOW_S3_ENDPOINT_URL and MLFLOW_S3_IGNORE_TLS

Signed-off-by: changyonglik <[email protected]>

* Removed duplicated imports

Signed-off-by: changyonglik <[email protected]>

* Paraphrased specify to specifies

Signed-off-by: changyonglik <[email protected]>

* Changed _EnvironmentVariable to _BooleanEnvironmentVariable for MLFLOW_S3_IGNORE_TLS and defaults to False

Signed-off-by: changyonglik <[email protected]>

* Changed environment variables in hdfs_artifact_repo.py

Signed-off-by: changyonglik <[email protected]>

* Changed single to double quotes

Signed-off-by: changyonglik <[email protected]>

* Fixed comments

Signed-off-by: changyonglik <[email protected]>

* Small fixes

Signed-off-by: dbczumar <[email protected]>

* Format

Signed-off-by: dbczumar <[email protected]>

* Reset submodule

Signed-off-by: dbczumar <[email protected]>

Signed-off-by: changyonglik <[email protected]>
Signed-off-by: dbczumar <[email protected]>
Co-authored-by: dbczumar <[email protected]>
Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>
Signed-off-by: harupy <[email protected]>
@harupy
Copy link
Copy Markdown
Member Author

harupy commented Aug 19, 2022

Diff between master and branch-2.0

Open
diff --git a/.github/workflows/master.yml b/.github/workflows/master.yml
index 96aa8dca1..fc5829f5e 100644
--- a/.github/workflows/master.yml
+++ b/.github/workflows/master.yml
@@ -197,6 +197,7 @@ jobs:
           repository: ${{ github.event.inputs.repository }}
           ref: ${{ github.event.inputs.ref }}
       - uses: ./.github/actions/setup-python
+      - uses: ./.github/actions/setup-pyenv
       - uses: ./.github/actions/setup-java
       - name: Install dependencies
         run: |
diff --git a/.github/workflows/r.yml b/.github/workflows/r.yml
index f8f682cd6..bc3a70df7 100644
--- a/.github/workflows/r.yml
+++ b/.github/workflows/r.yml
@@ -30,6 +30,11 @@ jobs:
         submodules: recursive
         repository: ${{ github.event.inputs.repository }}
         ref: ${{ github.event.inputs.ref }}
+    - uses: ./.github/actions/setup-python
+    - uses: ./.github/actions/setup-pyenv
+    - name: Install virtualenv
+      run: |
+        pip install virtualenv
     - uses: ./.github/actions/setup-java
     - uses: r-lib/actions/setup-r@v2
     # This step dumps the current set of R dependencies and R version into files to be used
diff --git a/docs/source/R-api.rst b/docs/source/R-api.rst
index 9596dbdb2..95225e067 100644
--- a/docs/source/R-api.rst
+++ b/docs/source/R-api.rst
@@ -1627,7 +1627,7 @@ https://www.mlflow.org/docs/latest/cli.html#mlflow-run for more info.
      experiment_name = NULL,
      backend = NULL,
      backend_config = NULL,
-     no_conda = FALSE,
+     env_manager = NULL,
      storage_dir = NULL
    )
 
@@ -1666,13 +1666,11 @@ Arguments
 |                               | describe the cluster to use when     |
 |                               | launching a run on Databricks.       |
 +-------------------------------+--------------------------------------+
-| ``no_conda``                  | If specified, assume that MLflow is  |
-|                               | running within a Conda environment   |
-|                               | with the necessary dependencies for  |
-|                               | the current project instead of       |
-|                               | attempting to create a new Conda     |
-|                               | environment. Only valid if running   |
-|                               | locally.                             |
+| ``env_manager``               | If specified, create an environment  |
+|                               | for the project using the specified  |
+|                               | environment manager. Available       |
+|                               | options are ‘local’, ‘virtualenv’,   |
+|                               | and ‘conda’.                         |
 +-------------------------------+--------------------------------------+
 | ``storage_dir``               | Valid only when ``backend`` is       |
 |                               | local. MLflow downloads artifacts    |
diff --git a/docs/source/quickstart.rst b/docs/source/quickstart.rst
index 91e9624c0..f0d81fbaf 100644
--- a/docs/source/quickstart.rst
+++ b/docs/source/quickstart.rst
@@ -155,8 +155,8 @@ projects log their Tracking API data in the local ``mlruns`` directory so you ca
 runs using ``mlflow ui``.
 
 .. note::
-    By default ``mlflow run`` installs all dependencies using `conda <https://conda.io/>`_.
-    To run a project without using ``conda``, you can provide the ``--no-conda`` option to
+    By default ``mlflow run`` installs all dependencies using `virtualenv <https://virtualenv.pypa.io/en/latest//>`_.
+    To run a project without using ``virtualenv``, you can provide the ``--env-manager=local`` option to
     ``mlflow run``. In this case, you must ensure that the necessary dependencies are already installed
     in your Python environment.
 
diff --git a/mlflow/R/mlflow/R/project-run.R b/mlflow/R/mlflow/R/project-run.R
index 2193e423f..9eaf78b96 100644
--- a/mlflow/R/mlflow/R/project-run.R
+++ b/mlflow/R/mlflow/R/project-run.R
@@ -31,9 +31,8 @@
 #' @param backend Execution backend to use for run.
 #' @param backend_config Path to JSON file which will be passed to the backend. For the Databricks backend,
 #'   it should describe the cluster to use when launching a run on Databricks.
-#' @param no_conda If specified, assume that MLflow is running within a Conda environment with the necessary
-#'   dependencies for the current project instead of attempting to create a new Conda environment. Only
-#'   valid if running locally.
+#' @param env_manager If specified, create an environment for the project using the specified environment manager.
+#'   Available options are 'local', 'virtualenv', and 'conda'.
 #' @param storage_dir Valid only when `backend` is local. MLflow downloads artifacts from distributed URIs passed to
 #'  parameters of type `path` to subdirectories of `storage_dir`.
 #'
@@ -42,7 +41,7 @@
 #' @export
 mlflow_run <- function(uri = ".", entry_point = NULL, version = NULL, parameters = NULL,
                        experiment_id = NULL, experiment_name = NULL, backend = NULL, backend_config = NULL,
-                       no_conda = FALSE, storage_dir = NULL) {
+                       env_manager = NULL, storage_dir = NULL) {
   if (!is.null(experiment_name) && !is.null(experiment_id)) {
     stop("Specify only one of `experiment_name` or `experiment_id`.")
   }
@@ -64,9 +63,9 @@ mlflow_run <- function(uri = ".", entry_point = NULL, version = NULL, parameters
     mlflow_cli_param("--backend", backend) %>%
     mlflow_cli_param("--backend-config", backend_config) %>%
     mlflow_cli_param("--storage-dir", storage_dir) %>%
+    mlflow_cli_param("--env-manager", env_manager) %>%
     c(param_list)
 
-  args <- if (!no_conda) args else c(args, "--no-conda")
   result <- do.call(mlflow_cli, c("run", args))
   matches <- regexec(".*Run \\(ID \\'([^\\']+).*", result$stderr)
   run_id <- regmatches(result$stderr, matches)[[1]][[2]]
diff --git a/mlflow/R/mlflow/man/mlflow_run.Rd b/mlflow/R/mlflow/man/mlflow_run.Rd
index 5c5322814..1bbc990ff 100644
--- a/mlflow/R/mlflow/man/mlflow_run.Rd
+++ b/mlflow/R/mlflow/man/mlflow_run.Rd
@@ -13,7 +13,7 @@ mlflow_run(
   experiment_name = NULL,
   backend = NULL,
   backend_config = NULL,
-  no_conda = FALSE,
+  env_manager = NULL,
   storage_dir = NULL
 )
 }
@@ -35,9 +35,8 @@ mlflow_run(
 \item{backend_config}{Path to JSON file which will be passed to the backend. For the Databricks backend,
 it should describe the cluster to use when launching a run on Databricks.}
 
-\item{no_conda}{If specified, assume that MLflow is running within a Conda environment with the necessary
-dependencies for the current project instead of attempting to create a new Conda environment. Only
-valid if running locally.}
+\item{env_manager}{If specified, create an environment for the project using the specified environment manager.
+Available options are 'local', 'virtualenv', and 'conda'.}
 
 \item{storage_dir}{Valid only when `backend` is local. MLflow downloads artifacts from distributed URIs passed to
 parameters of type `path` to subdirectories of `storage_dir`.}
diff --git a/mlflow/cli.py b/mlflow/cli.py
index fabb1b0eb..51676ae1d 100644
--- a/mlflow/cli.py
+++ b/mlflow/cli.py
@@ -113,8 +113,7 @@ def cli():
     "provided is different for each execution backend and is documented "
     "at https://www.mlflow.org/docs/latest/projects.html.",
 )
-@cli_args.NO_CONDA
-@cli_args.ENV_MANAGER
+@cli_args.ENV_MANAGER_PROJECTS
 @click.option(
     "--storage-dir",
     envvar="MLFLOW_TMP_DIR",
@@ -145,7 +144,6 @@ def run(
     experiment_id,
     backend,
     backend_config,
-    no_conda,  # pylint: disable=unused-argument
     env_manager,
     storage_dir,
     run_id,
diff --git a/mlflow/models/cli.py b/mlflow/models/cli.py
index ca14812f6..64f391c0a 100644
--- a/mlflow/models/cli.py
+++ b/mlflow/models/cli.py
@@ -30,7 +30,6 @@ def commands():
 @cli_args.HOST
 @cli_args.TIMEOUT
 @cli_args.WORKERS
-@cli_args.NO_CONDA
 @cli_args.ENV_MANAGER
 @cli_args.INSTALL_MLFLOW
 @cli_args.ENABLE_MLSERVER
@@ -40,7 +39,6 @@ def serve(
     host,
     timeout,
     workers,
-    no_conda,  # pylint: disable=unused-argument
     env_manager=None,
     install_mlflow=False,
     enable_mlserver=False,
@@ -64,7 +62,7 @@ def serve(
             "data": [[1, 2, 3], [4, 5, 6]]
         }'
     """
-    env_manager = env_manager or _EnvManager.CONDA
+    env_manager = env_manager or _EnvManager.VIRTUALENV
     return _get_flavor_backend(
         model_uri, env_manager=env_manager, workers=workers, install_mlflow=install_mlflow
     ).serve(
@@ -101,7 +99,6 @@ def serve(
     "https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.read_json"
     ".html",
 )
-@cli_args.NO_CONDA
 @cli_args.ENV_MANAGER
 @cli_args.INSTALL_MLFLOW
 def predict(
@@ -110,7 +107,6 @@ def predict(
     output_path,
     content_type,
     json_format,
-    no_conda,  # pylint: disable=unused-argument
     env_manager,
     install_mlflow,
 ):
@@ -119,7 +115,7 @@ def predict(
     data formats accepted by this function, see the following documentation:
     https://www.mlflow.org/docs/latest/models.html#built-in-deployment-tools.
     """
-    env_manager = env_manager or _EnvManager.CONDA
+    env_manager = env_manager or _EnvManager.VIRTUALENV
     if content_type == "json" and json_format not in ("split", "records"):
         raise Exception("Unsupported json format '{}'.".format(json_format))
     return _get_flavor_backend(
@@ -135,12 +131,10 @@ def predict(
 
 @commands.command("prepare-env")
 @cli_args.MODEL_URI
-@cli_args.NO_CONDA
 @cli_args.ENV_MANAGER
 @cli_args.INSTALL_MLFLOW
 def prepare_env(
     model_uri,
-    no_conda,  # pylint: disable=unused-argument
     env_manager,
     install_mlflow,
 ):
@@ -149,7 +143,7 @@ def prepare_env(
     downloading dependencies or initializing a conda environment. After preparation,
     calling predict or serve should be fast.
     """
-    env_manager = env_manager or _EnvManager.CONDA
+    env_manager = env_manager or _EnvManager.VIRTUALENV
     return _get_flavor_backend(
         model_uri, env_manager=env_manager, install_mlflow=install_mlflow
     ).prepare_env(model_uri=model_uri)
@@ -205,7 +199,7 @@ def build_docker(model_uri, name, env_manager, mlflow_home, install_mlflow, enab
     See https://www.mlflow.org/docs/latest/python_api/mlflow.pyfunc.html for more information on the
     'python_function' flavor.
     """
-    env_manager = env_manager or _EnvManager.CONDA
+    env_manager = env_manager or _EnvManager.VIRTUALENV
     _get_flavor_backend(model_uri, docker_build=True, env_manager=env_manager).build_image(
         model_uri,
         name,
diff --git a/mlflow/projects/_project_spec.py b/mlflow/projects/_project_spec.py
index ff9dc82a3..a07088159 100644
--- a/mlflow/projects/_project_spec.py
+++ b/mlflow/projects/_project_spec.py
@@ -9,6 +9,7 @@ from mlflow.exceptions import ExecutionException
 from mlflow.tracking import artifact_utils
 from mlflow.utils.file_utils import get_local_path_or_none
 from mlflow.utils.string_utils import is_string_type
+from mlflow.utils.environment import _PYTHON_ENV_FILE_NAME
 from mlflow.projects import env_type
 
 MLPROJECT_FILE_NAME = "mlproject"
@@ -118,6 +119,16 @@ def load_project(directory):
             name=project_name,
         )
 
+    default_python_env_path = os.path.join(directory, _PYTHON_ENV_FILE_NAME)
+    if os.path.exists(default_python_env_path):
+        return Project(
+            env_type=env_type.PYTHON,
+            env_config_path=default_python_env_path,
+            entry_points=entry_points,
+            docker_env=None,
+            name=project_name,
+        )
+
     default_conda_path = os.path.join(directory, DEFAULT_CONDA_FILE_NAME)
     if os.path.exists(default_conda_path):
         return Project(
diff --git a/mlflow/pyfunc/__init__.py b/mlflow/pyfunc/__init__.py
index 894a60f44..b1191ca71 100644
--- a/mlflow/pyfunc/__init__.py
+++ b/mlflow/pyfunc/__init__.py
@@ -918,7 +918,7 @@ def _get_or_create_env_root_dir(should_use_nfs):
 _MLFLOW_SERVER_OUTPUT_TAIL_LINES_TO_KEEP = 200
 
 
-def spark_udf(spark, model_uri, result_type="double", env_manager="local"):
+def spark_udf(spark, model_uri, result_type="double", env_manager=_EnvManager.VIRTUALENV):
     """
     A Spark UDF that can be used to invoke the Python function formatted model.
 
@@ -994,13 +994,13 @@ def spark_udf(spark, model_uri, result_type="double", env_manager="local"):
     :param env_manager: The environment manager to use in order to create the python environment
                         for model inference. Note that environment is only restored in the context
                         of the PySpark UDF; the software environment outside of the UDF is
-                        unaffected. Default value is ``local``, and the following values are
+                        unaffected. Default value is ``virtualenv``, and the following values are
                         supported:
 
-                         - ``conda``: (Recommended) Use Conda to restore the software environment
-                           that was used to train the model.
                          - ``virtualenv``: Use virtualenv to restore the python environment that
                            was used to train the model.
+                         - ``conda``: (Recommended) Use Conda to restore the software environment
+                           that was used to train the model.
                          - ``local``: Use the current Python environment for model inference, which
                            may differ from the environment used to train the model and may lead to
                            errors or invalid predictions.
diff --git a/mlflow/sagemaker/cli.py b/mlflow/sagemaker/cli.py
index 2102c60de..a23b1d6d4 100644
--- a/mlflow/sagemaker/cli.py
+++ b/mlflow/sagemaker/cli.py
@@ -578,7 +578,7 @@ def build_and_push_container(build, push, container, env_manager, mlflow_home):
     The image is built locally and it requires Docker to run.
     The image is pushed to ECR under current active AWS account and to current active AWS region.
     """
-    env_manager = env_manager or em.CONDA
+    env_manager = env_manager or em.VIRTUALENV
     if not (build or push):
         click.echo("skipping both build and push, have nothing to do!")
     if build:
diff --git a/mlflow/utils/cli_args.py b/mlflow/utils/cli_args.py
index 38039d0b8..13a7ad4e4 100644
--- a/mlflow/utils/cli_args.py
+++ b/mlflow/utils/cli_args.py
@@ -56,38 +56,8 @@ RUN_ID = click.option(
     help="ID of the MLflow run that generated the referenced content.",
 )
 
-NO_CONDA = click.option(
-    "--no-conda",
-    is_flag=True,
-    help="This flag is deprecated. Use `--env-manager=local` instead. "
-    "If specified, will assume that MLmodel/MLproject is running within "
-    "a Conda environment with the necessary dependencies for "
-    "the current project instead of attempting to create a new "
-    "conda environment.",
-)
 
-
-def _resolve_env_manager(ctx, _, env_manager):
-    no_conda = ctx.params.get("no_conda", False)
-    # Both `--no-conda` and `--env-manager` are specified
-    if no_conda and env_manager is not None:
-        raise click.BadParameter(
-            "`--no-conda` (deprecated) and `--env-manager` cannot be used at the same time."
-        )
-
-    # Only `--no-conda` is specified
-    if no_conda:
-        warnings.warn(
-            (
-                "`--no-conda` is deprecated and will be removed in a future MLflow release. "
-                "Use `--env-manager=local` instead."
-            ),
-            FutureWarning,
-            stacklevel=2,
-        )
-        return _EnvManager.LOCAL
-
-    # Only `--env-manager` is specified
+def _resolve_env_manager(_, __, env_manager):
     if env_manager is not None:
         _EnvManager.validate(env_manager)
         if env_manager == _EnvManager.VIRTUALENV:
@@ -101,27 +71,48 @@ def _resolve_env_manager(ctx, _, env_manager):
             )
         return env_manager
 
-    # Neither `--no-conda` nor `--env-manager` is specified
     return None
 
 
-ENV_MANAGER = click.option(
-    "--env-manager",
-    default=None,
-    type=click.UNPROCESSED,
-    callback=_resolve_env_manager,
+def _create_env_manager_option(help_string):
+    return click.option(
+        "--env-manager",
+        default=None,
+        type=click.UNPROCESSED,
+        callback=_resolve_env_manager,
+        help=help_string,
+    )
+
+
+ENV_MANAGER = _create_env_manager_option(
     # '\b' prevents rewrapping text:
     # https://click.palletsprojects.com/en/8.1.x/documentation/#preventing-rewrapping
-    help="""
-If specified, create an environment for MLmodel/MLproject using the specified
+    help_string="""
+If specified, create an environment for MLmodel using the specified
 environment manager. The following values are supported:
 
 \b
 - local: use the local environment
+- virtualenv: use virtualenv (and pyenv for Python version management)
 - conda: use conda
+
+If unspecified, default to virtualenv.
+""",
+)
+
+ENV_MANAGER_PROJECTS = _create_env_manager_option(
+    help_string="""
+If specified, create an environment for MLproject using the specified
+environment manager. The following values are supported:
+
+\b
+- local: use the local environment
 - virtualenv: use virtualenv (and pyenv for Python version management)
+- conda: use conda
 
-If unspecified, default to conda.
+If unspecified, the appropriate environment manager is automatically selected based on
+the project configuration. For example, if `MLproject.yaml` contains a `python_env` key,
+virtualenv is used.
 """,
 )
 
diff --git a/mlflow/utils/environment.py b/mlflow/utils/environment.py
index 4d6b455ed..7e1116d82 100644
--- a/mlflow/utils/environment.py
+++ b/mlflow/utils/environment.py
@@ -1,7 +1,6 @@
 import yaml
 import os
 import logging
-import sys
 import re
 import hashlib
 
@@ -64,15 +63,11 @@ class _PythonEnv:
     @classmethod
     def current(cls):
         return cls(
-            python=cls._get_current_python(),
+            python=PYTHON_VERSION,
             build_dependencies=cls.get_current_build_dependencies(),
             dependencies=[f"-r {_REQUIREMENTS_FILE_NAME}"],
         )
 
-    @staticmethod
-    def _get_current_python():
-        return ".".join(map(str, sys.version_info[:3]))
-
     @staticmethod
     def _get_package_version(package_name):
         try:
@@ -159,10 +154,11 @@ class _PythonEnv:
                 )
 
         if python is None:
-            raise MlflowException(
-                f"Could not extract python version from {path}",
-                error_code=INVALID_PARAMETER_VALUE,
+            _logger.warning(
+                f"{path} does not include a python version specification. "
+                f"Using the current python version {PYTHON_VERSION}."
             )
+            python = PYTHON_VERSION
 
         if unmatched_dependencies:
             _logger.warning(
diff --git a/mlflow/utils/virtualenv.py b/mlflow/utils/virtualenv.py
index 4ffeabfab..156902efc 100644
--- a/mlflow/utils/virtualenv.py
+++ b/mlflow/utils/virtualenv.py
@@ -6,7 +6,9 @@ import re
 from pathlib import Path
 from packaging.version import Version
 
+import mlflow
 from mlflow.exceptions import MlflowException
+from mlflow.models.model import Model, MLMODEL_FILE_NAME
 from mlflow.utils.process import _exec_cmd, _join_commands, _IS_UNIX
 from mlflow.utils.requirements_utils import _parse_requirements
 from mlflow.utils.environment import (
@@ -147,6 +149,15 @@ def _install_python(version, pyenv_root=None, capture_output=False):
     return Path(pyenv_root).joinpath("versions", version, *path_to_bin)
 
 
+def _get_conda_env_file(mlmodel_file):
+    for flavor, config in Model.load(mlmodel_file).flavors.items():
+        if flavor == mlflow.pyfunc.FLAVOR_NAME:
+            env = config.get(mlflow.pyfunc.ENV)
+            if env:
+                return env
+    return _CONDA_ENV_FILE_NAME
+
+
 def _get_python_env(local_model_path):
     """
     Constructs `_PythonEnv` from the model artifacts stored in `local_model_path`. If
@@ -160,7 +171,8 @@ def _get_python_env(local_model_path):
     """
     python_env_file = local_model_path / _PYTHON_ENV_FILE_NAME
     requirements_file = local_model_path / _REQUIREMENTS_FILE_NAME
-    conda_env_file = local_model_path / _CONDA_ENV_FILE_NAME
+    conda_env_file = local_model_path / _get_conda_env_file(local_model_path / MLMODEL_FILE_NAME)
+
     if python_env_file.exists():
         return _PythonEnv.from_yaml(python_env_file)
     else:
diff --git a/tests/models/test_cli.py b/tests/models/test_cli.py
index cd3713c5f..dc0087b04 100644
--- a/tests/models/test_cli.py
+++ b/tests/models/test_cli.py
@@ -133,7 +133,15 @@ def test_mlflow_is_not_installed_unless_specified():
         _mlflow_conda_env(path=os.path.join(fake_model_path, "conda.yaml"), install_mlflow=False)
         # The following should fail because there should be no mlflow in the env:
         p = subprocess.Popen(
-            ["mlflow", "models", "predict", "-m", fake_model_path],
+            [
+                "mlflow",
+                "models",
+                "predict",
+                "-m",
+                fake_model_path,
+                "--env-manager",
+                "conda",
+            ],
             stderr=subprocess.PIPE,
             cwd=tmp.path(""),
         )
@@ -398,7 +406,7 @@ def test_prepare_env_fails(sk_model):
     with TempDir(chdr=True):
         with mlflow.start_run() as active_run:
             mlflow.sklearn.log_model(
-                sk_model, "model", conda_env={"dependencies": ["mlflow-does-not-exist-dep==abc"]}
+                sk_model, "model", pip_requirements=["does-not-exist-dep==abc"]
             )
             model_uri = "runs:/{run_id}/model".format(run_id=active_run.info.run_id)
 
@@ -528,30 +536,6 @@ def _validate_with_rest_endpoint(scoring_proc, host_port, df, x, sk_model, enabl
 patch_get_flavor_backend = mock.patch("mlflow.models.cli._get_flavor_backend")
 
 
-@patch_get_flavor_backend
-def test_env_manager_deprecation_warning_is_raised_when_no_conda_is_specified(mock_flavor_backend):
-    with pytest.warns(FutureWarning, match=r"--no-conda.+deprecated"):
-        CliRunner().invoke(
-            models_cli.serve,
-            ["--model-uri", "model", "--no-conda"],
-            catch_exceptions=False,
-        )
-    mock_flavor_backend.assert_called_once()
-
-
-def test_env_manager_specifying_both_no_conda_and_env_manager_is_not_allowed():
-    res = CliRunner().invoke(
-        models_cli.serve,
-        ["--model-uri", "model", "--no-conda", "--env-manager=local"],
-        catch_exceptions=False,
-    )
-    assert res.exit_code != 0
-    assert (
-        "`--no-conda` (deprecated) and `--env-manager` cannot be used at the same time."
-        in res.stdout
-    )
-
-
 def test_env_manager_unsupported_value():
     with pytest.raises(ValueError, match=r"Invalid value for `env_manager`"):
         CliRunner().invoke(
diff --git a/tests/projects/test_kubernetes.py b/tests/projects/test_kubernetes.py
index 2f0c0438a..88d620d5f 100644
--- a/tests/projects/test_kubernetes.py
+++ b/tests/projects/test_kubernetes.py
@@ -59,7 +59,7 @@ def test_valid_kubernetes_job_spec():  # pylint: disable=unused-argument
     project_name = "mlflow-docker-example"
     image_tag = "image_tag"
     image_digest = "5e74a5a"
-    command = ["mlflow", "run", ".", "--no-conda", "-P", "alpha=0.5"]
+    command = ["mlflow", "run", ".", "--env-manager", "local", "-P", "alpha=0.5"]
     env_vars = {"RUN_ID": "1"}
     job_definition = kb._get_kubernetes_job_definition(
         project_name=project_name,
diff --git a/tests/projects/test_projects_cli.py b/tests/projects/test_projects_cli.py
index d8a8b8d6b..69f36f22c 100644
--- a/tests/projects/test_projects_cli.py
+++ b/tests/projects/test_projects_cli.py
@@ -125,8 +125,8 @@ def test_run_git_https():
     # Invoke command twice to ensure we set Git state in an isolated manner (e.g. don't attempt to
     # create a git repo in the same directory twice, etc)
     assert GIT_PROJECT_URI.startswith("https")
-    invoke_cli_runner(cli.run, [GIT_PROJECT_URI, "--no-conda", "-P", "alpha=0.5"])
-    invoke_cli_runner(cli.run, [GIT_PROJECT_URI, "--no-conda", "-P", "alpha=0.5"])
+    invoke_cli_runner(cli.run, [GIT_PROJECT_URI, "--env-manager", "local", "-P", "alpha=0.5"])
+    invoke_cli_runner(cli.run, [GIT_PROJECT_URI, "--env-manager", "local", "-P", "alpha=0.5"])
 
 
 @pytest.mark.skipif(
@@ -137,8 +137,8 @@ def test_run_git_ssh():
     # where SSH keys are unavailable. However it should be run locally whenever logic related to
     # running Git projects is modified.
     assert SSH_PROJECT_URI.startswith("git@")
-    invoke_cli_runner(cli.run, [SSH_PROJECT_URI, "--no-conda", "-P", "alpha=0.5"])
-    invoke_cli_runner(cli.run, [SSH_PROJECT_URI, "--no-conda", "-P", "alpha=0.5"])
+    invoke_cli_runner(cli.run, [SSH_PROJECT_URI, "--env-manager", "local", "-P", "alpha=0.5"])
+    invoke_cli_runner(cli.run, [SSH_PROJECT_URI, "--env-manager", "local", "-P", "alpha=0.5"])
 
 
 @pytest.mark.notrackingurimock
diff --git a/tests/projects/test_virtualenv_projects.py b/tests/projects/test_virtualenv_projects.py
index 8a2bf27f4..bfa877fa0 100644
--- a/tests/projects/test_virtualenv_projects.py
+++ b/tests/projects/test_virtualenv_projects.py
@@ -6,7 +6,11 @@ import mlflow
 from mlflow.exceptions import MlflowException
 from mlflow.utils.virtualenv import _create_virtualenv
 
-from tests.projects.utils import TEST_VIRTUALENV_PROJECT_DIR, TEST_VIRTUALENV_CONDA_PROJECT_DIR
+from tests.projects.utils import (
+    TEST_VIRTUALENV_PROJECT_DIR,
+    TEST_VIRTUALENV_CONDA_PROJECT_DIR,
+    TEST_VIRTUALENV_NO_PYTHON_ENV,
+)
 
 
 spy_on_create_virtualenv = mock.patch(
@@ -32,6 +36,17 @@ def test_virtualenv_project_execution_without_env_manager(create_virtualenv_spy)
     create_virtualenv_spy.assert_called_once()
 
 
+@spy_on_create_virtualenv
+def test_virtualenv_project_execution_no_python_env(create_virtualenv_spy):
+    """
+    When an MLproject file doesn't contain a `python_env` key but python_env.yaml exists,
+    virtualenv should be used as an environment manager.
+    """
+    submitted_run = mlflow.projects.run(TEST_VIRTUALENV_NO_PYTHON_ENV, entry_point="test")
+    submitted_run.wait()
+    create_virtualenv_spy.assert_called_once()
+
+
 @spy_on_create_virtualenv
 def test_virtualenv_project_execution_local(create_virtualenv_spy):
     submitted_run = mlflow.projects.run(
diff --git a/tests/projects/utils.py b/tests/projects/utils.py
index 6eee0a4d9..dbe391fef 100644
--- a/tests/projects/utils.py
+++ b/tests/projects/utils.py
@@ -18,6 +18,9 @@ TEST_VIRTUALENV_PROJECT_DIR = os.path.join(TEST_DIR, "resources", "example_virtu
 TEST_VIRTUALENV_CONDA_PROJECT_DIR = os.path.join(
     TEST_DIR, "resources", "example_virtualenv_conda_project"
 )
+TEST_VIRTUALENV_NO_PYTHON_ENV = os.path.join(
+    TEST_DIR, "resources", "example_virtualenv_no_python_env"
+)
 TEST_PROJECT_NAME = "example_project"
 TEST_NO_SPEC_PROJECT_DIR = os.path.join(TEST_DIR, "resources", "example_project_no_spec")
 GIT_PROJECT_URI = "https://github.com/mlflow/mlflow-example"
diff --git a/tests/pyfunc/test_spark.py b/tests/pyfunc/test_spark.py
index bf0e08c54..58faa5cd7 100644
--- a/tests/pyfunc/test_spark.py
+++ b/tests/pyfunc/test_spark.py
@@ -44,7 +44,9 @@ types = [np.int32, int, str, np.float32, np.double]
 def score_model_as_udf(model_uri, pandas_df, result_type="double"):
     spark = get_spark_session(pyspark.SparkConf())
     spark_df = spark.createDataFrame(pandas_df).coalesce(1)
-    pyfunc_udf = spark_udf(spark=spark, model_uri=model_uri, result_type=result_type)
+    pyfunc_udf = spark_udf(
+        spark=spark, model_uri=model_uri, result_type=result_type, env_manager="local"
+    )
     new_df = spark_df.withColumn("prediction", pyfunc_udf(*pandas_df.columns))
     return [x["prediction"] for x in new_df.collect()]
 
@@ -149,12 +151,12 @@ def test_spark_udf(spark, model_path):
                     expected = expected.astype(np.float32)
 
             expected = [list(row[1]) if is_array else row[1][0] for row in expected.iterrows()]
-            pyfunc_udf = spark_udf(spark, model_path, result_type=t)
+            pyfunc_udf = spark_udf(spark, model_path, result_type=t, env_manager="local")
             new_df = spark_df.withColumn("prediction", pyfunc_udf(*pandas_df.columns))
             actual = list(new_df.select("prediction").toPandas()["prediction"])
             assert expected == actual
             if not is_array:
-                pyfunc_udf = spark_udf(spark, model_path, result_type=tname)
+                pyfunc_udf = spark_udf(spark, model_path, result_type=tname, env_manager="local")
                 new_df = spark_df.withColumn("prediction", pyfunc_udf(*pandas_df.columns))
                 actual = list(new_df.select("prediction").toPandas()["prediction"])
                 assert expected == actual
@@ -219,7 +221,7 @@ def test_spark_udf_env_manager_predict_sklearn_model(spark, sklearn_model, model
 def test_spark_udf_with_single_arg(spark):
     class TestModel(PythonModel):
         def predict(self, context, model_input):
-            return [",".join(model_input.columns.tolist())] * len(model_input)
+            return [",".join(map(str, model_input.columns.tolist()))] * len(model_input)
 
     with mlflow.start_run() as run:
         mlflow.pyfunc.log_model("model", python_model=TestModel())
@@ -254,7 +256,10 @@ def test_spark_udf_autofills_no_arguments(spark):
     with mlflow.start_run() as run:
         mlflow.pyfunc.log_model("model", python_model=TestModel(), signature=signature)
         udf = mlflow.pyfunc.spark_udf(
-            spark, "runs:/{}/model".format(run.info.run_id), result_type=ArrayType(StringType())
+            spark,
+            "runs:/{}/model".format(run.info.run_id),
+            result_type=ArrayType(StringType()),
+            env_manager="local",
         )
         res = good_data.withColumn("res", udf()).select("res").toPandas()
         assert res["res"][0] == ["a", "b", "c"]
@@ -314,7 +319,10 @@ def test_spark_udf_autofills_column_names_with_schema(spark):
     with mlflow.start_run() as run:
         mlflow.pyfunc.log_model("model", python_model=TestModel(), signature=signature)
         udf = mlflow.pyfunc.spark_udf(
-            spark, "runs:/{}/model".format(run.info.run_id), result_type=ArrayType(StringType())
+            spark,
+            "runs:/{}/model".format(run.info.run_id),
+            result_type=ArrayType(StringType()),
+            env_manager="local",
         )
         data = spark.createDataFrame(
             pd.DataFrame(
@@ -342,7 +350,10 @@ def test_spark_udf_with_datetime_columns(spark):
     with mlflow.start_run() as run:
         mlflow.pyfunc.log_model("model", python_model=TestModel(), signature=signature)
         udf = mlflow.pyfunc.spark_udf(
-            spark, "runs:/{}/model".format(run.info.run_id), result_type=ArrayType(StringType())
+            spark,
+            "runs:/{}/model".format(run.info.run_id),
+            result_type=ArrayType(StringType()),
+            env_manager="local",
         )
         data = spark.range(10).selectExpr(
             "current_timestamp() as timestamp", "current_date() as date"
diff --git a/tests/resources/example_virtualenv_no_python_env/MLproject b/tests/resources/example_virtualenv_no_python_env/MLproject
new file mode 100644
index 000000000..c9ec2ba86
--- /dev/null
+++ b/tests/resources/example_virtualenv_no_python_env/MLproject
@@ -0,0 +1,6 @@
+name: virtualenv-example
+entry_points:
+  main:
+    command: 'python entrypoint.py'
+  test:
+    command: 'python entrypoint.py --test'
diff --git a/tests/resources/example_virtualenv_no_python_env/entrypoint.py b/tests/resources/example_virtualenv_no_python_env/entrypoint.py
new file mode 100644
index 000000000..b3d8bcf93
--- /dev/null
+++ b/tests/resources/example_virtualenv_no_python_env/entrypoint.py
@@ -0,0 +1,33 @@
+import argparse
+import os
+import sys
+
+import numpy as np
+import sklearn
+from sklearn.pipeline import make_pipeline
+from sklearn.preprocessing import StandardScaler
+from sklearn.svm import SVC
+
+import mlflow
+
+parser = argparse.ArgumentParser()
+parser.add_argument(
+    "--test",
+    action="store_true",
+    help="If specified, check this script is running in a virtual environment created by mlflow "
+    "and python and sickit-learn versions are correct.",
+)
+args = parser.parse_args()
+if args.test:
+    assert "VIRTUAL_ENV" in os.environ
+    assert sys.version_info[:3] == (3, 8, 13), sys.version_info
+    assert sklearn.__version__ == "1.0.2", sklearn.__version__
+
+X = np.array([[-1, -1], [-2, -1], [1, 1], [2, 1]])
+y = np.array([1, 1, 2, 2])
+
+clf = make_pipeline(StandardScaler(), SVC(gamma="auto"))
+clf.fit(X, y)
+
+with mlflow.start_run():
+    mlflow.sklearn.log_model(clf, artifact_path="model")
diff --git a/tests/resources/example_virtualenv_no_python_env/python_env.yaml b/tests/resources/example_virtualenv_no_python_env/python_env.yaml
new file mode 100644
index 000000000..09423cdd6
--- /dev/null
+++ b/tests/resources/example_virtualenv_no_python_env/python_env.yaml
@@ -0,0 +1,5 @@
+python: "3.8.13"
+build_dependencies:
+  - pip
+dependencies:
+  - -r requirements.txt
diff --git a/tests/resources/example_virtualenv_no_python_env/requirements.txt b/tests/resources/example_virtualenv_no_python_env/requirements.txt
new file mode 100644
index 000000000..b84714fd2
--- /dev/null
+++ b/tests/resources/example_virtualenv_no_python_env/requirements.txt
@@ -0,0 +1,3 @@
+mlflow
+scikit-learn==1.0.2
+protobuf<4.0.0
diff --git a/tests/utils/test_python_env.py b/tests/utils/test_python_env.py
index 538928cd4..4286307cf 100644
--- a/tests/utils/test_python_env.py
+++ b/tests/utils/test_python_env.py
@@ -2,6 +2,7 @@ import pytest
 from unittest import mock
 
 from mlflow.utils.environment import _PythonEnv
+from mlflow.utils import PYTHON_VERSION
 
 
 def test_constructor_argument_validation():
@@ -88,7 +89,7 @@ dependencies:
     assert python_env.dependencies == ["a", "b"]
 
 
-def test_from_conda_yaml_python_dependency_is_missing(tmp_path):
+def test_from_conda_yaml_use_current_python_version_when_no_python_spec_in_conda_yaml(tmp_path):
     content = """
 name: example
 channels:
@@ -101,8 +102,7 @@ dependencies:
 """
     yaml_path = tmp_path / "conda.yaml"
     yaml_path.write_text(content)
-    with pytest.raises(Exception, match="Could not extract python version"):
-        _PythonEnv.from_conda_yaml(yaml_path)
+    assert _PythonEnv.from_conda_yaml(yaml_path).python == PYTHON_VERSION
 
 
 def test_from_conda_yaml_invalid_python_comparator(tmp_path):

@harupy harupy changed the base branch from master to branch-2.0 August 19, 2022 07:20
Copy link
Copy Markdown
Collaborator

@dbczumar dbczumar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@github-actions
Copy link
Copy Markdown
Contributor

@github-actions github-actions bot added the rn/none List under Small Changes in Changelogs. label Aug 19, 2022
@harupy harupy merged commit 095833b into mlflow:branch-2.0 Aug 19, 2022
BenWilson2 added a commit that referenced this pull request Oct 27, 2022
* Rebase `branch-2.0` on master (#6467)

* Fix java model server compatibility with models containing databricks_runtime conf (#6337)

* Javafix

Signed-off-by: dbczumar <[email protected]>

* Resource fix

Signed-off-by: dbczumar <[email protected]>

* Add run / model links to MLP train step card (#6294)

* One commit

Signed-off-by: dbczumar <[email protected]>

* Submodule revert

Signed-off-by: dbczumar <[email protected]>

* Fix client tests

Signed-off-by: dbczumar <[email protected]>

* fix ci

Signed-off-by: dbczumar <[email protected]>

* Remove unused / invalid import

Signed-off-by: dbczumar <[email protected]>

* Put run summary back to end, fix tests

Signed-off-by: dbczumar <[email protected]>

* Use mocks instead

Signed-off-by: dbczumar <[email protected]>

* Fix inefficient relative time computation for metric plot (#6341)

* compute minTimestamp only once

Signed-off-by: harupy <[email protected]>

* fix method name

Signed-off-by: harupy <[email protected]>

* fix lint

Signed-off-by: harupy <[email protected]>

* return empty array

Signed-off-by: harupy <[email protected]>

* fix test

Signed-off-by: harupy <[email protected]>

* Add `MLFLOW_SQLALCHEMYSTORE_POOL_RECYCLE` flag (#6344)

* Add pool_recycle option to SQLAlchemy create_engine

Signed-off-by: Michal Karzynski <[email protected]>

* Add new option to unit test

Signed-off-by: Michal Karzynski <[email protected]>

* Add note in documentation

Signed-off-by: Michal Karzynski <[email protected]>

* Add box plot in compare-runs page (#6308)

* Added BoxPlot

Signed-off-by: changyonglik <[email protected]>

* Fixed key error

Signed-off-by: changyonglik <[email protected]>

* Added default state

Signed-off-by: changyonglik <[email protected]>

* Fixed props passing

Signed-off-by: changyonglik <[email protected]>

* Fixed react hooks state

Signed-off-by: changyonglik <[email protected]>

* Added unit test

Signed-off-by: changyonglik <[email protected]>

* Added boxplot to CompareModelVersion

Signed-off-by: changyonglik <[email protected]>

* Changed keys numbering to reflect tab name

Signed-off-by: changyonglik <[email protected]>

* Made the ordering of tabs consistent accross CompareRunView and CompareModelVersion

Signed-off-by: changyonglik <[email protected]>

* Linted

Signed-off-by: changyonglik <[email protected]>

* Fixed FormattedMessage

Signed-off-by: changyonglik <[email protected]>

* refactoring

Signed-off-by: harupy <[email protected]>

* fix lint errors

Signed-off-by: harupy <[email protected]>

* i18n

Signed-off-by: harupy <[email protected]>

* minor comment fix

Signed-off-by: harupy <[email protected]>

Co-authored-by: harupy <[email protected]>

* Add script and workflow to update requirements.yaml specifications (#6287)

* add script to update requirements.yaml

Signed-off-by: harupy <[email protected]>

* update both skinny and core requirements

Signed-off-by: harupy <[email protected]>

* remove base

Signed-off-by: harupy <[email protected]>

* clean up

Signed-off-by: harupy <[email protected]>

* add MLFLOW_CONDA_HOME

Signed-off-by: harupy <[email protected]>

* create create-pr job

Signed-off-by: harupy <[email protected]>

* fix syntax

Signed-off-by: harupy <[email protected]>

* remove redundant if

Signed-off-by: harupy <[email protected]>

* clean up

Signed-off-by: harupy <[email protected]>

* doc

Signed-off-by: harupy <[email protected]>

* dynamically determine python version

Signed-off-by: harupy <[email protected]>

* remove python version mock

Signed-off-by: harupy <[email protected]>

* use setup-ssh.sh in master.yml

Signed-off-by: harupy <[email protected]>

* simplify

Signed-off-by: harupy <[email protected]>

* update both core and skinny requirements

Signed-off-by: harupy <[email protected]>

* use env

Signed-off-by: harupy <[email protected]>

* remove action version

Signed-off-by: harupy <[email protected]>

* fix pandas dtypes issue

Signed-off-by: harupy <[email protected]>

* check if PR already exists

Signed-off-by: harupy <[email protected]>

* add semicolons

Signed-off-by: harupy <[email protected]>

* test PR creation

Signed-off-by: harupy <[email protected]>

* set base

Signed-off-by: harupy <[email protected]>

* use run_number

Signed-off-by: harupy <[email protected]>

* set result-encoding

Signed-off-by: harupy <[email protected]>

* revert changes for test

Signed-off-by: harupy <[email protected]>

* fix more tests

Signed-off-by: harupy <[email protected]>

* fix run URL

Signed-off-by: harupy <[email protected]>

* add dot

Signed-off-by: harupy <[email protected]>

* remove minimum_version

Signed-off-by: harupy <[email protected]>

* remove create-pr job

Signed-off-by: harupy <[email protected]>

* rename workflow

Signed-off-by: harupy <[email protected]>

* mutate dict approach

Signed-off-by: harupy <[email protected]>

* use ruamel

Signed-off-by: harupy <[email protected]>

* remove PYTHON_VERSION patch

Signed-off-by: harupy <[email protected]>

* add ruamel.yaml to requirements

Signed-off-by: harupy <[email protected]>

* skip update-requirements on PR

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* print new version

Signed-off-by: harupy <[email protected]>

* preserve quotes

Signed-off-by: harupy <[email protected]>

* fix badge

Signed-off-by: harupy <[email protected]>

* fix README

Signed-off-by: harupy <[email protected]>

* run ci

Signed-off-by: harupy <[email protected]>

* remove validate-requirements.yml

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* fix test_dataframe_from_json

Signed-off-by: harupy <[email protected]>

* Make `model_uri` optional for `mlflow models build-docker` (#6302)

* Make model_uri optional for mlflow models build-docker

Signed-off-by: harupy <[email protected]>

* fix doc

Signed-off-by: harupy <[email protected]>

* Add generic

Signed-off-by: harupy <[email protected]>

* Add pythou_function flavor

Signed-off-by: harupy <[email protected]>

* fix doc

Signed-off-by: harupy <[email protected]>

* quotes

Signed-off-by: harupy <[email protected]>

* use longer options

Signed-off-by: harupy <[email protected]>

* add index (#6347)

Signed-off-by: harupy <[email protected]>

* fix badge link (#6349)

Signed-off-by: harupy <[email protected]>

* Enable consider-using-dict-items rule for pylint (#6351)

* Enable consider-using-dict-items

Signed-off-by: harupy <[email protected]>

* fix lint errors

Signed-off-by: harupy <[email protected]>

* Enable consider-merging-isinstance (#6350)

Signed-off-by: harupy <[email protected]>

* Enable consider-using-from-import rule for pylint (#6352)

* Enable consider-using-from-import

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

* fix datasets import

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>

* Run model registry sqlalchemy tests in database job (#6353)

Signed-off-by: harupy <[email protected]>

* update to run profiles on the first 100 dataframe columns (#6297)

* update to run profiles on the first 100 dataframe columns

Signed-off-by: Sunish Sheth <[email protected]>

* Adding replace=True so we can sample rows twice

Signed-off-by: Sunish Sheth <[email protected]>

* Removing replace=true and fixing how the max_rows are calculated

Signed-off-by: Sunish Sheth <[email protected]>

* Fix sklearn autologging input example & signature mutation for models containing transformers (#6230)

* Fix with test case

Signed-off-by: dbczumar <[email protected]>

* Test fix

Signed-off-by: dbczumar <[email protected]>

* Fix and simplification

Signed-off-by: dbczumar <[email protected]>

* more fixes & better test coveragE

Signed-off-by: dbczumar <[email protected]>

* test

Signed-off-by: dbczumar <[email protected]>

* LGBM test

Signed-off-by: dbczumar <[email protected]>

* Format

Signed-off-by: dbczumar <[email protected]>

* Address comments

Signed-off-by: dbczumar <[email protected]>

* Fixes

Signed-off-by: dbczumar <[email protected]>

* Use py37-compatible call args syntax

Signed-off-by: dbczumar <[email protected]>

* use list (#6363)

Signed-off-by: harupy <[email protected]>

* Log runtime pipeline config to MLflow (#6359)

* Log runtime pipeline config to MLflow

Signed-off-by: Jin Zhang <[email protected]>

* Fixed lint

Signed-off-by: Jin Zhang <[email protected]>

* Add status badge for stale action (#6372)

Signed-off-by: harupy <[email protected]>

* Add stack trace section to bug report template (#6374)

Signed-off-by: harupy <[email protected]>

* Skipping the transform step by using Functional transformer (#6362)

Signed-off-by: Sunish Sheth <[email protected]>

* Series schema (#6361)

* Added in name for ColSpec of pandas datatype

infer panda series name for ColSpec

Signed-off-by: Ryan Fogle <[email protected]>

* Added test for Series name inference

added one more pytest condition in test_schema:test_schema_inference_on_pandas_series

Signed-off-by: Ryan Fogle <[email protected]>

* Update test_schema.py

Added in one more assertion to test schema inference.

Signed-off-by: Ryan Fogle <[email protected]>

* ran black

Signed-off-by: Ryan Fogle <[email protected]>

* added in requested changes in issue #6361

Signed-off-by: Ryan Fogle <[email protected]>

* fix typo. changed hasattr to getattr

Signed-off-by: Ryan Fogle <[email protected]>

* integrate mlflowdbfs (#6282)

Signed-off-by: Brian Barnes <[email protected]>

* Fix step card display breakage in Jupyter notebooks (#6378)

* remove

Signed-off-by: apurva-koti <[email protected]>

* fix

Signed-off-by: apurva-koti <[email protected]>

* Avoid using flask 2.2.0 (#6380)

Signed-off-by: harupy <[email protected]>

* Migrate GCS environment variables to `mlflow.environment_variables` module (#6375)

* Migrate GCS environment variables to mlflow.environment_variables

Signed-off-by: harupy <[email protected]>

* add default

Signed-off-by: harupy <[email protected]>

* improve comments

Signed-off-by: harupy <[email protected]>

* Avoid logging model signatures in pyspark ML autologging if model input/output dataframe contains unsupported data types (#6365)

* Avoid logging signatures

Signed-off-by: harupy <[email protected]>

* test

Signed-off-by: harupy <[email protected]>

* fix indent

Signed-off-by: harupy <[email protected]>

* check model output

Signed-off-by: harupy <[email protected]>

* fix warning message

Signed-off-by: harupy <[email protected]>

* todo

Signed-off-by: harupy <[email protected]>

* update test and doc

Signed-off-by: harupy <[email protected]>

* fix docstring

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>

* improve _assert_autolog_infers_model_signature_correctly

Signed-off-by: harupy <[email protected]>

* Refactor `set_matrix.py` (#6373)

* refacor set_matrix.py

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

* fix tests

Signed-off-by: harupy <[email protected]>

* tset for --no-dev

Signed-off-by: harupy <[email protected]>

* install pytest and pytest-cov

Signed-off-by: harupy <[email protected]>

* test for --changed-files

Signed-off-by: harupy <[email protected]>

* add pyyaml to requirements

Signed-off-by: harupy <[email protected]>

* fix is_matrix_empty

Signed-off-by: harupy <[email protected]>

* use raw string and re.match

Signed-off-by: harupy <[email protected]>

* Fix is_matrix_empty (#6385)

Signed-off-by: harupy <[email protected]>

* Allow mlflow-skinny's autolog() to succeed when no scipy is installed (#5897)

* allow mlflow-skinny's autolog() to succeed when no scipy is installed

Signed-off-by: Hannes Schulz <[email protected]>

* optional pyfunc scipy dependency

Signed-off-by: Hannes Schulz <[email protected]>

* fix linter-discovered issues

Signed-off-by: Hannes Schulz <[email protected]>

* add test case, autolog() should pass w/o scipy installed

Signed-off-by: Hannes Schulz <[email protected]>

* minor cleanup

Signed-off-by: Hannes Schulz <[email protected]>

* test creating _Example with / without scipy present

Signed-off-by: Hannes Schulz <[email protected]>

* docs: do not warn about sparse matrix classes

Signed-off-by: Hannes Schulz <[email protected]>

* linting

Signed-off-by: Hannes Schulz <[email protected]>

* address review comment

Signed-off-by: Hannes Schulz <[email protected]>

* run black

Signed-off-by: Hannes Schulz <[email protected]>

* allow mlflow-skinny's autolog() to succeed when no scipy is installed

Signed-off-by: Hannes Schulz <[email protected]>

* optional pyfunc scipy dependency

Signed-off-by: Hannes Schulz <[email protected]>

* fix linter-discovered issues

Signed-off-by: Hannes Schulz <[email protected]>

* add test case, autolog() should pass w/o scipy installed

Signed-off-by: Hannes Schulz <[email protected]>

* minor cleanup

Signed-off-by: Hannes Schulz <[email protected]>

* test creating _Example with / without scipy present

Signed-off-by: Hannes Schulz <[email protected]>

* docs: do not warn about sparse matrix classes

Signed-off-by: Hannes Schulz <[email protected]>

* linting

Signed-off-by: Hannes Schulz <[email protected]>

* address review comment

Signed-off-by: Hannes Schulz <[email protected]>

* run black

Signed-off-by: Hannes Schulz <[email protected]>

* remove redundant None check after import

Signed-off-by: Hannes Schulz <[email protected]>

* delete comment

Signed-off-by: Hannes Schulz <[email protected]>

* Revert "remove redundant None check after import"

This reverts commit f2e198c944f41d9a96c20ae471d71bff39431b48.

Signed-off-by: Hannes Schulz <[email protected]>

* review comments

Signed-off-by: Hannes Schulz <[email protected]>

* remove redundant test

Signed-off-by: Hannes Schulz <[email protected]>

* Apply suggestions from code review

Co-authored-by: Harutaka Kawamura <[email protected]>
Signed-off-by: Hannes Schulz <[email protected]>

* Autoformat: https://github.com/mlflow/mlflow/actions/runs/2779791161

Signed-off-by: mlflow-automation <[email protected]>

Co-authored-by: Harutaka Kawamura <[email protected]>
Co-authored-by: dbczumar <[email protected]>
Co-authored-by: mlflow-automation <[email protected]>

* Fix extraneous warning about pyspark evaluation truncation (#6389)

* Revert #6380 (#6386)

* revert

Signed-off-by: harupy <[email protected]>

* workaround for test_prometheus_exporter

Signed-off-by: harupy <[email protected]>

* nit

Signed-off-by: harupy <[email protected]>

* Validate metric value in `FileStore.log_metric` (#6381)

* add failing test

Signed-off-by: harupy <[email protected]>

* use _validate_metric

Signed-off-by: harupy <[email protected]>

* fix invalid metric timestamp

Signed-off-by: harupy <[email protected]>

* fix docstring

Signed-off-by: harupy <[email protected]>

* fix java test

Signed-off-by: harupy <[email protected]>

* Make search experiment by tag key comparison case sensitive in MYSQL (#6333)

* init

Signed-off-by: Weichen Xu <[email protected]>

* add test

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* fix BINARY conditions in MySQL

Signed-off-by: harupy <[email protected]>

* fix attr error

Signed-off-by: harupy <[email protected]>

Co-authored-by: harupy <[email protected]>

* Run Model Registry SQLAlchemy tests in PostgreSQL, MySQL, and MSSQL (#6390)

* Run Model Registry SQLAlchemy tests in postgres, mysql, and mssql

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>

* remove uuid

Signed-off-by: harupy <[email protected]>

* clean up

Signed-off-by: harupy <[email protected]>

* do not drop tables

Signed-off-by: harupy <[email protected]>

* Fix filestore data loss on failed write & mitigate read / write race condition (#6388)

* Fix

Signed-off-by: dbczumar <[email protected]>

* Fix

Signed-off-by: dbczumar <[email protected]>

* Format

Signed-off-by: dbczumar <[email protected]>

* Added a custom filter from_json to render_and_merge_yaml (#6368)

* Added a custom filter from_json to render_and_merge_yaml

Signed-off-by: Jin Zhang <[email protected]>

* Fixed test

Signed-off-by: Jin Zhang <[email protected]>

* Update tests/utils/test_file_utils.py

Co-authored-by: Siddharth Murching <[email protected]>

* Update tests/utils/test_file_utils.py

Co-authored-by: Siddharth Murching <[email protected]>

* Fixed test

Signed-off-by: Jin Zhang <[email protected]>

* Fixed windows test attempt

Signed-off-by: Jin Zhang <[email protected]>

* Fixed windows test

Signed-off-by: Jin Zhang <[email protected]>

Co-authored-by: Siddharth Murching <[email protected]>

* Fix `!=` operator for MySQL (#6397)

* fix ne operator and improve tests

Signed-off-by: harupy <[email protected]>

* add () to other operators

Signed-off-by: harupy <[email protected]>

* Simplify the documentation section in the PR template (#6398)

* Simplify the documentation section in the PR template

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

* Timebased gc (#6354)

* Added delete_time field to runs table

Signed-off-by: Jason Cheng <[email protected]>

* Updated latest_schema.sql to pass tests/store/tracking/test_sqlalchemy_store_schema.py

Signed-off-by: Jason Cheng <[email protected]>

* Added delete_time column into mlflow/store/tracking/dbmodels/initial_models.py

Signed-off-by: Jason Cheng <[email protected]>

* Moved the docstring to the end of the declaration instead of the start

Signed-off-by: Jason Cheng <[email protected]>

* Regenerated protobuf for RunInfo new schema, and passed pytest

Signed-off-by: Jason Cheng <[email protected]>

* Added --older-than flag in mlflow gc command, and added tests for that cli command

Signed-off-by: Jason Cheng <[email protected]>

* Removed delete_time from RunInfo proto

Signed-off-by: Jason Cheng <[email protected]>

* Set default older-than flag to None

Signed-off-by: Jason Cheng <[email protected]>

* Remove delete_time from RunInfo, add optional parameter older_than to store.get_deleted_runs(), and write delete_time into yaml file for file storage instead of adding it to RunInfo

Signed-off-by: Jason Cheng <[email protected]>

* Remove commented delete_time in RunInfo constructor in models.py

Signed-off-by: Jason Cheng <[email protected]>

* added INVALID_PARAMETER_VALUE error code in mlflow gc

Signed-off-by: Jason Cheng <[email protected]>

* Resolve case of delete time not in meta.yaml file, edited overwrite_run_info and gc

Signed-off-by: Jason Cheng <[email protected]>

* Rename delete_time to deleted_time

Signed-off-by: Jason Cheng <[email protected]>

* Rename delete_time to deleted_time, match error message in cli tests, filter SqlRuns by deleted_time, indicate float values accepted for gc --older-than flag

Signed-off-by: Jason Cheng <[email protected]>

* Rename delete_time to deleted_time, fixed assert statement in test_mlflow_gc, and fixed deleted_time queries in test_file_store.py and test_sqlalchemy_store.py

Signed-off-by: Jason Cheng <[email protected]>

* Only check if  is in meta after restoring run in test_delte_restore_run

Signed-off-by: Jason Cheng <[email protected]>

* Fixed lint errors

Signed-off-by: Jason Cheng <[email protected]>

* Install mlflow from repository root

Signed-off-by: harupy <[email protected]>

Co-authored-by: harupy <[email protected]>

* Separate protos job (#6399)

* Separate protos job

Signed-off-by: harupy <[email protected]>

* test

Signed-off-by: harupy <[email protected]>

* Add paths

Signed-off-by: harupy <[email protected]>

* Revert "test"

This reverts commit 5d04b02f55ec92e1e3ac18eb651ea989ca0d469a.

Signed-off-by: harupy <[email protected]>

* Fix flaky `TestFileStore.test_get_deleted_runs` (#6402)

* use gt operator

Signed-off-by: harupy <[email protected]>

* fix sqlalchemy store

Signed-off-by: harupy <[email protected]>

* Migrate environment variables for SQLAlchemy store (#6396)

Signed-off-by: harupy <[email protected]>

* Deduplicate MlflowClient in MLflow docs, move to mlflow.client module (#6405)

* Dedupe MlflowClient

Signed-off-by: dbczumar <[email protected]>

* Improvements

Signed-off-by: dbczumar <[email protected]>

* Add client

Signed-off-by: dbczumar <[email protected]>

* Remove unused functions in `mlflow.data` module (#6408)

* remove unused functions in data

Signed-off-by: harupy <[email protected]>

* Remove unused functions and variables

Signed-off-by: harupy <[email protected]>

* Tag based registered model search and model version search (#6320)

* init

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update tests

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* clean

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* add test

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* de-dup tag based search result

Signed-off-by: Weichen Xu <[email protected]>

* add () to fix case_sensitive_mysql_ne

Signed-off-by: Weichen Xu <[email protected]>

* fix

Signed-off-by: Weichen Xu <[email protected]>

* lint

Signed-off-by: Weichen Xu <[email protected]>

* fix

* fix test in TODO

Signed-off-by: Weichen Xu <[email protected]>

* support dup tag key filter

Signed-off-by: Weichen Xu <[email protected]>

* add mv order by

Signed-off-by: Weichen Xu <[email protected]>

* cmp res list in test

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* add doc

Signed-off-by: Weichen Xu <[email protected]>

* fix

Signed-off-by: Weichen Xu <[email protected]>

* fix lint

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* update doc

Signed-off-by: Weichen Xu <[email protected]>

* Increase maximum param value length to 500 (#6358)

* increase validation of maximum param value length from 250 to 500 (squashed)

Signed-off-by: Jan Sindlar <[email protected]>

* 1. added test for exceeding max length. 2. lint. 3. validation logic addresses null

Signed-off-by: Jan Sindlar <[email protected]>

* file store should test already stringified params

Signed-off-by: Jan Sindlar <[email protected]>

* update alembic chain

Signed-off-by: Jan Sindlar <[email protected]>

* Autoformat: https://github.com/mlflow/mlflow/actions/runs/2800398158

Signed-off-by: mlflow-automation <[email protected]>

* Update tests/store/tracking/test_file_store.py

Co-authored-by: Harutaka Kawamura <[email protected]>
Signed-off-by: Jan Sindlar <[email protected]>

Co-authored-by: Jan Sindlar <[email protected]>
Co-authored-by: mlflow-automation <[email protected]>
Co-authored-by: Harutaka Kawamura <[email protected]>

* Add workflow dispatch for requirements validation, remove duplicate file (#6418)

* Workflow dispatch

Signed-off-by: dbczumar <[email protected]>

* Remove unused

Signed-off-by: dbczumar <[email protected]>

* Prevent `pytest.raises` context manager from containing multiple statements (#6409)

* rename

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* Do not allow calling assert in pytest.raises

Signed-off-by: harupy <[email protected]>

* more strict rule

Signed-off-by: harupy <[email protected]>

* Improve error message

Signed-off-by: harupy <[email protected]>

* relax condition

Signed-off-by: harupy <[email protected]>

* fix lint errors

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>

* clean up

Signed-off-by: harupy <[email protected]>

* rename _is_complex_pytest_raises

Signed-off-by: harupy <[email protected]>

* fix lint errors

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>

* Fix regression in pandas type inference behavior for scoring server (#6417)

* Fix impl

Signed-off-by: dbczumar <[email protected]>

* Remove unused pandas import

Signed-off-by: dbczumar <[email protected]>

* Adjust client to use SearchExperiments POST method (#6415)

* POST

Signed-off-by: dbczumar <[email protected]>

* Generate protos

Signed-off-by: dbczumar <[email protected]>

* Fix test

Signed-off-by: dbczumar <[email protected]>

* update (#6420)

Signed-off-by: Weichen Xu <[email protected]>

* Check if artifacts are proxied in model_version_artifact_handler (#6355)

* Check if artifacts are proxied in model_version_artifact_handler

Signed-off-by: Mohammad Abbas <[email protected]>

* Use file prefix for artifact dest on windows

Signed-off-by: dbczumar <[email protected]>

* Fix application of prefix

Signed-off-by: dbczumar <[email protected]>

* Fixes

Signed-off-by: dbczumar <[email protected]>

Co-authored-by: dbczumar <[email protected]>

* Allow sql filter IN operator right-hand side values including whitespaces (#6413)

* support in rhs whitespace

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* Fix IN operator related issues in sql filter parser (#6411)

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* clean

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* address comment

Signed-off-by: Weichen Xu <[email protected]>

* Remove unused method `SearchUtils._get_comparison_for_model_registry` (#6412)

* init

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* Update MLflow UI (#6422)

* Project import generated by Copybara.

GitOrigin-RevId: 086b1200f4573559e37fcea6cb5472d52f166e42
Signed-off-by: dbczumar <[email protected]>

* Reconcile changes from universe with OSS

Signed-off-by: dbczumar <[email protected]>

* Fix test fails

Signed-off-by: dbczumar <[email protected]>

* Fix

Signed-off-by: dbczumar <[email protected]>

* Apply model search fix

Signed-off-by: dbczumar <[email protected]>

* Remove errant test line

Signed-off-by: dbczumar <[email protected]>

Co-authored-by: Richard Zang <[email protected]>

* remove near from deprecation msg (#6430)

Signed-off-by: ninabacc-db <[email protected]>

* Raise clear error message when pipeline path contains a space (#6426)

* Add unsupported

Signed-off-by: dbczumar <[email protected]>

* Fix

Signed-off-by: dbczumar <[email protected]>

* Exc

Signed-off-by: dbczumar <[email protected]>

* Test

Signed-off-by: dbczumar <[email protected]>

* Format

Signed-off-by: dbczumar <[email protected]>

* Test fix

Signed-off-by: dbczumar <[email protected]>

* Fix

Signed-off-by: dbczumar <[email protected]>

* [ALL TESTS] Changelog for MLflow 1.28.0 (#6433)

* Generating changelog for MLflow 1.27.1.dev0

Signed-off-by: Jenkins <[email protected]>

* Changelog

Signed-off-by: dbczumar <[email protected]>

* Add missing PR

Signed-off-by: dbczumar <[email protected]>

* Some fixes

Signed-off-by: dbczumar <[email protected]>

* More small fixes

Signed-off-by: dbczumar <[email protected]>

* Fix

Signed-off-by: dbczumar <[email protected]>

Signed-off-by: Jenkins <[email protected]>
Signed-off-by: dbczumar <[email protected]>
Co-authored-by: Jenkins <[email protected]>
Co-authored-by: dbczumar <[email protected]>

* Patch (#6440)

Signed-off-by: dbczumar <[email protected]>

Signed-off-by: dbczumar <[email protected]>

* [ALL TESTS] Update  (#6443)

* python dev/update_ml_package_versions.py

Signed-off-by: Jenkins <[email protected]>

* pyspark max ver 3.4

Signed-off-by: Weichen Xu <[email protected]>

Signed-off-by: Jenkins <[email protected]>
Signed-off-by: Weichen Xu <[email protected]>
Co-authored-by: Jenkins <[email protected]>
Co-authored-by: Weichen Xu <[email protected]>

* Update MLflow version to 1.28.1 (#6449)

Signed-off-by: Jenkins <[email protected]>

Signed-off-by: Jenkins <[email protected]>
Co-authored-by: Jenkins <[email protected]>

* Add data capture config to sagemaker (#6423)

Signed-off-by: jonwiggins <[email protected]>

Signed-off-by: jonwiggins <[email protected]>

* Fix small search_runs docs issues (#6452)

* Fix

Signed-off-by: dbczumar <[email protected]>

* Doc fix

Signed-off-by: dbczumar <[email protected]>

* Fix

Signed-off-by: dbczumar <[email protected]>

Signed-off-by: dbczumar <[email protected]>

* python dev/update_pypi_package_index.py (#6442)

Signed-off-by: Jenkins <[email protected]>

Signed-off-by: Jenkins <[email protected]>
Co-authored-by: Jenkins <[email protected]>

* use xgboost on pypi (#6461)

Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>

* Add environment variable for `echo` option in `create_engine` (#6460)

* Add environment variable for echo

Signed-off-by: harupy <[email protected]>

* use _BooleanEnvironmentVariable

Signed-off-by: harupy <[email protected]>

* address comments

Signed-off-by: harupy <[email protected]>

* address comments and add tests

Signed-off-by: harupy <[email protected]>

* fix comment

Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>

Signed-off-by: dbczumar <[email protected]>
Signed-off-by: harupy <[email protected]>
Signed-off-by: Michal Karzynski <[email protected]>
Signed-off-by: Sunish Sheth <[email protected]>
Signed-off-by: Jin Zhang <[email protected]>
Signed-off-by: Ryan Fogle <[email protected]>
Signed-off-by: Brian Barnes <[email protected]>
Signed-off-by: apurva-koti <[email protected]>
Signed-off-by: Weichen Xu <[email protected]>
Signed-off-by: ninabacc-db <[email protected]>
Signed-off-by: Jenkins <[email protected]>
Signed-off-by: jonwiggins <[email protected]>
Co-authored-by: Corey Zumar <[email protected]>
Co-authored-by: Michał Karzyński <[email protected]>
Co-authored-by: Chang Yong Lik <[email protected]>
Co-authored-by: Sunish Sheth <[email protected]>
Co-authored-by: jinzhang21 <[email protected]>
Co-authored-by: Ryan Fogle <[email protected]>
Co-authored-by: bbarnes52 <[email protected]>
Co-authored-by: apurva-koti <[email protected]>
Co-authored-by: Hannes Schulz <[email protected]>
Co-authored-by: dbczumar <[email protected]>
Co-authored-by: mlflow-automation <[email protected]>
Co-authored-by: WeichenXu <[email protected]>
Co-authored-by: Siddharth Murching <[email protected]>
Co-authored-by: Cheng Kuan Yong Jason <[email protected]>
Co-authored-by: johnyNJ <[email protected]>
Co-authored-by: Jan Sindlar <[email protected]>
Co-authored-by: Mohammad Abbas <[email protected]>
Co-authored-by: Richard Zang <[email protected]>
Co-authored-by: Nina Baccam <[email protected]>
Co-authored-by: mlflow-automation <[email protected]>
Co-authored-by: Jenkins <[email protected]>
Co-authored-by: Jon Wiggins <[email protected]>

* Use `virtualenv` by default when running an ML project (#6489)

* Use virtualenv by default when running an ML project

Signed-off-by: harupy <[email protected]>

* use _PYTHON_ENV_FILE_NAME

Signed-off-by: harupy <[email protected]>

* fix doc

Signed-off-by: harupy <[email protected]>

* fix env type

Signed-off-by: harupy <[email protected]>

* fix env_type

Signed-off-by: harupy <[email protected]>

* swap conda and virtualenv

Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>

* Use `virtualenv` by default when restoring a model environment (#6459)

* Use virtualenv by default when restoring a model environment

Signed-off-by: harupy <[email protected]>

* fix failed test

Signed-off-by: harupy <[email protected]>

* set up pyenv and virtualenv

Signed-off-by: harupy <[email protected]>

* get conda_env file path from MLmodel file

Signed-off-by: harupy <[email protected]>

* pyenv

Signed-off-by: harupy <[email protected]>

* use current python version

Signed-off-by: harupy <[email protected]>

* fix failed test

Signed-off-by: harupy <[email protected]>

* fix failed test

Signed-off-by: harupy <[email protected]>

* update default value of spark_udf

Signed-off-by: harupy <[email protected]>

* rename test

Signed-off-by: harupy <[email protected]>

* revert spark_udf change

Signed-off-by: harupy <[email protected]>

* revert

Signed-off-by: harupy <[email protected]>

* change default value to virtualenv

Signed-off-by: harupy <[email protected]>

* use local

Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>

* Remove `--no-conda` (#6501)

* remove --no-conda

Signed-off-by: harupy <[email protected]>

* update R docs

Signed-off-by: harupy <[email protected]>

* remove tests for --no-conda

Signed-off-by: harupy <[email protected]>

Signed-off-by: harupy <[email protected]>

* Sync `branch-2.0` with master (#6510)

* Fix java model server compatibility with models containing databricks_runtime conf (#6337)

* Javafix

Signed-off-by: dbczumar <[email protected]>

* Resource fix

Signed-off-by: dbczumar <[email protected]>

* Add run / model links to MLP train step card (#6294)

* One commit

Signed-off-by: dbczumar <[email protected]>

* Submodule revert

Signed-off-by: dbczumar <[email protected]>

* Fix client tests

Signed-off-by: dbczumar <[email protected]>

* fix ci

Signed-off-by: dbczumar <[email protected]>

* Remove unused / invalid import

Signed-off-by: dbczumar <[email protected]>

* Put run summary back to end, fix tests

Signed-off-by: dbczumar <[email protected]>

* Use mocks instead

Signed-off-by: dbczumar <[email protected]>

* Fix inefficient relative time computation for metric plot (#6341)

* compute minTimestamp only once

Signed-off-by: harupy <[email protected]>

* fix method name

Signed-off-by: harupy <[email protected]>

* fix lint

Signed-off-by: harupy <[email protected]>

* return empty array

Signed-off-by: harupy <[email protected]>

* fix test

Signed-off-by: harupy <[email protected]>

* Add `MLFLOW_SQLALCHEMYSTORE_POOL_RECYCLE` flag (#6344)

* Add pool_recycle option to SQLAlchemy create_engine

Signed-off-by: Michal Karzynski <[email protected]>

* Add new option to unit test

Signed-off-by: Michal Karzynski <[email protected]>

* Add note in documentation

Signed-off-by: Michal Karzynski <[email protected]>

* Add box plot in compare-runs page (#6308)

* Added BoxPlot

Signed-off-by: changyonglik <[email protected]>

* Fixed key error

Signed-off-by: changyonglik <[email protected]>

* Added default state

Signed-off-by: changyonglik <[email protected]>

* Fixed props passing

Signed-off-by: changyonglik <[email protected]>

* Fixed react hooks state

Signed-off-by: changyonglik <[email protected]>

* Added unit test

Signed-off-by: changyonglik <[email protected]>

* Added boxplot to CompareModelVersion

Signed-off-by: changyonglik <[email protected]>

* Changed keys numbering to reflect tab name

Signed-off-by: changyonglik <[email protected]>

* Made the ordering of tabs consistent accross CompareRunView and CompareModelVersion

Signed-off-by: changyonglik <[email protected]>

* Linted

Signed-off-by: changyonglik <[email protected]>

* Fixed FormattedMessage

Signed-off-by: changyonglik <[email protected]>

* refactoring

Signed-off-by: harupy <[email protected]>

* fix lint errors

Signed-off-by: harupy <[email protected]>

* i18n

Signed-off-by: harupy <[email protected]>

* minor comment fix

Signed-off-by: harupy <[email protected]>

Co-authored-by: harupy <[email protected]>

* Add script and workflow to update requirements.yaml specifications (#6287)

* add script to update requirements.yaml

Signed-off-by: harupy <[email protected]>

* update both skinny and core requirements

Signed-off-by: harupy <[email protected]>

* remove base

Signed-off-by: harupy <[email protected]>

* clean up

Signed-off-by: harupy <[email protected]>

* add MLFLOW_CONDA_HOME

Signed-off-by: harupy <[email protected]>

* create create-pr job

Signed-off-by: harupy <[email protected]>

* fix syntax

Signed-off-by: harupy <[email protected]>

* remove redundant if

Signed-off-by: harupy <[email protected]>

* clean up

Signed-off-by: harupy <[email protected]>

* doc

Signed-off-by: harupy <[email protected]>

* dynamically determine python version

Signed-off-by: harupy <[email protected]>

* remove python version mock

Signed-off-by: harupy <[email protected]>

* use setup-ssh.sh in master.yml

Signed-off-by: harupy <[email protected]>

* simplify

Signed-off-by: harupy <[email protected]>

* update both core and skinny requirements

Signed-off-by: harupy <[email protected]>

* use env

Signed-off-by: harupy <[email protected]>

* remove action version

Signed-off-by: harupy <[email protected]>

* fix pandas dtypes issue

Signed-off-by: harupy <[email protected]>

* check if PR already exists

Signed-off-by: harupy <[email protected]>

* add semicolons

Signed-off-by: harupy <[email protected]>

* test PR creation

Signed-off-by: harupy <[email protected]>

* set base

Signed-off-by: harupy <[email protected]>

* use run_number

Signed-off-by: harupy <[email protected]>

* set result-encoding

Signed-off-by: harupy <[email protected]>

* revert changes for test

Signed-off-by: harupy <[email protected]>

* fix more tests

Signed-off-by: harupy <[email protected]>

* fix run URL

Signed-off-by: harupy <[email protected]>

* add dot

Signed-off-by: harupy <[email protected]>

* remove minimum_version

Signed-off-by: harupy <[email protected]>

* remove create-pr job

Signed-off-by: harupy <[email protected]>

* rename workflow

Signed-off-by: harupy <[email protected]>

* mutate dict approach

Signed-off-by: harupy <[email protected]>

* use ruamel

Signed-off-by: harupy <[email protected]>

* remove PYTHON_VERSION patch

Signed-off-by: harupy <[email protected]>

* add ruamel.yaml to requirements

Signed-off-by: harupy <[email protected]>

* skip update-requirements on PR

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* print new version

Signed-off-by: harupy <[email protected]>

* preserve quotes

Signed-off-by: harupy <[email protected]>

* fix badge

Signed-off-by: harupy <[email protected]>

* fix README

Signed-off-by: harupy <[email protected]>

* run ci

Signed-off-by: harupy <[email protected]>

* remove validate-requirements.yml

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* rename

Signed-off-by: harupy <[email protected]>

* fix test_dataframe_from_json

Signed-off-by: harupy <[email protected]>

* Make `model_uri` optional for `mlflow models build-docker` (#6302)

* Make model_uri optional for mlflow models build-docker

Signed-off-by: harupy <[email protected]>

* fix doc

Signed-off-by: harupy <[email protected]>

* Add generic

Signed-off-by: harupy <[email protected]>

* Add pythou_function flavor

Signed-off-by: harupy <[email protected]>

* fix doc

Signed-off-by: harupy <[email protected]>

* quotes

Signed-off-by: harupy <[email protected]>

* use longer options

Signed-off-by: harupy <[email protected]>

* add index (#6347)

Signed-off-by: harupy <[email protected]>

* fix badge link (#6349)

Signed-off-by: harupy <[email protected]>

* Enable consider-using-dict-items rule for pylint (#6351)

* Enable consider-using-dict-items

Signed-off-by: harupy <[email protected]>

* fix lint errors

Signed-off-by: harupy <[email protected]>

* Enable consider-merging-isinstance (#6350)

Signed-off-by: harupy <[email protected]>

* Enable consider-using-from-import rule for pylint (#6352)

* Enable consider-using-from-import

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

* fix datasets import

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>

* Run model registry sqlalchemy tests in database job (#6353)

Signed-off-by: harupy <[email protected]>

* update to run profiles on the first 100 dataframe columns (#6297)

* update to run profiles on the first 100 dataframe columns

Signed-off-by: Sunish Sheth <[email protected]>

* Adding replace=True so we can sample rows twice

Signed-off-by: Sunish Sheth <[email protected]>

* Removing replace=true and fixing how the max_rows are calculated

Signed-off-by: Sunish Sheth <[email protected]>

* Fix sklearn autologging input example & signature mutation for models containing transformers (#6230)

* Fix with test case

Signed-off-by: dbczumar <[email protected]>

* Test fix

Signed-off-by: dbczumar <[email protected]>

* Fix and simplification

Signed-off-by: dbczumar <[email protected]>

* more fixes & better test coveragE

Signed-off-by: dbczumar <[email protected]>

* test

Signed-off-by: dbczumar <[email protected]>

* LGBM test

Signed-off-by: dbczumar <[email protected]>

* Format

Signed-off-by: dbczumar <[email protected]>

* Address comments

Signed-off-by: dbczumar <[email protected]>

* Fixes

Signed-off-by: dbczumar <[email protected]>

* Use py37-compatible call args syntax

Signed-off-by: dbczumar <[email protected]>

* use list (#6363)

Signed-off-by: harupy <[email protected]>

* Log runtime pipeline config to MLflow (#6359)

* Log runtime pipeline config to MLflow

Signed-off-by: Jin Zhang <[email protected]>

* Fixed lint

Signed-off-by: Jin Zhang <[email protected]>

* Add status badge for stale action (#6372)

Signed-off-by: harupy <[email protected]>

* Add stack trace section to bug report template (#6374)

Signed-off-by: harupy <[email protected]>

* Skipping the transform step by using Functional transformer (#6362)

Signed-off-by: Sunish Sheth <[email protected]>

* Series schema (#6361)

* Added in name for ColSpec of pandas datatype

infer panda series name for ColSpec

Signed-off-by: Ryan Fogle <[email protected]>

* Added test for Series name inference

added one more pytest condition in test_schema:test_schema_inference_on_pandas_series

Signed-off-by: Ryan Fogle <[email protected]>

* Update test_schema.py

Added in one more assertion to test schema inference.

Signed-off-by: Ryan Fogle <[email protected]>

* ran black

Signed-off-by: Ryan Fogle <[email protected]>

* added in requested changes in issue #6361

Signed-off-by: Ryan Fogle <[email protected]>

* fix typo. changed hasattr to getattr

Signed-off-by: Ryan Fogle <[email protected]>

* integrate mlflowdbfs (#6282)

Signed-off-by: Brian Barnes <[email protected]>

* Fix step card display breakage in Jupyter notebooks (#6378)

* remove

Signed-off-by: apurva-koti <[email protected]>

* fix

Signed-off-by: apurva-koti <[email protected]>

* Avoid using flask 2.2.0 (#6380)

Signed-off-by: harupy <[email protected]>

* Migrate GCS environment variables to `mlflow.environment_variables` module (#6375)

* Migrate GCS environment variables to mlflow.environment_variables

Signed-off-by: harupy <[email protected]>

* add default

Signed-off-by: harupy <[email protected]>

* improve comments

Signed-off-by: harupy <[email protected]>

* Avoid logging model signatures in pyspark ML autologging if model input/output dataframe contains unsupported data types (#6365)

* Avoid logging signatures

Signed-off-by: harupy <[email protected]>

* test

Signed-off-by: harupy <[email protected]>

* fix indent

Signed-off-by: harupy <[email protected]>

* check model output

Signed-off-by: harupy <[email protected]>

* fix warning message

Signed-off-by: harupy <[email protected]>

* todo

Signed-off-by: harupy <[email protected]>

* update test and doc

Signed-off-by: harupy <[email protected]>

* fix docstring

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>

* improve _assert_autolog_infers_model_signature_correctly

Signed-off-by: harupy <[email protected]>

* Refactor `set_matrix.py` (#6373)

* refacor set_matrix.py

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

* fix tests

Signed-off-by: harupy <[email protected]>

* tset for --no-dev

Signed-off-by: harupy <[email protected]>

* install pytest and pytest-cov

Signed-off-by: harupy <[email protected]>

* test for --changed-files

Signed-off-by: harupy <[email protected]>

* add pyyaml to requirements

Signed-off-by: harupy <[email protected]>

* fix is_matrix_empty

Signed-off-by: harupy <[email protected]>

* use raw string and re.match

Signed-off-by: harupy <[email protected]>

* Fix is_matrix_empty (#6385)

Signed-off-by: harupy <[email protected]>

* Allow mlflow-skinny's autolog() to succeed when no scipy is installed (#5897)

* allow mlflow-skinny's autolog() to succeed when no scipy is installed

Signed-off-by: Hannes Schulz <[email protected]>

* optional pyfunc scipy dependency

Signed-off-by: Hannes Schulz <[email protected]>

* fix linter-discovered issues

Signed-off-by: Hannes Schulz <[email protected]>

* add test case, autolog() should pass w/o scipy installed

Signed-off-by: Hannes Schulz <[email protected]>

* minor cleanup

Signed-off-by: Hannes Schulz <[email protected]>

* test creating _Example with / without scipy present

Signed-off-by: Hannes Schulz <[email protected]>

* docs: do not warn about sparse matrix classes

Signed-off-by: Hannes Schulz <[email protected]>

* linting

Signed-off-by: Hannes Schulz <[email protected]>

* address review comment

Signed-off-by: Hannes Schulz <[email protected]>

* run black

Signed-off-by: Hannes Schulz <[email protected]>

* allow mlflow-skinny's autolog() to succeed when no scipy is installed

Signed-off-by: Hannes Schulz <[email protected]>

* optional pyfunc scipy dependency

Signed-off-by: Hannes Schulz <[email protected]>

* fix linter-discovered issues

Signed-off-by: Hannes Schulz <[email protected]>

* add test case, autolog() should pass w/o scipy installed

Signed-off-by: Hannes Schulz <[email protected]>

* minor cleanup

Signed-off-by: Hannes Schulz <[email protected]>

* test creating _Example with / without scipy present

Signed-off-by: Hannes Schulz <[email protected]>

* docs: do not warn about sparse matrix classes

Signed-off-by: Hannes Schulz <[email protected]>

* linting

Signed-off-by: Hannes Schulz <[email protected]>

* address review comment

Signed-off-by: Hannes Schulz <[email protected]>

* run black

Signed-off-by: Hannes Schulz <[email protected]>

* remove redundant None check after import

Signed-off-by: Hannes Schulz <[email protected]>

* delete comment

Signed-off-by: Hannes Schulz <[email protected]>

* Revert "remove redundant None check after import"

This reverts commit f2e198c944f41d9a96c20ae471d71bff39431b48.

Signed-off-by: Hannes Schulz <[email protected]>

* review comments

Signed-off-by: Hannes Schulz <[email protected]>

* remove redundant test

Signed-off-by: Hannes Schulz <[email protected]>

* Apply suggestions from code review

Co-authored-by: Harutaka Kawamura <[email protected]>
Signed-off-by: Hannes Schulz <[email protected]>

* Autoformat: https://github.com/mlflow/mlflow/actions/runs/2779791161

Signed-off-by: mlflow-automation <[email protected]>

Co-authored-by: Harutaka Kawamura <[email protected]>
Co-authored-by: dbczumar <[email protected]>
Co-authored-by: mlflow-automation <[email protected]>

* Fix extraneous warning about pyspark evaluation truncation (#6389)

* Revert #6380 (#6386)

* revert

Signed-off-by: harupy <[email protected]>

* workaround for test_prometheus_exporter

Signed-off-by: harupy <[email protected]>

* nit

Signed-off-by: harupy <[email protected]>

* Validate metric value in `FileStore.log_metric` (#6381)

* add failing test

Signed-off-by: harupy <[email protected]>

* use _validate_metric

Signed-off-by: harupy <[email protected]>

* fix invalid metric timestamp

Signed-off-by: harupy <[email protected]>

* fix docstring

Signed-off-by: harupy <[email protected]>

* fix java test

Signed-off-by: harupy <[email protected]>

* Make search experiment by tag key comparison case sensitive in MYSQL (#6333)

* init

Signed-off-by: Weichen Xu <[email protected]>

* add test

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* fix BINARY conditions in MySQL

Signed-off-by: harupy <[email protected]>

* fix attr error

Signed-off-by: harupy <[email protected]>

Co-authored-by: harupy <[email protected]>

* Run Model Registry SQLAlchemy tests in PostgreSQL, MySQL, and MSSQL (#6390)

* Run Model Registry SQLAlchemy tests in postgres, mysql, and mssql

Signed-off-by: harupy <[email protected]>

* fix failed tests

Signed-off-by: harupy <[email protected]>

* remove uuid

Signed-off-by: harupy <[email protected]>

* clean up

Signed-off-by: harupy <[email protected]>

* do not drop tables

Signed-off-by: harupy <[email protected]>

* Fix filestore data loss on failed write & mitigate read / write race condition (#6388)

* Fix

Signed-off-by: dbczumar <[email protected]>

* Fix

Signed-off-by: dbczumar <[email protected]>

* Format

Signed-off-by: dbczumar <[email protected]>

* Added a custom filter from_json to render_and_merge_yaml (#6368)

* Added a custom filter from_json to render_and_merge_yaml

Signed-off-by: Jin Zhang <[email protected]>

* Fixed test

Signed-off-by: Jin Zhang <[email protected]>

* Update tests/utils/test_file_utils.py

Co-authored-by: Siddharth Murching <[email protected]>

* Update tests/utils/test_file_utils.py

Co-authored-by: Siddharth Murching <[email protected]>

* Fixed test

Signed-off-by: Jin Zhang <[email protected]>

* Fixed windows test attempt

Signed-off-by: Jin Zhang <[email protected]>

* Fixed windows test

Signed-off-by: Jin Zhang <[email protected]>

Co-authored-by: Siddharth Murching <[email protected]>

* Fix `!=` operator for MySQL (#6397)

* fix ne operator and improve tests

Signed-off-by: harupy <[email protected]>

* add () to other operators

Signed-off-by: harupy <[email protected]>

* Simplify the documentation section in the PR template (#6398)

* Simplify the documentation section in the PR template

Signed-off-by: harupy <[email protected]>

* fix

Signed-off-by: harupy <[email protected]>

* Timebased gc (#6354)

* Added delete_time field to runs table

Signed-off-by: Jason Cheng <[email protected]>

* Updated latest_schema.sql to pass tests/store/tracking/test_sqlalchemy_store_schema.py

Signed-off-by: Jason Cheng <[email protected]>

* Added delete_time column into mlflow/store/tracking/dbmodels/initial_models.py

Signed-off-by: Jason Cheng <[email protected]>

* Moved the docstring to the end of the declaration instead of the start

Signed-off-by: Jason Cheng <[email protected]>

* Regenerated protobuf for RunInfo new schema, and passed pytest

Signed-off-by: Jason Cheng <[email protected]>

* Added --older-than flag in mlflow gc command, and added tests for that cli command

Signed-off-by: Jason Cheng <[email protected]>

* Removed delete_time from RunInfo proto

Signed-off-by: Jason Cheng <[email protected]>

* Set default older-than flag to None

Signed-off-by: Jason Cheng <[email protected]>

* Remove delete_time from RunInfo, add optional parameter older_than to store.get_deleted_runs(), and write delete_time into yaml file for file storage instead of adding it to RunInfo

Signed-off-by: Jason Cheng <[email protected]>

* Remove commented delete_time in RunInfo constructor in models.py

Signed-off-by: Jason Cheng <[email protected]>

* added INVALID_PARAMETER_VALUE error code in mlflow gc

Signed-off-by: Jason Cheng <[email protected]>

* Resolve case of delete time not in meta.yaml file, edited overwrite_run_info and gc

Signed-off-by: Jason Cheng <[email protected]>

* Rename delete_time to deleted_time

Signed-off-by: Jason Cheng <[email protected]>

* Rename delete_time to deleted_time, match error message in cli tests, filter SqlRuns by deleted_time, indicate float values accepted for gc --older-than flag

Signed-off-by: Jason Cheng <[email protected]>

* Rename delete_time to deleted_time, fixed assert statement in test_mlflow_gc, and fixed deleted_time queries in test_file_store.py and test_sqlalchemy_store.py

Signed-off-by: Jason Cheng <[email protected]>

* Only check if  is in meta after restoring run in test_delte_restore_run

Signed-off-by: Jason Cheng <[email protected]>

* Fixed lint errors

Signed-off-by: Jason Cheng <[email protected]>

* Install mlflow from repository root

Signed-off-by: harupy <[email protected]>

Co-authored-by: harupy <[email protected]>

* Separate protos job (#6399)

* Separate protos job

Signed-off-by: harupy <[email protected]>

* test

Signed-off-by: harupy <[email protected]>

* Add paths

Signed-off-by: harupy <[email protected]>

* Revert "test"

This reverts commit 5d04b02f55ec92e1e3ac18eb651ea989ca0d469a.

Signed-off-by: harupy <[email protected]>

* Fix flaky `TestFileStore.test_get_deleted_runs` (#6402)

* use gt operator

Signed-off-by: harupy <[email protected]>

* fix sqlalchemy store

Signed-off-by: harupy <[email protected]>

* Migrate environment variables for SQLAlchemy store (#6396)

Signed-off-by: harupy <[email protected]>

* Deduplicate MlflowClient in MLflow docs, move to mlflow.client module (#6405)

* Dedupe MlflowClient

Signed-off-by: dbczumar <[email protected]>

* Improvements

Signed-off-by: dbczumar <[email protected]>

* Add client

Signed-off-by: dbczumar <[email protected]>

* Remove unused functions in `mlflow.data` module (#6408)

* remove unused functions in data

Signed-off-by: harupy <[email protected]>

* Remove unused functions and variables

Signed-off-by: harupy <[email protected]>

* Tag based registered model search and model version search (#6320)

* init

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update tests

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* clean

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* add test

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* update

Signed-off-by: Weichen Xu <[email protected]>

* de-dup tag based search result

Signed-off-by: Weichen Xu <[email protected]>

* add () to fix case_sensitive_mysql_ne

Signed-off-by: Weichen Xu <[email protected]>

* fix

Signed-off-by: Weichen Xu <[email protected]>

* lint

Signed-off-by: Weichen Xu <[email protected]>

* fix

* fix test in TODO

Signed-off-by: Weichen Xu <[email protected]>

* support dup tag key filter

Signed-off-by: Weichen Xu <[email protected]>

* add mv order by

Signed-off-by: Weichen Xu <[email protected]>

* cmp res list in test

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* add doc

Signed-off-by: Weichen Xu <[email protected]>

* fix

Signed-off-by: Weichen Xu <[email protected]>

* fix lint

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* address comments

Signed-off-by: Weichen Xu <[email protected]>

* update doc

Signed-off-by: Weichen Xu <[email protected]>

* Increase maximum param value length to 500 (#6358)

* increase validation of maximum param value length from 250 to 500 (squashed)

Signed-off-by: Jan Sindlar <[email protected]>

* 1. added test for exceed…
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

rn/none List under Small Changes in Changelogs.

Projects

None yet

Development

Successfully merging this pull request may close these issues.