Skip to content

Add max queue size functionality to CoroQueue and related components#53

Merged
semiversus merged 5 commits intomasterfrom
52-limit-sinkasync-coro-queue
Feb 12, 2026
Merged

Add max queue size functionality to CoroQueue and related components#53
semiversus merged 5 commits intomasterfrom
52-limit-sinkasync-coro-queue

Conversation

@phettberg
Copy link
Collaborator

  • Introduced MaxQueueException for handling queue size limits.
  • Updated CoroQueue to accept max_queue_size parameter.
  • Modified MapAsync and SinkAsync to support max_queue_size.
  • Added tests for queue size threshold behavior.

- Introduced MaxQueueException for handling queue size limits.
- Updated CoroQueue to accept max_queue_size parameter.
- Modified MapAsync and SinkAsync to support max_queue_size.
- Added tests for queue size threshold behavior.
@phettberg phettberg linked an issue Feb 11, 2026 that may be closed by this pull request
@phettberg phettberg self-assigned this Feb 11, 2026
@phettberg
Copy link
Collaborator Author

phettberg commented Feb 11, 2026

@flofeurstein, could you please already review? I'll fix the CI faults later.
@semiversus, how important is Python 3.8 support to you?

@semiversus
Copy link
Owner

Python 3.8 and Python 3.9 are end of life, so you can drop the support of them.

Copy link
Collaborator

@flofeurstein flofeurstein left a comment

Choose a reason for hiding this comment

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

Good job!

@phettberg phettberg linked an issue Feb 12, 2026 that may be closed by this pull request
- Update Python versions in CI workflow to include 3.12 and 3.13
- Add ruff for linting and coding style checks
- Update test functions to solipsism even tloop
Removed old virtual eventloop (replaced by async-solipsism module)
@phettberg
Copy link
Collaborator Author

  • VirtualEventLoop had compatibility issues with newer Python versions - replaced it with async-solipsism
  • pylama can't execute with Python 3.12, and they just won't fix it: Fixes to work with Python 3.12+ klen/pylama#254
  • flake8 has compatibility issues with Python 3.14. When using the newest flake8, it'll throw a lot of errors as new rules were added
  • I dropped pylama and flake8 and replaced them with ruff. However, I can't really replace the checks 1:1, but I've tried the best I could. This is the current rule set:
# pycodestyle (E, W)
# mccabe (C90)
# flake8-bugbear (B)
# flake8-async (ASYNC)
# flake8-builtins (A)
# flake8-annotations (ANN) not used
# flake8-quotes (Q) not used
# pylint (PLC, PLE, PLR, PLW) not used
# ...
[tool.ruff.lint]
select = ["E", "W", "C90", "A", "B", "ASYNC"]

[tool.ruff.lint.flake8-quotes]
inline-quotes = "single"
  • I did not try to fix code style or other issues by more use of linting or style checks; I just don't have the time. Furthermore, it's an act, do decide, what you want to check anyway.

@phettberg phettberg requested a review from semiversus February 12, 2026 14:08
@phettberg phettberg added the enhancement New feature or request label Feb 12, 2026
@semiversus semiversus merged commit 1c8e719 into master Feb 12, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Outdated tooling and support of Python >= 3.12 Limit SinkAsync coro queue

3 participants