Skip to content

Render canvas frames through an app only watching the host - #32

Merged
enowdev merged 3 commits into
mainfrom
fix/canvas-render-watched-host
Nov 4, 2026
Merged

enowdev merged 3 commits into
mainfrom
fix/canvas-render-watched-host

Conversation

@enowdev

@enowdev enowdev commented Nov 4, 2026

Copy link
Copy Markdown
Owner

enowx-app canvas screenshot from a session on a server failed with "open the app connected to this host", while the app was open and watching that host.

Cause

The daemon renders through an app in browsers.serving (daemon/canvas.go:246). Only the app's main connection registers there (ui/connection.go:140). Connections to other hosts register only ServeApp (ui/watch.go:141) and ignore canvas.render in watchEvent (ui/watch.go:216). So with the app showing the Mac and watching enowxlabs, enowxlabs has an app connected and none to render.

This is by design of the registration, not a lost one: a reconnect or restart registers again. It renders on the Mac because its app does show that host.

On enowxlabs, enowxd.log shows connection 83cdb953ecae (kind=app) open since 17:02:27 with no close, which fits. The log doesn't say which of the app's connections that is.

Fix

  • New canvas.serve: a watched host's connection registers for renders alone, so a Browser's actions still go only to an app showing the host.
  • The app showing the host goes first, then the latest app watching it.
  • watchEvent handles canvas.render and replies through that host's connection (renderCanvas used to always reply through the main one).
  • With no app connected, the error says exactly that.

Mixed versions: an older daemon answers an unknown method and nothing changes; an older app never registers, as before.

Not changed: exporting a video still needs the app showing the host (daemon/canvas_video.go:55), the same limit. Said in docs/canvas.md.

Tests

New: TestCanvasRendersThroughAnAppWatching, TestWatchedHostsRenderRequestGoesBackToIt. They run on CI; locally only go build, go vet, and recording the API, as asked.

Not run: a real render from a real app, or from the failing session.

Touches no go.mod, version/ or cloud/, so merging doesn't deploy the cloud.

🤖 Generated with Claude Code

enowdev and others added 3 commits November 4, 2026 21:22
An app registered to render only on its main connection, so a session on a host
the app watched, showing another, was told to open the app while it was open. An
app now registers on those connections too, for renders alone: a Browser's actions
need the app showing the host.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@enowdev
enowdev merged commit d2cdcab into main Nov 4, 2026
6 of 8 checks passed
@enowdev

enowdev commented Nov 5, 2026

Copy link
Copy Markdown
Owner Author

Its commits are in main through the 0.7.0 release merge (#40, e306b3b).

@enowdev
enowdev deleted the fix/canvas-render-watched-host branch November 5, 2026 04:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant