Skip to content
Open
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ Also, that release drops support for Python 3.9, making Python 3.10 the minimum
* Refactored `dpnp.fft` and `dpnp.random` submodules by removing wildcard imports and defining explicit public exports [#2649](https://github.com/IntelPython/dpnp/pull/2649)
* Added support for the `out` keyword to accept a tuple, bringing ufunc signatures into alignment with those in NumPy [#2664](https://github.com/IntelPython/dpnp/pull/2664)
* Unified public API definitions in `dpnp.linalg` and `dpnp.scipy` submodules [#2663](https://github.com/IntelPython/dpnp/pull/2663)
* Aligned the signature of `dpnp.reshape` function with Python array API by making `shape` a required argument [#2673](https://github.com/IntelPython/dpnp/pull/2673)

### Deprecated

Expand Down
9 changes: 1 addition & 8 deletions dpnp/dpnp_iface_manipulation.py
Original file line number Diff line number Diff line change
Expand Up @@ -3013,7 +3013,7 @@ def require(a, dtype=None, requirements=None, *, like=None):
return arr


def reshape(a, /, shape=None, order="C", *, copy=None):
def reshape(a, /, shape, order="C", *, copy=None):
"""
Gives a new shape to an array without changing its data.

Expand All @@ -3028,8 +3028,6 @@ def reshape(a, /, shape=None, order="C", *, copy=None):
an integer, then the result will be a 1-D array of that length.
One shape dimension can be -1. In this case, the value is
inferred from the length of the array and remaining dimensions.

Default: ``None``.
order : {None, "C", "F", "A"}, optional
Read the elements of `a` using this index order, and place the
elements into the reshaped array using this index order. ``"C"``
Expand Down Expand Up @@ -3113,11 +3111,6 @@ def reshape(a, /, shape=None, order="C", *, copy=None):

"""

if shape is None:
raise TypeError(
"reshape() missing 1 required positional argument: 'shape'"
)

if order is None:
order = "C"
elif order in "aA":
Expand Down
Loading