diff --git a/libs/labelbox/src/labelbox/schema/catalog.py b/libs/labelbox/src/labelbox/schema/catalog.py index 567bbd777..df50503ad 100644 --- a/libs/labelbox/src/labelbox/schema/catalog.py +++ b/libs/labelbox/src/labelbox/schema/catalog.py @@ -1,4 +1,5 @@ from typing import Any, Dict, List, Optional, Tuple, Union +import warnings from labelbox.orm.db_object import experimental from labelbox.schema.export_filters import CatalogExportFilters, build_filters @@ -45,6 +46,13 @@ def export_v2( >>> task.wait_till_done() >>> task.result """ + + warnings.warn( + "You are currently utilizing export_v2 for this action, which will be deprecated in a V7. Please refer to docs for export alternatives. https://docs.labelbox.com/reference/export-overview#export-methods", + DeprecationWarning, + stacklevel=2, + ) + task, is_streamable = self._export(task_name, filters, params) if is_streamable: return ExportTask(task, True) diff --git a/libs/labelbox/src/labelbox/schema/data_row.py b/libs/labelbox/src/labelbox/schema/data_row.py index 8987a00f0..ed1184c12 100644 --- a/libs/labelbox/src/labelbox/schema/data_row.py +++ b/libs/labelbox/src/labelbox/schema/data_row.py @@ -2,6 +2,7 @@ from enum import Enum from typing import TYPE_CHECKING, List, Optional, Tuple, Union, Any import json +import warnings from labelbox.orm import query from labelbox.orm.db_object import ( @@ -277,6 +278,13 @@ def export_v2( >>> task.wait_till_done() >>> task.result """ + + warnings.warn( + "You are currently utilizing export_v2 for this action, which will be deprecated in a V7. Please refer to docs for export alternatives. https://docs.labelbox.com/reference/export-overview#export-methods", + DeprecationWarning, + stacklevel=2, + ) + task, is_streamable = DataRow._export( client, data_rows, global_keys, task_name, params ) diff --git a/libs/labelbox/src/labelbox/schema/dataset.py b/libs/labelbox/src/labelbox/schema/dataset.py index 389afb7e1..df467caf1 100644 --- a/libs/labelbox/src/labelbox/schema/dataset.py +++ b/libs/labelbox/src/labelbox/schema/dataset.py @@ -358,6 +358,13 @@ def export_v2( >>> task.wait_till_done() >>> task.result """ + + warnings.warn( + "You are currently utilizing export_v2 for this action, which will be deprecated in a V7. Please refer to docs for export alternatives. https://docs.labelbox.com/reference/export-overview#export-methods", + DeprecationWarning, + stacklevel=2, + ) + task, is_streamable = self._export(task_name, filters, params) if is_streamable: return ExportTask(task, True) diff --git a/libs/labelbox/src/labelbox/schema/model_run.py b/libs/labelbox/src/labelbox/schema/model_run.py index bc9971174..053c43b97 100644 --- a/libs/labelbox/src/labelbox/schema/model_run.py +++ b/libs/labelbox/src/labelbox/schema/model_run.py @@ -539,6 +539,12 @@ def export_v2( >>> export_task = export_v2("my_export_task", params={"media_attributes": True}) """ + + warnings.warn( + "You are currently utilizing export_v2 for this action, which will be deprecated in a V7. Please refer to docs for export alternatives. https://docs.labelbox.com/reference/export-overview#export-methods", + DeprecationWarning, + stacklevel=2, + ) task, is_streamable = self._export(task_name, params) if is_streamable: return ExportTask(task, True) diff --git a/libs/labelbox/src/labelbox/schema/project.py b/libs/labelbox/src/labelbox/schema/project.py index 2205a05e2..ae97089a7 100644 --- a/libs/labelbox/src/labelbox/schema/project.py +++ b/libs/labelbox/src/labelbox/schema/project.py @@ -415,6 +415,13 @@ def export_v2( >>> task.wait_till_done() >>> task.result """ + + warnings.warn( + "You are currently utilizing export_v2 for this action, which will be deprecated in a V7. Please refer to docs for export alternatives. https://docs.labelbox.com/reference/export-overview#export-methods", + DeprecationWarning, + stacklevel=2, + ) + task, is_streamable = self._export(task_name, filters, params) if is_streamable: return ExportTask(task, True) diff --git a/libs/labelbox/src/labelbox/schema/slice.py b/libs/labelbox/src/labelbox/schema/slice.py index 9a0ae912e..3bad8cf07 100644 --- a/libs/labelbox/src/labelbox/schema/slice.py +++ b/libs/labelbox/src/labelbox/schema/slice.py @@ -127,6 +127,13 @@ def export_v2( >>> task.wait_till_done() >>> task.result """ + + warnings.warn( + "You are currently utilizing export_v2 for this action, which will be deprecated in a V7. Please refer to docs for export alternatives. https://docs.labelbox.com/reference/export-overview#export-methods", + DeprecationWarning, + stacklevel=2, + ) + task, is_streamable = self._export(task_name, params) if is_streamable: return ExportTask(task, True)