Skip to content

Commit 715bf58

Browse files
authored
Merge pull request #128 from astropenguin:astropenguin/issue127
Remove deprecated features
2 parents 7e4f315 + eb5f043 commit 715bf58

File tree

5 files changed

+1
-180
lines changed

5 files changed

+1
-180
lines changed

xarray_dataclasses/__init__.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ def _make_field_generic():
1818
# submodules
1919
from . import dataarray
2020
from . import dataset
21-
from . import deprecated
2221
from . import datamodel
2322
from . import dataoptions
2423
from . import typing
@@ -27,7 +26,6 @@ def _make_field_generic():
2726
# aliases
2827
from .dataarray import *
2928
from .dataset import *
30-
from .deprecated import *
3129
from .datamodel import *
3230
from .dataoptions import *
3331
from .typing import *

xarray_dataclasses/dataarray.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -84,12 +84,6 @@ def asdataarray(
8484
DataArray object created from the dataclass object.
8585
8686
"""
87-
try:
88-
# for backward compatibility (deprecated in v1.0.0)
89-
dataoptions = DataOptions(dataclass.__dataarray_factory__)
90-
except AttributeError:
91-
pass
92-
9387
try:
9488
dataoptions = dataclass.__dataoptions__
9589
except AttributeError:

xarray_dataclasses/datamodel.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,10 @@
99
# dependencies
1010
import numpy as np
1111
import xarray as xr
12-
from typing_extensions import TypedDict
12+
from typing_extensions import TypedDict, get_type_hints
1313

1414

1515
# submodules
16-
from .deprecated import get_type_hints
1716
from .typing import (
1817
ArrayLike,
1918
DataClass,

xarray_dataclasses/dataset.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -84,12 +84,6 @@ def asdataset(
8484
Dataset object created from the dataclass object.
8585
8686
"""
87-
try:
88-
# for backward compatibility (deprecated in v1.0.0)
89-
dataoptions = DataOptions(dataclass.__dataset_factory__)
90-
except AttributeError:
91-
pass
92-
9387
try:
9488
dataoptions = dataclass.__dataoptions__
9589
except AttributeError:

xarray_dataclasses/deprecated.py

Lines changed: 0 additions & 164 deletions
This file was deleted.

0 commit comments

Comments
 (0)