Skip to content

refactor(telegram): drop the flood-stack compat shims - #1434

Merged
axisrow merged 1 commit into
mainfrom
refactor/drop-flood-shims
Sep 1, 2026
Merged

axisrow merged 1 commit into
mainfrom
refactor/drop-flood-shims

Conversation

@axisrow

@axisrow axisrow commented Sep 1, 2026

Copy link
Copy Markdown
Owner

What

Final cleanup of the extraction epic: the four src/telegram re-export shims (flood_wait, rate_limiter, rate_limit_gate, flood_breaker) are deleted; all ~50 importer files (26 src + 22 tests) now import telethon_floodgate directly. Also removes the zero-consumer run_with_flood_wait backward-compat re-export in client_pool.

No code is deleted that still exists here — the bodies moved to the package in #1432; this removes the import-path bridge only.

Verified

  • zero references to the four shim paths in src/tests (grep guard)
  • ruff clean (64 import blocks auto-re-sorted), import-linter contract kept
  • full suite (CI-config venv): 9383 passed parallel + 990 serial; failure set identical to main modulo known flakes (quality_scoring, search_routes, integration, photo_loader, debug_memory — last two re-verified green in isolation)
  • DIALOG_SWEEP_MAX_CALLS cross-invariant test switched to the module-path import (not in the package root __all__)

🤖 Generated with Claude Code

The four src/telegram shims (flood_wait, rate_limiter, rate_limit_gate,
flood_breaker) were re-export-only bridges kept by the extraction PR
(#1432) so ~50 importer files would not change in the migration commit.
All imports now go to telethon_floodgate directly and the shims are
deleted — no duplicated code remains in this repository.

- the backward-compat run_with_flood_wait re-export in client_pool is
  removed too (zero importers and zero patch targets, verified)
- DIALOG_SWEEP_MAX_CALLS keeps its module-path import (not in the
  package root __all__)
- pybreaker stays a dependency (notifier.py imports it directly)

Verified: zero references to the four shim paths anywhere; ruff clean
(64 import blocks re-sorted); import-linter contract kept; full suite in
the CI-config venv: 9383 passed parallel + 990 serial, failure set
identical to main modulo the known flakes (quality_scoring, search_routes,
integration, photo_loader, debug_memory — the last two pass in isolation).

Co-Authored-By: Claude Code <noreply@anthropic.com>
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.

1 participant