AAA 78e0d4194a fix(routing): recover failed connections across route transitions
## Problem and outcome / 问题与结果

An active media connection could fail while a replacement was being prepared, but its failure report was suppressed or attributed to the pending route. Separately, a room revision advanced by another Viewer could invalidate a delayed failure report for a connection that was still current, leaving playback stalled after the browser had already reported the failure.

Failure reporting now follows committed connection ownership. P2P and SFU reports carry the existing physical connection identity; the server accepts a delayed active failure only while that connection and its endpoint session still match. Preparation reports retain their exact operation checks, and stale connections, stale sessions and future revisions remain rejected. This adds no wire fields, recovery timers, dependencies or routing policy.

## Release notes

### 中文

这是一次连接恢复修复,改善分享过程中断线或画面停滞后的自动恢复。

- 修复自动切换线路期间,当前连接失效后可能未触发正确恢复的问题,覆盖 P2P 和服务器兜底线路。
- 修复其他观众加入等房间变化恰好发生时,延迟到达的故障反馈可能被忽略,导致画面停滞后无法自动恢复的问题。
- App 公网邀请或本地模式请房主更新 App 后重新分享,观众刷新页面。使用已部署站点时,请管理员更新 Server,房主和观众刷新页面。

### English

This patch improves automatic recovery when a connection fails or playback stalls during sharing.

- Fixed failures on the current connection being missed or attributed to the wrong route while Piik prepares a replacement. This covers P2P and server fallback connections.
- Fixed delayed failure reports being ignored after another Viewer joins or the room changes, which could leave playback stalled without automatic recovery.
- For App public invitations or Local mode, the Host should update the App and start sharing again; Viewers should reload the page. For a deployed site, update the Server, then refresh the page for the Host and all Viewers.

## Verification / 验证

- `npm run check`: typecheck, 71 test files / 1,003 tests, and the Web production build passed.
- `npm run check:go-core`: Go tests, formatting, vet and supported core target builds passed.
- Browser fault injection passed for delayed reports across room changes, Host and Viewer signaling reconnects, pending-candidate reauthentication, and source replacement during preparation. The previously reproduced stall recovered automatically with one failure report; process, profile and port cleanup passed.
- The embedded SFU H.264 simulcast gate passed with decoded video and audio, a live 720p to 480p profile change, and publication retirement.
- Focused regressions cover Host/Viewer and P2P/SFU report ownership, retired connections, wrong identities, stale sessions and future revisions. Documentation and repository hygiene checks passed.

These results do not establish the original reporter's specific cause. Physical Native capture, representative public networks and long-duration recovery remain outside this local acceptance.

## Impact / 影响

Patch release: **v1.5.3**. No wire, configuration or storage format changes; existing published message handlers remain compatible. The routing contract owns the updated failure-report rule, and TODO retains the outstanding reporter/device evidence boundaries.
2026-09-17 22:56:06 +08:00

Piik mascot

Piik

Share the good stuff.
Private screen sharing for you and up to 20 friends.

Website · Download · Gitee mirror · Use online · Documentation

License: MIT Up to 20 viewers P2P-first media

English · 简体中文

Piik is a free, open-source screen sharing tool for games, movie nights, drawings and photos. Choose what to share and send an invitation. Your friends watch in their browsers.

A little room · Show / hide animation

A host with a gold crown switches between a gamepad, paintbrush, camera and remote as friends watch games, drawings, photos and a film.

Features · Get started · Self-hosting · Contributing

Features

  • Watch without installing. Friends join by invitation in a desktop or mobile browser.
  • Share from Piik App or an existing Piik site. Capture a screen, window or browser tab; available sources and audio depend on the platform.
  • Direct connections first. Media travels between participants where possible (P2P). A self-hosted server can provide automatic media forwarding (SFU) as a fallback.
  • Rooms you control. Invitations, room codes and optional room passwords, for one host and up to 20 viewers.
  • Flexible viewing. Light and dark themes, playback controls, picture-in-picture and a connection topology view.
  • One program to host a site. Web UI, room management and optional media forwarding are packaged together.

Piik room: a shared game, playback controls and friends on a sofa. The host wears a small gold crown.
Interface preview · Sample room with a generated game scene

Get started

To watch: open the invitation your friend sends you. Select Play if the picture does not start automatically.

To share: download Piik App to get started. To share without installing, you can also create a room in the online version.

Start here What you need to do
Use Piik online Open it in a desktop browser to create a room and share.
Download Piik App Extract and open the App, choose Public invite, then Open Piik to create a temporary room.
Host your own site Advanced: deploy Piik Server on a Linux x64 server with your own domain, then connect through Piik App or a browser.

Choose a screen, send an invitation, watch together.

  1. Select Start sharing, then choose the picture and audio to share.
  2. Select Copy invite link and send it to your friends. Keep the sharing tab open.

Piik follows your system language: Chinese or English, with English as the fallback. Use 中 / EN / ✦ in the header to switch language or try the visual mode. The App offers a local room, a temporary public link, or a connection to your own site. Keep the App running while sharing through it.

Download a ZIP beginning with piik-app. The filename also identifies the platform:

Filename contains Platform
windows-amd64 Windows x64
darwin-arm64 Apple silicon; native capture requires macOS 13+
linux-amd64 Linux x64

Full setup guide → · Open online →

Browser capture requires HTTPS or localhost. Windows App and desktop browser sharing are the primary tested paths. The macOS and Linux apps have not yet been tested on physical devices; test results and feedback are welcome. P2P-only modes, including the App's temporary public link and the online version, may not connect on restrictive networks.

Self-hosting

Piik Server is a standalone binary with the web interface built in. Download the Linux x64 Server package (piik-<revision>-runtime.tar.gz), extract it, and run:

./piik-server

Open http://localhost:8787 to try it locally. For a public site, configure your domain, HTTPS reverse proxy and STUN address. Room data is stored in SQLite. For containers, use the Docker Compose setup.

Deploy your own site → · Configuration · Run from source

Contributing

Bug reports, translations, documentation improvements and pull requests are welcome. See ways to contribute or help translate Piik. Use the repository layout to find your way around.

License

Piik-owned code is MIT licensed. Dependencies retain their own licenses and notices.

S
Description
Free, open-source screen sharing for friends. P2P-first, with browser viewing, a desktop app and optional self-hosting.
https://piik.tv
Readme MIT
9.7 MiB
0 Stars 1 Watchers 0 Forks
Languages
TypeScript 46.2%
Go 36.5%
C++ 5.9%
JavaScript 5%
CSS 2.5%
Other 3.9%