• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

supabase / supabase-py / 41641996150 / 13
98%
main: 98%

Build:
DEFAULT BRANCH: main
Ran 03 Nov 2026 01:14PM UTC
Files 18
Run time 0s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

03 Nov 2026 01:10PM UTC coverage: 97.977%. Remained the same
41641996150.13

push

github

web-flow
chore(realtime): remove unused _leave_open_topic (#1930)

Resolves SDK-2676.

## What

Removes `AsyncRealtimeClient._leave_open_topic()`. Nothing called it, so
coverage always reported it as uncovered. Also removes the `AsyncMock`
stub for it in `tests/test_presence.py`.

## Why delete instead of wiring it up

- **realtime-js never called it from `channel()`.** In realtime-js v2
(and in phoenix.js, where it comes from), the only caller of
`_leaveOpenTopic` was `RealtimeChannel._rejoin()`. `channel()` returned
the existing channel for the topic. realtime-js removed it in
supabase/supabase-js#2119 when it switched to phoenix's JS client.
- **Python already removed that same caller on purpose.** `git log -S
_leave_open_topic` shows that cfbe5943 (#1346, "ammend reconnect logic
to not unsubscribe") replaced the call in `_rejoin()` with a log line.
During a reconnect the helper found the rejoining channel itself and
unsubscribed it. The method has been dead since then. Its only other
appearance is the test stub added in 6be6c0cd.
- **It can't find a duplicate.** `self.channels` is a dict keyed by
topic, so the helper could only ever match `self.channels[topic]`, which
is the channel being joined. When `channel()` replaces a leaving
channel, the old instance is dropped from the dict and is already
leaving, not joined or joining. `_remove_channel()` only deletes the
entry if it is still the same instance, so the replacement is safe
without this helper.

## Testing

- `git grep leave_open` returns nothing.
- `make ruff` is clean.
- With realtime infra running, `uv run --frozen --package realtime
pytest tests` gives 116 passed, including `test_channel_rejoin.py`,
`test_subscription_status.py` and `test_presence.py`.
- `uv run --frozen --package realtime mypy src/realtime tests` reports
no issues.

## Review

I reviewed the diff with `/code-review` (high effort). It found no
issues, so nothing changed.

1017 of 1038 relevant lines covered (97.98%)

0.98 hits per line

Source Files on job run-ubuntu-latest-3.11-functions - 41641996150.13
  • Tree
  • List 18
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 41641996150
  • ca09489d on github
  • Prev Job for on main (#41641937400.13)
  • Next Job for on main (#41643835757.5)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc