16 KiB
16 KiB
Doghouse 0.3.0
Release notes, filled in as milestones land. The detailed engineering notes per milestone
(CHANGES-M11.md to CHANGES-M13.md) are in the repository, not in the zip.
M11: install it as an app
- Doghouse can be installed to the home screen or desktop (manifest, icons, install button in Settings > App and notifications; iPhone steps shown there).
- A service worker shows a friendly offline page when the server can't be reached. It caches no app files, so an upgrade can't leave you on a mix of old and new.
- Upgrades: a new version takes over when you have only one Doghouse window open and aren't in a call or voice channel. Otherwise it waits until you close the other windows or leave the call.
- Nothing to configure. Your reverse proxy must not cache
/sw.jsor/manifest.webmanifest.
M12: push notifications
- Switch notifications on per device in Settings > App and notifications (asked only then), with a Send test button. DMs and group chats notify for every message; servers for @mentions and replies. Levels per server, channel and DM; Do Not Disturb; quiet hours in your own time zone.
- "Show message content" off: the notification says only who wrote, and the push carries no text.
- No notification for what you are looking at in a focused tab; a burst of messages folds into one "N new messages" notification; tapping opens the right conversation.
- Self-hosted Web Push: a key pair is made on first start in
data/vapid.json(in your backup). Your server needs outbound HTTPS to Google/Apple/Mozilla push services. - Database migration 008 (automatic). Roll back only from a backup.
- @mentions are highlighted in messages.
M13: ringing calls and ringtones
- A DM or group call rings: the other people get a card with Accept and Decline, a looping tone
(three built-in tones, or your own), and a vibration on phones. The caller hears a soft ringback.
With the app closed, a push rings the phone: Accept opens the app on the call (the browser needs
a tap before it will open the microphone), Decline declines. A ring push lives 30 s at most; a
call-endpush clears it when the caller hangs up or someone answers. - No loud ring (the card still shows) with Do Not Disturb, in quiet hours, or while you are already in a call. Two tabs of one browser: only the visible tab rings aloud; both show the card.
- Settings > App and notifications: choose a tone, preview it, set the volume, or "Use my own ringtone" (mp3, ogg Vorbis/Opus or wav, up to 1 MB and 30 s). Your file is checked in the page and stays on that device (never uploaded); it survives logout, another account on the same browser gets the default, and Remove deletes it.
- Pushes go through two queue lanes so a slow message push can't delay a ring: calls 16 at a time with a 4 s timeout (dropped if they waited over 20 s), messages 8 at a time with a 10 s timeout. A message push to an endpoint that timed out is skipped for 60 s; rings never are.
- Push housekeeping: 408 and 413 are treated as temporary; five other client errors within 24 h switch a device off ("Not working" in Settings); a success resets the count; duplicate device rows are merged at start-up.
- Details and review fixes:
CHANGES-M13.md(in the repository, not in the zip).
M14: clean-up
- Two tabs, one ring (QA-39): a BroadcastChannel claim, visible tab first. It fails open: a hidden tab waits about 300 ms for a visible tab and rings if none answers; a visible tab that freezes can't leave the ring silent (the other tab rings again within about 4 to 5 s). No Web Lock is used.
- A tab in a call tells the other tabs of the browser (QA-50), which then don't ring aloud (the card still shows). A tab that crashes or freezes is forgotten after about 4 s, so it can't silence them for good.
- A late LiveKit
room_finishedof an earlier call in the same DM can no longer end the new call (QA-54): the call remembers its LiveKit room session id and ignores aroom_finishedfor another session or from before the call started; as a backstop the server asks LiveKit whether anyone is still in the room first (and ends the call as before if LiveKit can't be asked). - The call room name is reused for every call in a DM, so the server no longer removes people or
deletes the room by name on a normal path: a normal leave, and a call ending with nobody in it,
make no LiveKit change at all (the client has already disconnected; LiveKit closes an empty room
itself). When someone must be forced out (a declined 1:1 whose caller is still connected, a
member removed from a group, joining a voice channel, an outsider in the room) the server first
looks that session up and removes only that session, and does nothing if LiveKit can't be asked
(the app's own
call:statealso makes the client leave). The onlydeleteRoomleft is the start-up cleanup of rooms that have no call and the deletion of a group's room when the group itself is gone. - LiveKit's own room timeouts are already set, with no action needed and nothing new in 0.3.0:
deploy/livekit.yamlhas hadroom.empty_timeout: 300(an empty room is closed after 5 minutes) anddeparture_timeout: 20since 0.1.x, and it anddocker-compose.ymlare identical to 0.2.0. Only the e2e LiveKit config uses 10 and 5. There is no other LiveKit config in the repo (no separate dev one). Nothing needs changing: a room that is still open when the next call in the DM starts is simply reused, which the session checks above allow for. - Built-in tone format (QA-42): if the first format (ogg or m4a) won't decode, the other is tried once, then silence without an error loop.
- Custom ringtone checks (QA-41, rest): the WAV duration is read by walking the RIFF chunks (a big
chunk before
datano longer hides it); an mp3 with some junk before its first frame is accepted (two real frames in the first 4 KB), ADTS AAC is refused; an Ogg must carry Vorbis or Opus (Ogg-FLAC, Speex and Theora are refused before decoding). Size is still checked first, then the format. - e2e skip audit (below).
Environment variables new in 0.3
| Var | Default | Notes |
|---|---|---|
VAPID_PUBLIC_KEY, VAPID_PRIVATE_KEY |
generated into data/vapid.json |
Set both or neither. Changing keys makes every device switch notifications on again |
PUSH_ENDPOINT_ALLOW |
empty | Extra push-service hosts (host or *.suffix, https only). Needed only if your browser's push service isn't Google, Apple, Mozilla or Windows |
PUSH_TEST_ORIGINS |
empty | Tests only (read only when NODE_ENV=test): lets the e2e suite point pushes at a local mock. Ignored in production |
CALL_RING_TIMEOUT_MS |
30000 |
Existing since 0.2.0; the ring push TTL is capped at 30 s whatever this says |
Limits: 10 devices per account (an 11th replaces the one that last received a push longest ago).
Upgrading from 0.2.0 and rolling back
- Upgrade as in the README ("Upgrading 0.2.0 -> 0.3.0"). Migration
008_push.sqlruns on start (additive: push devices, notification settings, user columns). A newdata/vapid.jsonappears; it is part of your backup. - No new ports. Your reverse proxy must not cache
/sw.jsor/manifest.webmanifest. - Rollback: stop 0.3.0, restore the backup taken before the upgrade into the 0.2.0 folder, start 0.2.0. Do not run 0.2.0 on upgraded data.
- Custom ringtones live in each browser (IndexedDB) and are not in your backup.
Developers: the e2e skip audit (M14)
A full e2e run (REQUIRE_LIVEKIT=1) is 52 passed, 44 skipped, 0 failed. All 44 skips were checked
and are intentional; none was stale or accidental (no test is skipped for a missing LiveKit when
REQUIRE_LIVEKIT=1, which fails instead). Each skip now says why in its own message.
- Desktop-only tests (42 skipped in the phone project): the test builds its own browsers or
viewports, or the thing it checks isn't viewport dependent, so a second run adds nothing.
call-recall.spec(1),call-restart.spec(1),calls.spec(7),dm-presence.spec(2),groups.spec(1),profiles.spec(1),push.spec(4),pwa.spec(14: worker, offline, install and upgrade lifecycle),realtime.spec(1),ringing.spec(3),ringtone.spec(4),server-media.spec(1),voice.spec(1),xss.spec(1). - Phone-only tests (2 skipped in the desktop project): the 320 px composer layout
(
composer-layout.spec) and the phone layout check inpwa.spec. - Missing LiveKit: skips only when
REQUIRE_LIVEKITis not 1 (nolivekit-serverbinary); with it set the suite fails instead of hiding the voice tests. - Skip policy (also at the top of
e2e/playwright.config.ts): the suite runs in a desktop and a phone project. A test that builds its own browsers or viewports, or isn't viewport dependent, runs once, in the desktop project, and skips in the phone project with a reason startingdesktop only:. A layout check that only makes sense on a phone runs only in the phone project and starts its reason withphone only:. The only other skip is a missing LiveKit binary, andREQUIRE_LIVEKIT=1turns that into a failure. Every new skip needs a reason of one of these kinds; a baretest.skipor a skip without a reason is not allowed. A full run reports 44 skipped (42 desktop-only skips in the phone project, 2 phone-only skips in the desktop project) today.
Fixes found in review
- Upgrades could occasionally stay on the old service worker when the page reloaded right as the new worker was waiting; the page now waits for the page to settle before asking it to take over.
- A call or voice channel is now protected from worker upgrades from the moment you click Join until you leave, including the short automatic reconnect.
Developers
- e2e ports, screenshot and artifact folders are env vars (
e2e/ports.mjs), so suites can run side by side. E2E_UNIQUE_OUTPUT=1gives each e2e run its own output folder (test-results/e2e-<time>), so loops don't overwrite earlier failures.ringing.specsaves each page's console and thecall:*events the server sent it into the test's output folder (and attaches them).call-restart.spec.ts(real LiveKit): ends a call and at once starts a new one in the same DM (people take turns, since one person may start 10 calls per 10 minutes) and checks that each new call is still the DM's active call, with its caller connected, 6 s later. It runs 3 restarts by default;E2E_RAPID_RESTARTS=20 npm run e2e:only -- call-restart.spec.tsruns a longer one (about 7 s per restart). Checked against the code before the QA-54 fixes (ae56d85): it did not fail there (20 of 20 restarts survived, idle and under load), so it is a regression guard for the race rather than a reproduction of it; the server tests are what pin the fix.E2E_SERVER_LOG=<file>keeps the e2e app server's log, andE2E_LOG_LEVEL=infomakes it include every LiveKit kick, removal, room delete and call-end decision (reason, identity, room, sid, call id; QA-58).E2E_LIVEKIT_LOG=info(defaultwarn) sets the e2e LiveKit server's log level; its log islivekit.login the run's data folder.call-recall.spec.ts(real LiveKit): cancel a call and call again at once, with the hang-up slowed down (E2E_LEAVE_DELAY_MS, default 400;E2E_RECALL_CYCLES=N).- e2e fails early with a clear message if its ports are busy, and kills leftover servers when it finishes.
Known issues
- Starting a call within a second or two of cancelling or timing out another call in the same chat
can, rarely, drop the new call at connect. Calling again works. Seen about 2 times in roughly 400
related test runs, and once only under heavy CPU load. The suspected cause (the hang-up request
being overtaken by the next start) is fixed on the client and covered by a server test, but it
was never reproduced in a browser, so the cause is not proven. With
E2E_LOG_LEVEL=infothe server logs who removed a call participant and why. Fixed in 0.3.1 (seeCHANGES-0.3.1.md): the cause was found and each call now has its own LiveKit room.
Real-device checklist (phone and desktop)
Nothing here can be proven by the automated tests; do it once on real hardware before shipping.
- Real push round trip: on Android Chrome, switch notifications on, close the app completely, have someone DM you: the notification appears and tapping opens that DM. Repeat with the phone locked. Turn "Show message content" off and check it only says who wrote. Log out and check the phone stops getting them.
- iPhone: iOS 16.4 or later, Safari, Add to Home Screen, then switch notifications on from the installed app (not from Safari). Check a DM push and a call ring push arrive with the app closed, the status bar and notch / home-indicator insets in the installed app, and that the call card fits. Settings shows the steps if you try from a Safari tab.
- Install: Android Chrome Install; desktop Chrome or Edge Install.
- Ringing, with the app closed: call the phone; it rings (system notification sound, plus the notification with Accept and Decline). Accept opens the app on the call and you tap Accept there; Decline from the notification declines. Put the phone offline for over 30 s while it's called, then bring it back online: no late ring.
- Android notification buttons: Accept and Decline on the call notification, and a missed call shows "Missed call from X" afterwards.
- Loud-ring suppression in a call: while on a call (or in a voice channel), have a second person call you: the card shows but there is no loud ring; the same with Do Not Disturb on.
- DND and quiet hours, by ear: with DND on, a call card is silent and there is no vibration or push sound; set quiet hours that include now (in your own time zone) and check the same; turn both off and check it rings again. The caller's ringback is silent too in DND and quiet hours.
- Safari AAC decode: on iPhone/Mac Safari, the three built-in tones play (they are
.m4athere), loop with no gap or click, and the preview works. Try a custom mp3 and a custom wav (and an ogg on recent Safari): accepted ones play, an undecodable one gets a clear message. - Tone quality by ear: listen to Classic phone, Soft marimba and Doghouse jazz on the phone speaker and on headphones: loop seam, loudness at 70% (default), at 100% (capped), and the ringback pulse.
- 10-device cap: register notifications on 11 devices or browsers for one account (a few browser profiles will do): the 11th works and the one that received a push longest ago stops getting them. Server tests cover the rule; this only confirms it with real devices.
- Push lanes: with a push endpoint that hangs, ring pushes to your other devices still arrive
within a couple of seconds and a message push to the blocked one backs off. Blocking is per push-service
host (Chrome and Android use Google's FCM, Safari/iPhone use Apple's, Firefox uses Mozilla's), so
use a Firefox or Apple device alongside a Chrome device: block only one host with the firewall (for
example
fcm.googleapis.com) and check the other device still gets its ring. Two Chrome/FCM devices would be blocked together and prove nothing. Server tests (push-lanes.test.ts) cover this with fake endpoints; the real check is only that nothing in front of your server changes it. - Two tabs: on desktop, open Doghouse in two tabs and ring yourself from another account: only the tab you are looking at rings aloud; switching tabs moves the sound; both show the card.
- Rejoin gap with a forced network drop: drop the connection mid-call (airplane mode for a few seconds, or switch Wi-Fi off), let the call rejoin on its own, and with a new version deployed, confirm the upgrade does not swap the worker during the rejoin gap (the call keeps going and the tab is not reloaded). It should only swap after you leave the call.