diff --git a/poetry.lock b/poetry.lock index 6622f4f..0512439 100644 --- a/poetry.lock +++ b/poetry.lock @@ -14,14 +14,14 @@ files = [ [[package]] name = "asyncgui" -version = "0.8.0" +version = "0.9.3" description = "A minimalistic async library that focuses on fast responsiveness" optional = false python-versions = "<4.0,>=3.9" groups = ["main"] files = [ - {file = "asyncgui-0.8.0-py3-none-any.whl", hash = "sha256:69b5d9aae17283c2bbb948c8f93cd03c2bbca5c060bbbce11ceeecb0292e5c03"}, - {file = "asyncgui-0.8.0.tar.gz", hash = "sha256:daca14460f42c04586a4f824ccb7b43c24ea6cbda5ee3852aef43db5b69fe83c"}, + {file = "asyncgui-0.9.3-py3-none-any.whl", hash = "sha256:ed73fc00c68d7e0d804eb239f2ad9c319dce57a5d31342c19aadc18f44270103"}, + {file = "asyncgui-0.9.3.tar.gz", hash = "sha256:46b283946a1814f600b502ee48082be9681097a72d8d011305e453d683a9064b"}, ] [package.dependencies] @@ -715,4 +715,4 @@ zstd = ["zstandard (>=0.18.0)"] [metadata] lock-version = "2.1" python-versions = "^3.10" -content-hash = "2956f3254f29ccd2d8d8ddcaff9717701a5089c7ab3b679bfe07d60acec4bb97" +content-hash = "7d7745bae3bb7d5043353a8442c90e644edd605ce32f5fe8c4286608e544d767" diff --git a/pyproject.toml b/pyproject.toml index 99fbde0..82f6a26 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "asyncgui-ext-queue" -version = "0.3.0" +version = "0.3.1" description = "An asyncio.Queue equivalence for asyncgui" authors = ["Nattōsai Mitō "] license = "MIT" @@ -26,7 +26,7 @@ packages = [ [tool.poetry.dependencies] python = "^3.10" -asyncgui = ">=0.7,<0.9" +asyncgui = ">=0.9.3,<1.0.0" [tool.poetry.group.dev.dependencies] pytest = "^8.0" diff --git a/src/asyncgui_ext/queue.py b/src/asyncgui_ext/queue.py index 5707149..b548f6c 100644 --- a/src/asyncgui_ext/queue.py +++ b/src/asyncgui_ext/queue.py @@ -284,15 +284,15 @@ def transfer_items(self, *_unused): while True: while (not self.is_full) and putters: putter, item = next_putter() - if (cb := putter._callback) is not None: + if (task := putter._waiting_task) is not None: c_put(item) - cb(None) + task._step(None) if (not getters) or self.is_empty: break while (not self.is_empty) and getters: getter = next_getter() - if (cb := getter._callback) is not None: - cb(None, c_get()) + if (task := getter._waiting_task) is not None: + task._step(None, c_get()) if (not putters) or self.is_full: break finally: