Skip to content

Merge pull request #516 from saffron-health/release-v0.6.39

Latest

Choose a tag to compare

@github-actions github-actions released this 30 Jul 00:51
0470fd7

Features

  • Persistent browser auth profiles: browser_open now accepts an authProfile parameter to reuse signed-in browser state across sessions. Omitting the field uses the named default profile on supported providers; pass authProfile: false for a fresh incognito session.

    // Reuse a named profile
    await toolkit.tools.browser_open.execute({ authProfile: "work" });
    
    // Incognito session
    await toolkit.tools.browser_open.execute({ authProfile: false });

    Named profiles are supported on the Local, Libretto Cloud, Kernel, and Browser Use providers. Browserbase and Steel are unsupported until a durable name-to-ID mapping is available. Local profiles are stored under ~/.libretto/browser-tools/profiles with owner-only permissions. Changes persist only after browser_close or a graceful dispose().

  • Account deletion controls: Workspace owners can now delete their Libretto Cloud account (and workspace, when they are the sole member) from the Users tab of the dashboard. A confirmation dialog is shown before any destructive action.

Improvements

  • Modal-scoped accessibility snapshots: When a modal dialog is open (<dialog>, role="dialog" aria-modal="true", or role="alertdialog" aria-modal="true"), the accessibility snapshot now roots at the modal instead of the full page. This prevents inert background content from cluttering the tree and ensures agents see only the focus-trapped UI.

    Before — page behind the modal stayed in the tree:

    <document>
      <main>
        # Checkout
        <button>Pay now</button>
      </main>
      Delete this item?
      <button>Cancel</button>
    </document>
    

    After — modal is the root:

    <dialog>
      Confirm delete
      Delete this item?
      <button>Cancel</button>
      <button>Delete</button>
    </dialog>
    
  • Opt-in snapshot diffs on exec: Accessibility-tree diffs after browser_exec / libretto exec are now opt-in. Pass diffSnapshot: true (tool) or --diff-snapshot (CLI) when you want a before/after page-change diff after an exploratory mutation. Skipping the flag avoids the cost of two snapshot captures on every exec.

    // Only capture a diff when you need it
    await toolkit.tools.browser_exec.execute({
      sessionId,
      code: "await page.locator('button').click()",
      diffSnapshot: true,
    });
    npx libretto exec --diff-snapshot "await page.locator('button').click()"
  • snapshot <ref> always captures a fresh tree: Scoped snapshots no longer depend on a cached tree from a prior full snapshot. Each snapshot <ref> call now captures a fresh screenshot and accessibility tree, then scopes the output to that ref.

  • Portable daemon IPC endpoints: The daemon now uses os.tmpdir() for socket paths on Linux (instead of a hardcoded /tmp), keeps macOS on the short /tmp path to stay within its 104-byte Unix socket limit, and correctly prefers UID-based endpoint isolation over username on Unix systems. Windows named pipe behavior is unchanged.

  • Cleanup errors as values: dispose(), closeSession(), and browser_close no longer throw on provider or browser cleanup failures. Errors are returned as typed values (BrowserCleanupError | null), so partial failures are surfaced to callers without masking the original error or leaving sessions in an unknown state.