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

supabase / realtime-py / 16576482377 / 2
82%
main: 82%

Build:
DEFAULT BRANCH: main
Ran 28 Jul 2025 06:00PM UTC
Files 17
Run time 1s
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

28 Jul 2025 05:56PM UTC coverage: 82.404% (+1.3%) from 81.078%
16576482377.2

push

github

web-flow
feat: validate server message (#345)

* chore: introduce `ServerMessage` and `ClientMessage` types

`ServerMessage` represents all the different message types that a
server might send to a client
`ClientMessage` represents all the different message types that a
client might send to a server

these are there to validate the payload types, enforcing the
correctness of the payloads

* fix: improve messages schema

now all of messages should be valid

* feat: introduce `ServerMessage` parsing

now, instead of parsing and dispatching the messages inside the
`AsyncRealtimeChannel._trigger` function, first parse the message
using pydantic's `ServerMessageAdapter` type adapter, and then
dispatch the callbacks inside `_handle_message`, based on which
message was parsed.

this required the removal of the `_on` function, which was used to
both define callbacks to messages, but also to define callbacks to
event refs, which was very confusing. this behavior was used precisely
to define callbacks that are called on acks.

now, AsyncPush'es are saved in
AsyncRealtimeChannel.messages_waiting_for_ack, and later the callbacks
registered by `AsyncPush.receive` (now saved directly in the push
object) are called when a `phx_reply` type message is received.

some logic was introduce to avoid this message buffer from growing
forever indefinetly, by removing these messages from the dictionary
once the callback is called, or once the timeout is reached.

754 of 915 relevant lines covered (82.4%)

0.82 hits per line

Source Files on job run-ubuntu-latest-3.13 - 16576482377.2
  • Tree
  • List 17
  • Changed 6
  • Source Changed 0
  • Coverage Changed 6
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 16576482377
  • 8c6066e6 on github
  • Prev Job for on main (#16204567293.4)
  • Next Job for on main (#16576671696.3)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc