Repository navigation
feat(session-manager): add the Session Manager service - #5332
Merged
Merged
Conversation
5 tasks done
…n manager The session manager's add-secret form is built on existing components, so the library gets what that form needed. Every default path stays as it was for the other consumers (platform, web, docs, ui-docs). - Input and Textarea: a secret mode with show/hide and copy buttons (FieldValueActions), spell check, auto-correct and auto-capitalize off for sensitive values, the caller's ref left alone (React 19 ref cleanup keeps working), the reveal state re-masks when masking turns off, and the buttons are inert inside Skeletonize. - CopyableField: masked and wrap values with the same actions. - Dialog: a sticky footer and an initial-focus ref, passed on by FormDialog. - startReactServer: WebSocket endpoints and an idle timeout, an `analytics` switch (UMAMI_* is followed by default), and a 400 that carries the security headers for a malformed Host header instead of a bare 500. - Catalogs (en/de/fr), ui-docs pages and demos, stories and tests for each; the Storybook preview gets the TooltipProvider its stories need.
Rebuilds the Session Manager as services/session-manager, a TypeScript service in the monorepo. It runs isolated Camoufox browser sessions on your own computer: each session has its own profile, stable fingerprint and proxy. It has a proxy pool with checks and import, a secrets vault that can be typed into pages, a live view of the browsers in the page, and an MCP endpoint (42 tools) for AI assistants. It was a Python/FastAPI app; its data is not migrated. - Backend: one Bun process serving the page, the HTTP API (Hono + zod), the live view (WebSocket) and /mcp; bun:sqlite store; camoufox-js and playwright-core for the browsers. Host, Origin and Sec-Fetch-Site checks, request and length limits, loopback traffic through the session's proxy, page text framed as untrusted for assistants, credentials kept out of logs and reports. - Frontend: React 19, TanStack Router, react-query and react-hook-form on @tale/ui, laid out like the platform, in English, German and French, WCAG 2.1 AA. - Tests: server and UI projects, a real-browser lane (opt-in), guards, and a Playwright suite that runs one isolated fake server per worker. - README with the security model, the HTTP API and the MCP tools; a manual test layer.
The Session Manager is released like web: part of the release train, its own image (tale-session-manager), standalone compose stack, container test, CI scope, build job and Playwright job. It is not a site (it stays out of the sites_only lane) and its compose file publishes on loopback only, because it has no login. - Workflows: release.yml (full cohort), build.yml (session-manager-test), e2e.yml (static-sites matrix, 25-minute job timeout), ci-scope, and the release-candidate contract. - compose.session-manager.yml and its test override, the container test and its helper, the guard tests that enumerate services, workflows and images. - Docs and housekeeping: compose-files pages (en/de/fr), CI, RELEASING and CONTRIBUTING notes, .agents/repo.md, issue templates and labeler, knip, commitlint scope, performance inventory, lockfile.
…t on Windows and Linux The browser tests on the CI runner (Linux, where a scrollbar takes room from the page) found what a Mac hides: - Secrets table: the full table needed 932 px, and a window of 1024 px leaves 940 px on a Mac but 925 px beside a scrollbar that is not an overlay, so Windows and Linux showed the compact row there. The details column needs 80 px least now (912 px in all). - The summaries of collapsible details (the tool groups, the import report, the install issue) relied on the browser's own focus ring, whose colour differs per platform. They carry a ring of the app's tokens, like every other control. - Tests: a tap waits the 700 ms the page lets go of mouse events after a drag (a tap sooner is one of them, and the CI runner is quicker than a Mac), and a dialog is measured once it has stopped sliding in.
yannickmonney
force-pushed
the
feat/session-manager-service
branch
from
November 3, 2026 10:03
52a3b1c to
7ae31b5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Rebuilds the Session Manager as
services/session-manager, a TypeScript service in the Tale monorepo. It runs isolated Camoufox browser sessions on your own computer: each session has its own profile, stable fingerprint and proxy. It has a proxy pool with checks and import, a secrets vault that can be typed into pages, a live view of the browsers in the page, and an MCP endpoint (42 tools) for AI assistants. It was a Python/FastAPI app in a separate repository (kept as the behaviour reference); its data is not migrated (decided: no longer needed, no importer).It is released like
web: part of Tale's release train (the samev*.*.*cohort), published as its own image (ghcr.io/tale-project/tale/tale-session-manager), run from its own standalone compose stack, with its own container test and CI scope, build and Playwright jobs. Two deliberate differences fromweb: it is not a "site" (it stays out of thesites_onlyre-release lane), and its compose file publishes on loopback only, because it has no login and drives browsers with your proxies and secrets.Four commits, in the order to read them:
feat(ui): what the shared library needed (backwards compatible; every default path is unchanged for platform, web, docs and ui-docs).feat(session-manager): the service.ci(session-manager): release, CI, compose, guards and docs.fix(session-manager): what the first CI run showed on Linux and Windows (the secrets table beside a classic scrollbar, a focus ring of the app's own for<summary>, two timing fixes in specs).What is in it
/mcp; SQLite store (bun:sqlite);camoufox-js+playwright-corefor the browsers. The frontend is React 19, TanStack Router, react-query and react-hook-form on@tale/uicomponents, laid out like the platform (rail, sessions panel, settings kit, tables, dialogs, empty and error states), in English, German and French (du/tu), WCAG 2.1 AA. The README has the security model, the HTTP API, the MCP tools and the Docker run; a manual test layer sits next to the tests.packages/ui):Input/Textareasecret mode with show/hide and copy (FieldValueActions),CopyableFieldmasked/wrap values,Dialogsticky footer + initial focus (passed on byFormDialog),startReactServerWebSocket endpoints +idleTimeout+ ananalyticsswitch, and a400that carries the security headers for a malformedHostinstead of a bare500; catalogs (en/de/fr), ui-docs pages and demos, stories and tests for each.release.yml(full cohort),build.yml(session-manager-test),e2e.yml(static-sitesmatrix),ci-scope, the release-candidate contract, the guard tests that enumerate services, workflows and images,compose.session-manager.yml+ its test override, the container test,docs/{en,de,fr}/develop/compose-files.md,.agents/repo.md,CI.md,RELEASING.md, issue templates + labeler, knip, the commitlint scope.Things to know before merging
.github/release-candidate-contract.json) changes by 14 lines (new build job ids and names, the e2e names, thepr-scopeoutput, thescopeenv, thestatic-sitestimeout 20 → 25 minutes, the e2e success list). No digest is stored in the repo, so the Ops-side digest needs its usual review. The 25-minute timeout holds: the session-manager Playwright job took 13 to 15 minutes in CI on its two runs (the jsdom UI suite of the service, about 1.5 minutes, also joins UI shard 1).Sandbox on Incuswas red on the first runs, for a reason outside this change.services/sandbox/e2e/incus/lab.shonmainpinned Incus7.5.1builds that Zabbly's stable channel no longer carried, so the lab stopped at its install step. It runs on this pull request because the PR edits the CI scope files, which gives it the full scope. fix(sandbox): pin a current Zabbly build of Incus in the lab #5336 pinned the current 7.6 builds and is merged; this branch is rebased on it.camoufox-jspins), not the old app's 156.camoufox-js,playwright-core,fingerprint-generator,socks(browser, identity and SOCKS5 client; nothing equivalent in the monorepo),undici(HTTP through a proxy dispatcher for the exit-IP checks),fast-xml-parser(the CLDR territory data of the geo lookup);hono,zod,react-query,react-hook-formare the stack the other services use.bun audit --prod --audit-level=highis clean; Opengrep: 0 findings.fingerprint-generatorhavenavigator.oscpu: null; Camoufox then leaves the computer's real value in place, so a page could read the host OS under another OS's user agent. A fingerprint without it is now drawn again.Follow-ups (not in this PR)
Library: lift the settings kit,
ShellAlert,AppRail,useDocumentTitleanduseConnectionTroubleinto@tale/ui(copied from the platform for now); an AT-safe masked mode forInput/Textarea(CSS-masked fields are read aloud); the toaster has no close control and sits over page headers' primary actions for 5 s;use-restore-focuswhile a popover fades out; Radix menus and the viewer's tab strip raisescrollable-region-focusableat 844×390;<html lang>for unsupported browser locales; the toast region label in de/fr; Germancommon.actions.clearAll;PropertyRow80 px label column;ErrorDisplayCompactsays "Try again" three times; stickyDataTablefooter sliver;IconButtonfocus-ring contrast;Tabs/CodeBlockcoarse-pointer sizes;CodeBlockcopy feedback;CollapsibleDetailssummary class;LanguageSwitcheralignment. Service: compose hardening flags (cap_drop,no-new-privileges) once verified with a real session; the image on arm64 is not verified; two managers on one data directory are not refused (documented).Checklist
bun run checkpasses (format, lint, typecheck, all tests). Run locally for everything this change touches: oxfmt on the whole repo,oxlint --type-awareandtscfor the service, the service's server (2,916 tests) and UI (2,570 tests) projects,packages/ui(4,447 unit tests) and the platform suites that render the changed components; the rest of the monorepo's suites are left to CI. The guard tests undertools/clipass except two inplatform-docs.test.tsthat need generated sources this checkout does not build (they fail the same way onmain).bun run lint:sastpasses (Opengrep, 0 findings).messages/{en,de,fr}/*.yml(reviewed in all three languages) and thepackages/uicatalogs (697 keys each, same keys in en, de and fr).docs/{en,de,fr}/are updated and ui-docs has pages and demos for the shared components. N/A for other user docs: the Session Manager is a standalone developer tool documented by its own README and manual test layer; like the other standalone services it has no pages underdocs/.README.md/README.de.md/README.fr.md: N/A: they describe the platform. The service has its own README.Test plan
bun run --filter @tale/session-manager test:camoufox, needs an installed build; see the README).packages/ui398 files, 4,447 unit tests; browser tests for the changed components; the platform, web, docs and ui-docs suites that use them.bun install, thenbun run --filter @tale/session-manager dev(http://localhost:3004), or build and start it (build, thenstart); the Docker way isdocker compose -f compose.session-manager.yml up --build. Screenshots of every screen and state (light/dark, phone, German, French) were reviewed.