Skip to content
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
1 change: 1 addition & 0 deletions stdlib/VERSIONS
Original file line numberDiff line numberDiff line change
Expand Up@@ -35,6 +35,7 @@ _dummy_threading: 3.0-3.8
_heapq: 3.0-
_imp: 3.0-
_interpchannels: 3.13-
_interpqueues: 3.13-
_interpreters: 3.13-
_json: 3.0-
_locale: 3.0-
Expand Down
16 changes: 16 additions & 0 deletions stdlib/_interpqueues.pyi
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
from typing import Any, SupportsIndex

class QueueError(RuntimeError): ...
class QueueNotFoundError(QueueError): ...

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

I'm not seeing these actually get exported, might be because of:

// QueueEmpty and QueueFull are set by set_external_exc_types().state->QueueEmpty=NULL;
state->QueueFull=NUL

3.13.0b2

>>>import_interpqueuesasiq>>>iq.QueueEmptyTraceback (mostrecentcalllast):
File"<python-input-5>", line1, in<module>iq.QueueEmptyAttributeError: module'_interpqueues'hasnoattribute'QueueEmpty'>>>iq.QueueFullTraceback (mostrecentcalllast):
File"<python-input-6>", line1, in<module>iq.QueueFullAttributeError: module'_interpqueues'hasnoattribute'QueueFull'>>>


def bind(qid: SupportsIndex) -> None: ...
def create(maxsize: SupportsIndex, fmt: SupportsIndex) -> int: ...
def destroy(qid: SupportsIndex) -> None: ...
def get(qid: SupportsIndex) -> tuple[Any, int]: ...
def get_count(qid: SupportsIndex) -> int: ...
def get_maxsize(qid: SupportsIndex) -> int: ...
def get_queue_defaults(qid: SupportsIndex) -> tuple[int]: ...
def is_full(qid: SupportsIndex) -> bool: ...
def list_all() -> list[tuple[int, int]]: ...
def put(qid: SupportsIndex, obj: Any, fmt: SupportsIndex) -> None: ...
def release(qid: SupportsIndex) -> None: ...