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

supabase / supabase-flutter / 29927200486
86%

Build:
DEFAULT BRANCH: main
Ran 22 Jul 2026 02:10PM UTC
Jobs 9
Files 103
Run time 1min
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

22 Jul 2026 02:09PM UTC coverage: 86.869%. Remained the same
29927200486

push

github

web-flow
docs(examples): add realtime Postgres Changes, Broadcast and Presence example (#1619)

## What

Adds a new `supabase_flutter` example, `realtime_room`, that
demonstrates all three Supabase Realtime features on a single channel:

- **Postgres Changes** stream inserts and deletes on a `messages` table,
keeping the chat log in sync across clients.
- **Broadcast** relays ephemeral "typing" pings that are never written
to the database.
- **Presence** tracks who is in the room and surfaces the live roster.

It follows the `database_crud` template: the realtime subscription lives
in `lib/room_channel.dart` (one `supabase.channel(...)` exposing the
three features as plain Dart streams), database reads/writes live in
`lib/room_repository.dart`, and the UI stays thin so the logic is easy
to drive from tests.

## Backend wiring

- New migration
`examples/supabase/migrations/20240602000000_realtime_room_example.sql`:
`messages` table added to the `supabase_realtime` publication, `replica
identity full`, RLS + anon policies + grants.
- Seed rows added to `examples/supabase/seed.sql`.
- No `config.toml` change needed (realtime is part of the always-on
local stack).
- Registered the example in the workspace root `pubspec.yaml` and the
`examples/README.md` table.

## Notable detail

`RoomChannel.subscribe()` uses `RealtimeChannelConfig(replicationReady:
true)` and waits for the replication-ready system event before
completing. Without this, a message inserted immediately after joining
is missed, because Postgres Changes replication is set up asynchronously
after the join is confirmed.

## Testing

- `flutter analyze`: no issues; `dart format`: clean.
- Verified end to end against a local stack (`supabase db reset`):
migration, publication membership, `replica identity full` and seed rows
confirmed on the running DB.
- Exercised the repository and channel against the live stack covering
all three features (insert/delete over Postgres Changes, typing over
Broadcast, tw... (continued)

5577 of 6420 relevant lines covered (86.87%)

3.92 hits per line

Jobs
ID Job ID Ran Files Coverage
1 yet_another_json_isolate - 29927200486.1 22 Jul 2026 02:10PM UTC 1
93.65
GitHub Action Run
2 realtime_client - 29927200486.2 22 Jul 2026 02:12PM UTC 11
90.16
GitHub Action Run
3 gotrue - 29927200486.3 22 Jul 2026 02:13PM UTC 28
87.6
GitHub Action Run
4 supabase - 29927200486.4 22 Jul 2026 02:11PM UTC 17
83.2
GitHub Action Run
5 postgrest - 29927200486.5 22 Jul 2026 02:12PM UTC 10
85.33
GitHub Action Run
6 supabase_flutter - 29927200486.6 22 Jul 2026 02:10PM UTC 10
79.31
GitHub Action Run
7 storage_client - 29927200486.7 22 Jul 2026 02:12PM UTC 13
84.63
GitHub Action Run
8 functions_client - 29927200486.8 22 Jul 2026 02:10PM UTC 3
98.85
GitHub Action Run
9 supabase_common - 29927200486.9 22 Jul 2026 02:10PM UTC 10
100.0
GitHub Action Run
Source Files on build 29927200486
  • Tree
  • List 103
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #29927200486
  • 7a500d24 on github
  • Prev Build on main (#29909032831)
  • Next Build on main (#29928677670)
  • 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