Skip to content

Commit 9e60370

Browse files
committed
🩹 Fix numpy<2.1 invariant shape-type issue
1 parent 0712dc3 commit 9e60370

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎scipy-stubs/optimize/_optimize.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ _AllVecs: TypeAlias = list[_Int1D | _Float1D]
7070
_ResultValueT = TypeVar("_ResultValueT", default=Any)
7171
_XT_contra = TypeVar("_XT_contra", bound=_ComplexCo1D, default=_Float1D, contravariant=True)
7272
_ValueT_co = TypeVar("_ValueT_co", bound=float | npc.floating, default=_Float, covariant=True)
73-
_JacT_co = TypeVar("_JacT_co", bound=onp.Array[tuple[int] | tuple[int, int], npc.floating], default=_Float1D, covariant=True)
73+
_JacT_co = TypeVar("_JacT_co", bound=onp.Array1D[npc.floating] | onp.Array2D[npc.floating], default=_Float1D, covariant=True)
7474

7575
@type_check_only
7676
class _DoesFMin(Protocol):

0 commit comments

Comments
 (0)