Skip to content

feat(website): the browser client, env website new and env website dev (FD-4683) - #446

Open
williamloo-scale wants to merge 6 commits into
wloo/website-specfrom
wloo/website-authoring-cli
Open

williamloo-scale wants to merge 6 commits into
wloo/website-specfrom
wloo/website-authoring-cli

Conversation

@williamloo-scale

@williamloo-scale williamloo-scale commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

Stacked on #445.

Authoring tools for SDK sites.

  • site-client.js (with .d.ts), shipped in the protocol package: api(), universeNow() from X-Universe-Now, followUniverseClock(), which re-reads it from the health path so an idle page follows a stopped or faster clock, session(), signIn(), signOut(), errors as ApiError. Notes uses a copy, which a test keeps identical.
  • agent-env env website new NAME scaffolds a site like Notes: site.py, seed, a Vite web/ with the client, Dockerfile, env.toml, README. --from-mcp reads an MCP server's tools from its source (AST, without running it) and --from-tools-json from a tools/list answer; each tool becomes a stub route answering 501.
  • agent-env env website dev runs a site locally without Docker: vite build --watch, uvicorn reload, and a local clock with the gateway's /clock routes. Each reload is synced to the clock and seeded, and conformance runs once.

A scaffolded image installs the protocol from PyPI, so it needs a protocol release with these changes.

Test

Unit suite: 12,814 passed (one GitHub-clone test from main, which hangs on the local machine on main too, deselected). Generated sites pass the conformance check in the tests.

🤖 Generated with Claude Code

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; no blocking findings remain.

Summary

Adds browser helpers and commands for creating and running website environments locally.

  • Authors can scaffold a starter website from a name or tool list.
  • Authors can run a website locally with reload, a clock, and seeded data.
  • Website pages can share browser helpers for API calls, sessions, and time.
  • Website deploys use site-card readiness by default and keep health paths as a fallback.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart LR
  New["env website new"] --> Files["Site, seed, frontend, Dockerfile"]
  Files --> Dev["env website dev"]
  Dev --> Build["Build and watch frontend"]
  Dev --> Server["Run server with reload"]
  Dev --> Clock["Run local clock"]
  Server --> Boot["New server boot"]
  Boot --> Prime["Sync clock and load seed"]
  Prime --> Check["Check conformance once"]
  Check --> Restore["Restore local clock and seed"]
Loading

Reviews (17) · Last reviewed commit: "fix(website): the browser client reports..." · Reviewed by Greptile

@williamloo-scale williamloo-scale changed the title website: browser client, env website new and env website dev (FD-4683) feat(website): the browser client, env website new and env website dev (FD-4683) Nov 3, 2026
@williamloo-scale
williamloo-scale marked this pull request as ready for review November 3, 2026 00:24
@williamloo-scale
williamloo-scale requested a review from a team as a code owner November 3, 2026 00:24
Comment thread src/agent_env/cli/env/website_dev.py Resolved
Comment thread src/agent_env/cli/env/website_dev.py Resolved
Comment thread src/agent_env/cli/env/website_dev.py Resolved
Comment thread src/agent_env/cli/env/website_dev.py Resolved
Comment thread src/agent_env/cli/env/website_dev.py Resolved
Comment thread src/agent_env/cli/env/website_dev.py Resolved
Comment thread src/agent_env/cli/env/website_dev.py Resolved
@williamloo-scale
williamloo-scale force-pushed the wloo/website-authoring-cli branch 2 times, most recently from 8cc706b to 7e5b297 Compare November 3, 2026 22:52
Comment thread src/agent_env/cli/env/website.py Resolved
@williamloo-scale
williamloo-scale force-pushed the wloo/website-authoring-cli branch from 7e5b297 to 9a073e2 Compare November 3, 2026 23:47
williamloo-scale added a commit that referenced this pull request Nov 3, 2026
This PR's change, rebased as one commit onto #446.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@williamloo-scale
williamloo-scale force-pushed the wloo/website-authoring-cli branch from 9a073e2 to 543d2b2 Compare November 4, 2026 00:32
@williamloo-scale
williamloo-scale force-pushed the wloo/website-authoring-cli branch from 8ce884c to 687d166 Compare November 4, 2026 04:40
williamloo-scale and others added 5 commits November 3, 2026 20:54
…v (FD-4683)

This PR's change, rebased as one commit onto #445.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…mes its timeouts (FD-4683)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…dress, as Notes does (FD-4683)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
… routes it stubs (FD-4683)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…n its own origin, as Notes does (FD-4683)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…s as a network ApiError (FD-4683)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

This branch has not been deployed

No deployments
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