Files
piik/docs/todo.md
T
AAA e3ada873fd feat(app): improve sharing controls, recovery and troubleshooting
Sharing failures were often reduced to a generic message, and changing Windows audio exclusion required reopening source selection. This phase keeps actionable failure context at the TV status indicator, adds live source-audio controls, and integrates independent capture, codec and ICE-lifetime repairs against the published contract.

The audio controls reuse source replacement and the existing mixer; audio-only changes preserve video capture, encoded sources and connections. Source enumeration is bounded by the serialized control response. Codec preflight and H.264 decoder input enforce the existing native format. Gateway mappings are revalidated only for actual ICE gatherings. Website scripts and styles now share content-addressed build output.

Browser/server v23, Native control v9, capture v7 and the 1440p ceiling stay unchanged. The held 4K/capability candidate and Magicsock transport are excluded. Documentation changes belong to the existing guides, standards and evidence owners.

## Validation

- `npm run check`: type checking, 81 test files / 1,370 tests and the production Web build passed.
- `npm run check:go`: Go tests, formatting, vet, cross-builds and Windows native capture regressions passed. A first run hit Windows temporary-directory cleanup after an unchanged SQLite test; five focused repetitions and the full rerun passed.
- Native Host gates passed separately with H.264 and VP8: live/paused quality changes, minimized-window recovery, source replacement, Viewer decoding and complete process/port cleanup. The App Local entry/authentication/invitation gate passed.
- Website/documentation build, documentation links and repository hygiene passed. Browser review covered Chinese/English, dark/light controls, 320px/360px and desktop layouts, audio selection/off state, troubleshooting dialog/ESC focus return, matching GitHub/Gitee architecture links and the embedded film.
- macOS/Linux physical capture, Windows 10 exclusion and representative network/device coverage remain explicit evidence limits. CI must pass Linux race checks and native packaging before publication.

## Release notes

### 中文

这是一次分享体验与兼容性更新。Windows App 支持在开播后调整排除的应用声音;遇到分享失败时,也有更清楚的提示和排查入口。

#### 使用改进

- 在「分享设置 → 声音」中调整系统声音和排除的应用,无需停止分享。支持的 Windows 10 系统也会按实际能力显示排除选项。
- 分享失败提示保留具体原因。点击电视下方状态,可查看处理建议、诊断入口及对应的故障排查文档。
- 补全中英文常见问题说明,涵盖 App 连接、选源与编码、站点地址配置、严格网络和浏览器 HDR 限制。

#### 修复

- 修复窗口较多或名称较长时选源列表可能加载失败,以及部分独立窗口未列出的情况。
- 改善 Windows 窗口最小化、恢复后的采集衔接。
- 修复部分 Firefox 编码属性影响连接的问题,并使原生接收的格式预判与实际支持范围一致。
- 重连时刷新网关端口映射,避免沿用已失效的映射结果;加强原生 H.264 输入校验。
- 官网下载架构切换增加统一动效,脚本与样式使用带内容标识的地址,减少更新后的缓存混用。

更新 App 并刷新页面即可使用相应改进,无需迁移配置或房间数据。Windows 10 音频排除是否可用取决于系统能力。

### English

This update improves sharing controls and compatibility. Windows App users can change audio exclusion during a share, and sharing failures now provide clearer guidance and a direct troubleshooting entry.

#### Improvements

- Change system sound and the excluded application under **Sharing settings → Sound** without stopping the share. Supported Windows 10 installations can also expose exclusion after the capability check.
- Sharing failures retain their specific cause. Select the status below the TV for recovery suggestions, diagnostics and the relevant troubleshooting guide.
- Updated English and Chinese guides cover App connectivity, source selection and encoding, site-address configuration, restricted networks and Browser HDR limitations.

#### Fixes

- Fixed source lists failing with many windows or long titles, and certain independent application windows being omitted.
- Improved Windows capture transitions when a window is minimized and restored.
- Fixed stale Firefox codec attributes disrupting connections and aligned native receiver preflight with its supported formats.
- Refresh gateway port mappings for new ICE gatherings instead of reusing stale results, and validate H.264 input before native decoding.
- Added consistent motion to website architecture selection and content-hashed script/style URLs to prevent mixed cached versions.

Update the App and reload the page to use the relevant improvements. No configuration or room-data migration is required. Windows 10 audio exclusion depends on actual system capability.
2026-10-06 02:24:15 +08:00

14 KiB

Current TODO Ledger

Last reviewed: 2026-10-06

Only Now is executable. Product modules own behavior; Git/PRs own completed history. A parked idea is not implementation authority.

Now

  • Assess Native Magicsock transport. Compare the isolated Go transport with the repaired Pion baseline under the NAT evidence boundary. Establish a measured benefit, supported paths, resource/authority bounds and compatibility cost before accepting product integration. Experiments do not establish a connectivity gain or authorize publication.

Held By Owner

  • 4K and resolution/capability expansion. Not planned for this phase, reaffirmed by the owner on 2026-10-06 because of cost relative to benefit. Keep the public v23/v9/v7 contract and 1440p ceiling. Resume the extensibility audit and media extension assessment only with a renewed benefit/cost decision. This includes unfinished cross-platform capture and capability negotiation; local tests alone do not authorize a protocol break or a 2.0 release. Retain recoverable Git evidence for the experiment without requiring an active worktree.
  • Browser-internal encoder work. Paused by the owner on 2026-10-01. Comparisons and Chromium traces own the evidence for synchronous H264 initialization, native adaptation and the unbuilt upstream repair candidate. Keep the verified Piik budget and handoff repairs; do not add periodic resets, a quality floor or a Browser fork. The field room's cause and all brief blur are not established as resolved.
  • 32-bit Windows/Linux Apps. Deferred by the owner on 2026-10-02; no package or website option is planned. Browser use remains available where the OS/browser supports the required media APIs. Retain the isolated Git evidence for the Windows x86 capture experiment; revisit its native dependencies, atomic alignment and real 32-bit device coverage only if this work is reopened.
  • Windows ARM64 App. Deferred by the owner on 2026-10-03. Keep Windows App packages and website downloads x64-only until this work is reopened.

Deferred Feature Work

These proposals remain deferred beyond the accepted interaction phase.

  • Managed Demo hosting. Evaluate cost and public UDP support before any migration. The assessment remains outside the current product release; keep the existing P2P-only Demo deployment until a provider and operating boundary are accepted.
  • Phone as a Host microphone: assess after the current work. Explore an opt-in link that pairs a phone's microphone with the Host's existing audio mixer. Evaluate pairing/revocation, latency/echo, browser background limits and Browser/native input ownership before accepting an implementation. This proposal does not reopen room voice or change the current release scope.
  • Passive App attachment: design hold. Site mode authorizes one selected origin and supplies native media without starting a local room server. A passive replacement needs an accepted site-consent/discovery flow; it must not admit arbitrary sites or add another runtime owner. Keep Site mode until that decision; removal of the Demo prefill does not authorize changing site trust.

Awaiting Device Or Reporter Evidence

These reports remain unmatched. A local repair or successful test is not proof of a reporter's cause; research owns the completed experiments and their limits.

  • macOS and Linux physical capture. Complete the remaining capture/audio checks in verification status, including an Intel Mac with a usable hardware H.264 encoder, an ARM64 Linux desktop, and Linux systems beyond the PR author's Hyprland/NVIDIA result.
  • Signaling recovery on passwordless sites (#446). Verify the admission correction against a matched Host/Server attempt; identify the event preceding the handshake failure rather than inferring password denial from AUTH_REQUIRED.
  • HDR, audio-exclusion and mobile interaction device coverage. Complete the physical matrix: HDR/mixed displays, voice-app process trees across playback devices and phone keyboard/theater/participant-menu interaction. Browser HDR overexposure is an accepted limitation with documented alternatives; reopen conversion work only with new evidence and an accepted implementation.
  • Native H.264 motion quality (#432). Obtain matched source/decoded pictures and bitstream for the original 720p30 game comparison. Retain current codec parameters. The evidence review owns the withdrawn CBR claim, Baseline admission repair and Main/High comparison; none establishes this report's cause.
  • Self-hosted room creation HTTP 403. Retest affected deployments using the address checks. Obtain the configured public address/origin and response details; distinguish Piik's rejection from a proxy/WAF 403 before assigning their cause.
  • No available media route. Compare the same endpoints/networks before assigning a regression since v1.4. Obtain paired Host/Viewer/App reports and distinguish route allocation, ICE, first-frame admission and route rejection. #443 lacks a connected Native edge and its paired Viewer/App transport report; #448 only reaches route allocation. The v1.6.3 candidate-timeout report lacks share-start and SDP/ICE evidence.
  • Camera and Host microphone device coverage. Check real audio levels, echo, device replacement/native mixing and phone camera permission, orientation and background behavior. Include OBS virtual-camera/audio-input sound quality and A/V synchronization. The capture assessment owns current behavior and the accepted physical limits.
  • Public-invitation startup and HTTP 1033. Obtain version and matched diagnostics for creation failures, Demo access and a stream stalling before reload returns 1033. Distinguish connector recovery/exit, DNS/provider failure and an obsolete link from media routing. Compare #396 with the runtime evidence. #434 establishes DNS refusal during edge discovery, not a cause shared by all startup reports.
  • Viewer interruptions. Obtain paired endpoint/upstream-relay diagnostics for established viewing returning to P2P connecting, including #429's SFU-to-P2P dropout. Separately retest the v1.5.0 App public-link report where one Viewer drops immediately after connection details appear while others work. Distinguish first-frame admission, signaling grace and current-edge recovery.
  • Windows 11 capture border remains visible. Identify the App/Browser capture path, Windows build, permission result and other active captures. Capture evidence owns the graceful-retirement and concurrent-capture checks.
  • App discovery and share-start failures. Retest missing sources and unreachable App reports across authorization, browser permissions, control capacity, enumeration and startup. For the v1.6.5 Auto-to-VP8 report, obtain the Browser exception/assets and actual VP8 output: Browser stop-share precedes any local-edge request and does not prove a no-frame timeout. #419's AMD manual-H264 failure and #437's Auto-only failure need the same attempt's App diagnostics. For input-texture-create / 0x887a0005, obtain the next candidate/fallback result and final state; a rejected candidate alone is not the share outcome. Native media research owns the hardware checks and limits.
  • Share ends after entering a game. Obtain version, capture path, codec and paired diagnostics. Locate the first capture/output, preview-bridge, control or authority failure; distinguish source silence from target replacement, display-mode change and device loss. Capture research owns the quiet-source behavior; an encoder output deadline remains a candidate mechanism, not a diagnosis of this report.
  • Windows launcher exit after opening the page. A user reports that the mode-selection page opens, then the App console reports Piik App could not open its launcher: exit status 0xc0000005. Retest the browser handoff and obtain the affected build and URL-handler process/dump evidence if it still fails.
  • System becomes very laggy after starting a share. Obtain mode, actual codec, profile, display refresh rate and CPU/GPU use, distinguishing startup from sustained lag. Compare saturated GPU/game-FPS impact and multi-output recovery with the helper-cost checks before changing allocation or cadence. For Native/SFU stalls, correlate the relevant Go runtime using the GC attribution boundary; no field report currently establishes GC as its cause.

Next: P2P Connection And Feedback Evidence

For the transport assessment, measure connection success, time to first picture and failure causes on representative networks, especially App and P2P-only sites. Use existing Debug provenance and selected-path events under the NAT evidence boundaries. Separate candidates, attempts, successful paths and timeouts; scope observations to connection generations without raw endpoints. Verify survey responses and P2P/SFU handoffs, including background direct attempts behind working SFU media. The iroh/Tailscale comparison records the isolated Go media/migration experiment and Browser/relay limits. Before adopting magicsock in the product, establish a benefit on matched network pairs and define room-authorized peer keys, endpoint exchange, MTU/resource limits and mixed Browser/Native behavior. Keep the experiment isolated from the production routing contract; Go reuse already works, so a Rust alternative needs a concrete Go limitation.

Parked Product Work

  1. Representative device/network acceptance. Resume the remaining matrix in verification status when directed, preserving platform deferrals and serial physical checks. Before reusing the optional viewer-mbb canary, replace its obsolete Viewer-only trigger and capacity assertions with the sender-owned contract.
  2. Broader quality work. Reopen from measured interruptions, failed recovery or healthy-sibling degradation at acceptable complexity. The Browser pool comparison owns cold-encoder tradeoffs; low resolution alone is not a defect. Check whether a proposed move merely shifts pressure to another parent's siblings.
  3. Signaling execution model. Measure signaling-lock contention, synchronous persistence, presence fan-out, diagnostic I/O and cross-room password-work fairness before changing the lock or execution model.
  4. Reachable ownership/refactor work. With related behavior changes, evaluate per-share Host and Viewer route ownership under engineering review. Reopen C=3 structural-intent retention or multi-child evidence ownership only with current-contract reproductions. Shared recovery must preserve Native bridge versus network-failure semantics. Before changing Host loopback-failure retirement, account for its preview, Browser quality candidates, quality/SFU updates and track-ended consumers; independent Native publication alone does not make ignoring the failure safe. This is not a diagnosed field cause.
  5. Storage fault recovery. Choose and verify a damaged-disk/COMMIT/ROLLBACK recovery policy before adding catch-and-continue or retries. This failure boundary remains unestablished after ordinary persistence checks.
  6. Platform output. Reopen for a registered receiver acting as an ordinary Viewer only after the platform-output gate passes.
  7. Additional languages. Review community catalogs and their rendered UI following the translation guide, including names, menu navigation, text direction and layout.
  8. Windows code signing. Revisit after enrollment in a trusted signing service. Sign executables before archive checksums; publisher identity does not guarantee that antivirus cloud scanning stops.
  9. Gitee download-source warning. Paused by the owner. Keep GitHub primary and retain Gitee; do not add a self-hosted mirror. Chrome still blocks the Gitee attachment when Referer is removed. Reopen for new evidence or a provider review; the warning remains unresolved.
  10. Release-operation policy. Protected release environments, immutable draft assets and changing mirror-failure policy remain unaccepted proposals; evaluate their benefit before adding release machinery.
  11. Automatic local chat history. Explicit TXT export covers manual retention. Reconsider automatic storage only with a stable room-incarnation identity, bounded retention and a clear delete control; reusable room codes must not combine conversations. No new history service or wire field is authorized.
  12. Direct OBS input (#436). Reopen for a measured virtual-camera limitation. The capture assessment records raw-frame output and the WHIP boundary; virtual camera alone is not a second encode. Do not add an RTMP/WHIP listener without an accepted publication owner.