From 73699b3cea2272cc211b53bcef47ec9edea36722 Mon Sep 17 00:00:00 2001 From: John Moutafis <2430971+JohnMoutafis@users.noreply.github.com> Date: Fri, 12 Jul 2024 11:14:04 +0300 Subject: [PATCH] Remove old `tiledb.cloud.file` methods for version v0.12.16 (#602) * Remove old `tiledb.cloud.file` methods. --- docs/_quarto.yaml | 3 -- src/tiledb/cloud/__init__.py | 2 - src/tiledb/cloud/file.py | 78 ------------------------------------ 3 files changed, 83 deletions(-) delete mode 100644 src/tiledb/cloud/file.py diff --git a/docs/_quarto.yaml b/docs/_quarto.yaml index 03f6f5dbd..e1628df27 100644 --- a/docs/_quarto.yaml +++ b/docs/_quarto.yaml @@ -35,8 +35,6 @@ website: href: reference/cloudarray.qmd - text: "`config`" href: reference/config.qmd - - text: "`file`" - href: reference/file.qmd - text: "`groups`" href: reference/groups.qmd - text: "`invites`" @@ -132,7 +130,6 @@ quartodoc: - client - cloudarray - config - - file - groups - invites - notebook diff --git a/src/tiledb/cloud/__init__.py b/src/tiledb/cloud/__init__.py index 2344b43c5..c5583198d 100644 --- a/src/tiledb/cloud/__init__.py +++ b/src/tiledb/cloud/__init__.py @@ -4,7 +4,6 @@ from . import asset from . import compute from . import dag -from . import file from . import files from . import groups from . import sql @@ -56,7 +55,6 @@ "asset", "compute", "dag", - "file", "files", "groups", "sql", diff --git a/src/tiledb/cloud/file.py b/src/tiledb/cloud/file.py deleted file mode 100644 index 330abf1e4..000000000 --- a/src/tiledb/cloud/file.py +++ /dev/null @@ -1,78 +0,0 @@ -from typing import Optional, Tuple, Union - -from tiledb.cloud.rest_api import models - - -def create_file( - namespace: str, - input_uri: str, - output_uri: str, - name: Optional[str] = None, - access_credentials_name: Optional[str] = None, - access_credential_name: Optional[str] = None, - async_req: bool = False, -) -> models.FileCreated: - """ - DEPRECATED METHOD: Will be removed from version 0.12.16. - Use `tiledb.cloud.files.utils.create_file instead. - - Creates a TileDB file at the specified location - :param namespace: namespace the create file operation belongs to - :param name: name to use for registration in TileDB Cloud - :param input_uri: input file uri - :param output_uri: output array uri - :param access_credential_name: - DEPRECATED. Use ``access_credential_name`` instead. - :param access_credentials_name: optional access credentials to use - :param async_req: return future instead of results for async support - :return: FileCreated details, including file_uuid and output_uri - """ - raise DeprecationWarning( - "This method is deprecated. " - "Use `tiledb.cloud.files.utils.create_file instead." - ) - - -def export_file_local( - uri: str, - output_uri: str, - timestamp: Union[Tuple[int, int], int, None] = None, - async_req: bool = False, -) -> models.FileExported: - """ - DEPRECATED METHOD: Will be removed from version 0.12.16. - Use `tiledb.cloud.files.utils.export_file_local` instead. - - Exports a TileDB File back to its original file format - :param uri: The ``tiledb://...`` URI of the file to export - :param output_uri: output file uri - :param tuple timestamp: (default None) If int, open the array at a given TileDB - timestamp. If tuple, open at the given start and end TileDB timestamps. - :param async_req: return future instead of results for async support - :return: FileExported details, including output_uri - """ - raise DeprecationWarning( - "This is deprecated. " - "Use `tiledb.cloud.files.utils.export_file_local` instead." - ) - - -def export_file( - uri: str, - output_uri: str, - async_req: bool = False, -) -> models.FileExported: - """ - DEPRECATED METHOD: Will be removed from version 0.12.16. - Use `tiledb.cloud.files.utils.export_file` instead. - - Exports a TileDB File back to its original file format - :param uri: The ``tiledb://...`` URI of the file to export - :param output_uri: output file uri - :param async_req: return future instead of results for async support - :return: FileExported details, including output_uri - """ - raise DeprecationWarning( - "This method is deprecated. " - "Use `tiledb.cloud.files.utils.export_file` instead." - )