-
-
Notifications
You must be signed in to change notification settings - Fork 2k
Fix 3.15 stdlib stubtest #15863
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
Fix 3.15 stdlib stubtest #15863
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -12,22 +12,17 @@ def abs_paths() -> None: ... # undocumented | |||||||||||||||||||||
| def addpackage(sitedir: StrPath, name: StrPath, known_paths: set[str] | None) -> set[str] | None: ... # undocumented | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| if sys.version_info >= (3, 15): | ||||||||||||||||||||||
| def process_startup_files() -> None: ... # undocumented | ||||||||||||||||||||||
| def addsitedir(sitedir: str, known_paths: set[str] | None = None, *, defer_processing_start_files: bool = False) -> None: ... | ||||||||||||||||||||||
| def addsitepackages( | ||||||||||||||||||||||
| known_paths: set[str] | None, prefixes: Iterable[str] | None = None, *, defer_processing_start_files: bool = False | ||||||||||||||||||||||
| ) -> set[str] | None: ... # undocumented | ||||||||||||||||||||||
| def addusersitepackages( | ||||||||||||||||||||||
| known_paths: set[str] | None, *, defer_processing_start_files: bool = False | ||||||||||||||||||||||
| ) -> set[str] | None: ... # undocumented | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| else: | ||||||||||||||||||||||
| def addsitedir(sitedir: str, known_paths: set[str] | None = None) -> None: ... | ||||||||||||||||||||||
| def addsitepackages( | ||||||||||||||||||||||
| known_paths: set[str] | None, prefixes: Iterable[str] | None = None | ||||||||||||||||||||||
| ) -> set[str] | None: ... # undocumented | ||||||||||||||||||||||
| def addusersitepackages(known_paths: set[str] | None) -> set[str] | None: ... # undocumented | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| class StartupState: | ||||||||||||||||||||||
| __slots__ = ("_known_paths", "_processed_sitedirs", "_path_entries", "_importexecs", "_entrypoints") | ||||||||||||||||||||||
| def __init__(self, known_paths: set[str] | None = None) -> None: ... | ||||||||||||||||||||||
| def addsitedir(self, sitedir: str) -> None: ... | ||||||||||||||||||||||
| def addusersitepackages(self) -> None: ... | ||||||||||||||||||||||
| def addsitepackages(self, prefixes: Iterable[str] | None = None) -> None: ... | ||||||||||||||||||||||
| def process(self) -> None: ... | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| def addsitedir(sitedir: str, known_paths: set[str] | None = None) -> None: ... | ||||||||||||||||||||||
| def addsitepackages(known_paths: set[str] | None, prefixes: Iterable[str] | None = None) -> set[str] | None: ... # undocumented | ||||||||||||||||||||||
| def addusersitepackages(known_paths: set[str] | None) -> set[str] | None: ... # undocumented | ||||||||||||||||||||||
|
Comment on lines
+24
to
+25
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should this really allow a
Suggested change
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hmm, this just matches the previous annotations here. I haven't changed the types of any of these parameters in this PR. I'm open to changing them, but I think it's outside the scope of this PR
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh, I think the lines are marked as "changed", since the indentation (for the
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Previous patch releases of 3.15 added a
Comment on lines
+23
to
+25
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I assume this was a mistake?
Suggested change
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. no, not a mistake -- see my reply at #15863 (comment). We don't need split definitions over two
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hmm, they exist on 3.14, but why were they indented before? Maybe we should move the whole problem with these functions to another PR altogether.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Again, I explained this in #15863 (comment). We previously had this: if sys.version_info >= (3, 15):
def addsitedir(new_parameter): ...
else:
def addsitedir(): ...but the addition of the new parameter in 3.15 was reverted, so now we just have this again, removing the indentation that was previously necessary: def addsitedir(): ... |
||||||||||||||||||||||
| def check_enableusersite() -> bool | None: ... # undocumented | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| if sys.version_info >= (3, 13): | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
Uh oh!
There was an error while loading. Please reload this page.