Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/conda-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,4 +102,4 @@ jobs:
with:
packages_dir: wheels/
user: __token__
password: ${{ secrets.PYPI_TOKEN }}
password: ${{ secrets.PYPI_API_TOKEN }}
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,12 +139,12 @@ Create a new environment named `pypi` in the GitHub repository:
- Name it `pypi`
- Click "Configure environment"

**Step 2: Add PYPI_TOKEN secret**
**Step 2: Add PYPI_API_TOKEN secret**

Add your PyPI token to the `pypi` environment:
- In the `pypi` environment settings, scroll to "Environment secrets"
- Click "Add secret"
- Name: `PYPI_TOKEN` (use this exact name)
- Name: `PYPI_API_TOKEN` (use this exact name)
- Value: Your PyPI API token
- Click "Add secret"

Expand Down Expand Up @@ -180,7 +180,7 @@ This method creates a formal GitHub release with a tag, which automatically trig

1. Go to the Releases tab: https://github.com/google/ml-metadata/releases
2. Click the `Draft new release` button (you'll be redirected to https://github.com/google/ml-metadata/releases/new)
3. Click the `Select tag` button and create a new tag for your release (e.g., `v1.18.0`)
3. Click the `Select tag` button and create a new tag for your release (e.g., `v1.21.0`)
4. Click the `Target` dropdown and select your release branch
5. Fill in the **Release title** and **Release notes** sections
6. Choose the release type:
Expand Down
29 changes: 24 additions & 5 deletions RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,38 @@

## Major Features and Improvements

* N/A

## Breaking Changes

* N/A

## Deprecations

* N/A

## Bug Fixed and Other Changes

* N/A

# Version 1.21.0

## Major Features and Improvements

* Added Python 3.12 and Python 3.13 support.

## Breaking Changes

* Removed Python 3.9 support.
* Removed ZetaSQL-based `filter_query` functionality. The `filter_query`
parameter in `ListOptions` that relied on ZetaSQL for declarative filtering
has been removed in version 1.21.0. Users should migrate to native lookup
and lineage APIs (such as `get_artifacts_by_uri`, `get_artifacts_by_context`,
and `get_lineage_subgraph`) and filter retrieved objects directly in Python.

## Deprecations

* Deprecate ZetaSQL-based filter_query functionality. The `filter_query`
parameter in ListOperationOptions that relies on ZetaSQL for declarative
filtering is deprecated and will be removed in version 1.18.0. ZetaSQL
dependency is being removed from ML Metadata. Users should migrate to
alternative filtering approaches before the 1.18.0 release.
* N/A

## Bug Fixed and Other Changes

Expand Down
7 changes: 4 additions & 3 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ artifacts = store.get_artifacts()
# Plus, there are many ways to query the same Artifact
[stored_data_artifact] = store.get_artifacts_by_id([data_artifact_id])
artifacts_with_uri = store.get_artifacts_by_uri(data_artifact.uri)
# Note: filter_query is deprecated and will be removed in version 1.18.0.
# Note: filter_query has been removed in version 1.21.0.
artifacts_with_conditions = store.get_artifacts(
list_options=mlmd.ListOptions(
filter_query='uri LIKE "%/data" AND properties.day.int_value > 0'))
Expand All @@ -271,7 +271,7 @@ trainer_run.properties["state"].string_value = "RUNNING"
# Query all registered Execution
executions = store.get_executions_by_id([run_id])
# Similarly, the same execution can be queried with conditions.
# Note: filter_query is deprecated and will be removed in version 1.18.0.
# Note: filter_query has been removed in version 1.21.0.
executions_with_conditions = store.get_executions(
list_options = mlmd.ListOptions(
filter_query='type = "Trainer" AND properties.state.string_value IS NOT NULL'))
Expand Down Expand Up @@ -357,7 +357,7 @@ experiment_executions = store.get_executions_by_context(experiment_id)

# You can also use neighborhood queries to fetch these artifacts and executions
# with conditions.
# Note: filter_query is deprecated and will be removed in version 1.18.0.
# Note: filter_query has been removed in version 1.21.0.
experiment_artifacts_with_conditions = store.get_artifacts(
list_options = mlmd.ListOptions(
filter_query=('contexts_a.type = "Experiment" AND contexts_a.name = "exp1"')))
Expand Down Expand Up @@ -524,6 +524,7 @@ The list of `schema_version` used in MLMD releases are:

ml-metadata (MLMD) | schema_version
------------------ | --------------
1.21.0 | 10
1.16.0 | 10
1.15.0 | 10
1.14.0 | 10
Expand Down
17 changes: 8 additions & 9 deletions ml_metadata/metadata_store/metadata_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,10 @@ class ListOptions:
is_asc: Specifies `order_by` is ascending or descending. If `order_by` is
not given, the field is ignored. If `order_by` is set, then by default
ascending order is used for performance benefit.
filter_query: DEPRECATED (will be removed in v1.18.0) - An optional boolean
filter_query: DEPRECATED (removed in v1.21.0) - An optional boolean
expression in SQL syntax to specify conditions on node attributes and
directly connected assets. This feature depends on ZetaSQL which is being
removed from ML Metadata. Please migrate to alternative filtering approaches
before version 1.18.0. See
directly connected assets. This feature depends on ZetaSQL which has been
removed from ML Metadata. See
https://github.com/google/ml-metadata/blob/master/ml_metadata/proto/metadata_store.proto#L705-L783
for the query capabilities and syntax.
"""
Expand Down Expand Up @@ -1482,13 +1481,13 @@ def _call_method_with_list_options(
if list_options.order_by:
request.options.order_by_field.field = list_options.order_by.value
if list_options.filter_query:
# DEPRECATED: ZetaSQL-based filter_query will be removed in v1.18.0
# DEPRECATED: ZetaSQL-based filter_query has been removed in v1.21.0
import warnings
warnings.warn(
'DEPRECATION WARNING: filter_query is deprecated and will be '
'removed in version 1.18.0. This feature depends on ZetaSQL '
'which is being removed from ML Metadata. Please migrate to '
'alternative filtering approaches before the 1.18.0 release.',
'DEPRECATION WARNING: filter_query has been removed in version '
'1.21.0. This feature depended on ZetaSQL which has been removed '
'from ML Metadata. Please migrate to alternative filtering '
'approaches.',
DeprecationWarning,
stacklevel=3
)
Expand Down
2 changes: 1 addition & 1 deletion ml_metadata/query/filter_query_ast_resolver.cc
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ limitations under the License.
==============================================================================*/

// DEPRECATED: This file and its associated ZetaSQL-based filter_query
// functionality is deprecated and will be removed in version 1.18.0.
// functionality has been removed in version 1.21.0.
// ZetaSQL dependency is being phased out from ML Metadata.
// Please migrate to alternative filtering approaches.

Expand Down
2 changes: 1 addition & 1 deletion ml_metadata/query/filter_query_ast_resolver.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ limitations under the License.
namespace ml_metadata {

// DEPRECATED: This class and its associated ZetaSQL-based filter_query
// functionality is deprecated and will be removed in version 1.18.0.
// functionality has been removed in version 1.21.0.
// ZetaSQL dependency is being phased out from ML Metadata.
// Please migrate to alternative filtering approaches.
//
Expand Down
2 changes: 1 addition & 1 deletion ml_metadata/query/filter_query_builder.cc
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ limitations under the License.
==============================================================================*/

// DEPRECATED: This file and its associated ZetaSQL-based filter_query
// functionality is deprecated and will be removed in version 1.18.0.
// functionality has been removed in version 1.21.0.
// ZetaSQL dependency is being phased out from ML Metadata.
// Please migrate to alternative filtering approaches.

Expand Down
2 changes: 1 addition & 1 deletion ml_metadata/query/filter_query_builder.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ limitations under the License.
namespace ml_metadata {

// DEPRECATED: This class and its associated ZetaSQL-based filter_query
// functionality is deprecated and will be removed in version 1.18.0.
// functionality has been removed in version 1.21.0.
// ZetaSQL dependency is being phased out from ML Metadata.
// Please migrate to alternative filtering approaches.
//
Expand Down
2 changes: 1 addition & 1 deletion ml_metadata/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@
"""Contains the version string of ML Metadata."""

# Note that setup.py uses this version.
__version__ = '1.18.0.dev'
__version__ = '1.22.0.dev'
Loading