Skip to content

TYP: remove expired tostring methods #29050

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 25, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
TYP: remove expired tostring methods
  • Loading branch information
jorenham committed May 25, 2025
commit aaae32e45830a9b3d9c026d5e2d79390ccda50e6
4 changes: 1 addition & 3 deletions numpy/lib/_user_array_impl.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ from types import EllipsisType
from typing import Any, Generic, Self, SupportsIndex, TypeAlias, overload

from _typeshed import Incomplete
from typing_extensions import TypeVar, deprecated, override
from typing_extensions import TypeVar, override

import numpy as np
import numpy.typing as npt
Expand Down Expand Up @@ -220,8 +220,6 @@ class container(Generic[_ShapeT_co, _DTypeT_co]):

#
def copy(self, /) -> Self: ...
@deprecated("tostring() is deprecated. Use tobytes() instead.")
def tostring(self, /) -> bytes: ...
def tobytes(self, /) -> bytes: ...
def byteswap(self, /) -> Self: ...
def astype(self, /, typecode: _DTypeLike[_ScalarT]) -> container[_ShapeT_co, np.dtype[_ScalarT]]: ...
4 changes: 1 addition & 3 deletions numpy/ma/core.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ from collections.abc import Sequence
from typing import Any, Literal, Self, SupportsIndex, TypeAlias, overload

from _typeshed import Incomplete
from typing_extensions import TypeIs, TypeVar, deprecated
from typing_extensions import TypeIs, TypeVar

import numpy as np
from numpy import (
Expand Down Expand Up @@ -1057,8 +1057,6 @@ class MaskedArray(ndarray[_ShapeT_co, _DTypeT_co]):
def toflex(self) -> Incomplete: ...
def torecords(self) -> Incomplete: ...
def tolist(self, fill_value: Incomplete | None = None) -> Incomplete: ...
@deprecated("tostring() is deprecated. Use tobytes() instead.")
def tostring(self, /, fill_value: Incomplete | None = None, order: _OrderKACF = "C") -> bytes: ... # type: ignore[override]
def tobytes(self, /, fill_value: Incomplete | None = None, order: _OrderKACF = "C") -> bytes: ... # type: ignore[override]
def tofile(self, /, fid: Incomplete, sep: str = "", format: str = "%s") -> Incomplete: ...

Expand Down
Loading
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy