Skip to content

Conversation

loicdiridollou
Copy link
Member

It turns out you can't actually make it fully private with _ at the start of the name as it will raise a lint with PYI (it does not see it used in the file itself although it is used outside the file).

pandas-stubs/_libs/lib.pyi:17:1: PYI047 Private TypeAlias `_NoDefaultDoNotUse` is never used
   |
16 | no_default: Final = _NoDefault.no_default
17 | _NoDefaultDoNotUse: TypeAlias = Literal[_NoDefault.no_default]
   | ^^^^^^^^^^^^^^^^^^ PYI047
18 |
19 | def infer_dtype(value: object, skipna: bool = ...) -> str: ...
   |

Found 1 error. 

@loicdiridollou loicdiridollou requested a review from Dr-Irv June 24, 2025 20:58
Copy link
Collaborator

@Dr-Irv Dr-Irv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's make it private and just put a # noqa: PYI047 on that line.

Copy link
Collaborator

@Dr-Irv Dr-Irv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Dr-Irv Dr-Irv merged commit 9c49879 into pandas-dev:main Jun 25, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Change use of NoDefault to be private and maybe indicate it shouldn't be passed

2 participants