Skip to content

Commit

Permalink
Add PendingDeprecationWarning for map_direct (#682)
Browse files Browse the repository at this point in the history
  • Loading branch information
tomwhite authored Jan 22, 2025
1 parent e38aed5 commit 9f67ec8
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions cubed/core/ops.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
from numbers import Integral, Number
from operator import add
from typing import TYPE_CHECKING, Any, Sequence, Tuple, Union
from warnings import warn

import ndindex
import numpy as np
Expand Down Expand Up @@ -982,6 +983,11 @@ def map_direct(
Specification for the new array. If not specified, the one from the first side input
(`args`) will be used (if any).
"""
warn(
"`map_direct` is pending deprecation, please use `map_selection` instead",
PendingDeprecationWarning,
stacklevel=2,
)

from cubed.array_api.creation_functions import empty_virtual_array

Expand Down

0 comments on commit 9f67ec8

Please sign in to comment.