Skip to content
Open
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
3 changes: 2 additions & 1 deletion geocube/admin.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
from typing import List, Union, Dict, Tuple
from warnings import deprecated

from geocube import utils, entities, Client
from geocube.pb import admin_pb2, admin_pb2_grpc
from geocube.stub import Stub
from geocube.utils import deprecated, GeocubeError
from geocube.utils import GeocubeError


class Admin(Client):
Expand Down
7 changes: 4 additions & 3 deletions geocube/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,8 +196,8 @@ def create_records(self, aoi_ids: List[str], names: List[str],
"""
return self._create_records(aoi_ids, names, tags, dates)

@warnings.deprecated("Use record() instead")
def get_record(self, _id: str) -> entities.Record:
""" Deprecated: use record() instead """
return self.record(_id)

def record(self, _id: str) -> entities.Record:
Expand Down Expand Up @@ -529,8 +529,8 @@ def job(self, name: str = None, id_: str = None, log_page: int = 0, log_limit: i
return self._get_job_by_id(id_, log_page, log_limit)
raise ValueError("job: either name or id_ must be defined")

@warnings.deprecated("Use job() instead")
def get_job(self, job_id: Union[str, entities.Job], log_page=0, log_limit=1000):
""" Deprecated: use job() """
return self.job(id_=job_id, log_page=log_page, log_limit=log_limit)

def list_jobs(self, name_like: str = "", page=0, limit=10):
Expand Down Expand Up @@ -1030,5 +1030,6 @@ def _consolidate(self,
))
return self.get_job(self.stub.Consolidate(req).job_id)

@warnings.deprecated("Use Client instead")
class Consolidater(Client):
""" Deprecated: use Client instead """
pass
1 change: 0 additions & 1 deletion geocube/utils/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,4 @@
from geocube.utils.exceptions import catch_rpc_error, GeocubeError
from geocube.utils.aoi import read_aoi, plot_aoi
from geocube.utils.pb import pb_string, pb_null_timestamp
from geocube.utils.deprecated import deprecated
from geocube.utils.retry import exponential_retry, retry_on_geocube_error
15 changes: 0 additions & 15 deletions geocube/utils/deprecated.py

This file was deleted.