Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 2.1k
stdlib: Add several missing @abstractmethod decorators#7443
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
Uh oh!
There was an error while loading. Please reload this page.
Changes from all commits
6767315cd862ea89843325dc1a8e53163d317bf72d67e51a08d181e692adb46910f7ee95b75bf413929d12f7c45cf1447b8825f97247fedbee35c18File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -2,6 +2,7 @@ import sys | ||
| import threading | ||
| from contextlib import AbstractContextManager | ||
| from multiprocessing.context import BaseContext | ||
| from types import TracebackType | ||
| from typing import Any, Callable, Union | ||
| __all__ = ["Lock", "RLock", "Semaphore", "BoundedSemaphore", "Condition", "Event"] | ||
| @@ -28,8 +29,11 @@ class Condition(AbstractContextManager[bool]): | ||
| def wait_for(self, predicate: Callable[[], bool], timeout: float | None = ...) -> bool: ... | ||
| def acquire(self, block: bool = ..., timeout: float | None = ...) -> bool: ... | ||
| def release(self) -> None: ... | ||
| def __exit__( | ||
| self, __exc_type: type[BaseException] | None, __exc_val: BaseException | None, __exc_tb: TracebackType | None | ||
| ) -> None: ... | ||
| class Event(AbstractContextManager[bool]): | ||
MemberAuthor 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. This class doesn't seem to be a context manager at runtime, and doesn't seem to have ever been a context manager at runtime. | ||
| class Event: | ||
| def __init__(self, lock: _LockLike | None = ..., *, ctx: BaseContext) -> None: ... | ||
| def is_set(self) -> bool: ... | ||
| def set(self) -> None: ... | ||
| @@ -49,3 +53,6 @@ class Semaphore(SemLock): | ||
| class SemLock(AbstractContextManager[bool]): | ||
| def acquire(self, block: bool = ..., timeout: float | None = ...) -> bool: ... | ||
| def release(self) -> None: ... | ||
| def __exit__( | ||
| self, __exc_type: type[BaseException] | None, __exc_val: BaseException | None, __exc_tb: TracebackType | None | ||
| ) -> None: ... | ||
Uh oh!
There was an error while loading. Please reload this page.