Skip to content

Commit 122b1dd

Browse files
ConchylicultorThe kauldron Authors
authored andcommitted
Raise an error when using deprecated property
PiperOrigin-RevId: 868099334
1 parent 1a3ced5 commit 122b1dd

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

kauldron/utils/sharding_utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,9 @@ def set_global_mesh(self) -> Iterator[None]:
105105
@property
106106
def ds(self):
107107
"""DEPRECATED: Use `batch` instead."""
108-
return self.batch
108+
raise DeprecationWarning(
109+
'`sharding.ds` is deprecated. Use `sharding.batch` instead.'
110+
)
109111

110112

111113
@dataclasses.dataclass(frozen=True, kw_only=True)

0 commit comments

Comments
 (0)