Skip to content

Fix idle ConnectionManager shutdown - #10

Merged
nekrasovp merged 1 commit into
mainfrom
fix/issue-9-idle-stop
Aug 25, 2026
Merged

Fix idle ConnectionManager shutdown#10
nekrasovp merged 1 commit into
mainfrom
fix/issue-9-idle-stop

Conversation

@nekrasovp

Copy link
Copy Markdown
Contributor

Summary

  • cancel and await idle websocket reader tasks in the Polymarket, Kalshi, and Opinion connection managers
  • let an already-started callback dispatch complete before cancellation, preserving existing delivery behavior
  • make pre-start and repeated stop calls safe without consumer access to private task attributes
  • add focused lifecycle regression, negative, and idempotency coverage and document the public lifecycle

Validation

  • uv sync --group dev
  • uv run ruff check .
  • uv run mypy
  • uv run pytest -q -s (58 passed)
  • uv build
  • uv run twine check dist/*
  • uv run mkdocs build --strict
  • exact commit independently verified with the same gate in a git clone --no-local checkout

Closes #9.

Cancel and await idle websocket readers across all venue managers while allowing in-flight dispatch to complete. Add lifecycle regressions and document public stop semantics.\n\nCloses #9.
@nekrasovp
nekrasovp merged commit a3717e2 into main Aug 25, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: ConnectionManager.stop() can hang on idle websocket streams

1 participant