Skip to content

v0.9.42: organization self-service fixes, Chat admin actions, sandbox timeout output and faster warm calls - #9613

Merged
waleedlatif1 merged 27 commits into
mainfrom
release/v0.9.42
Nov 3, 2026
Merged

waleedlatif1 merged 27 commits into
mainfrom
release/v0.9.42

Conversation

@waleedlatif1

Copy link
Copy Markdown
Collaborator

waleedlatif1 and others added 20 commits November 2, 2026 17:35
… Sim's account (#9593)

* improvement(media): record a hosted-key auth failure when fal refuses Sim's account

Mothership's generate_audio and generate_video call fal on Sim's hosted keys
outside the tool executor, so a refused account (revoked key, or a lock for an
exhausted balance) only reached logs. The submit path now records a
Sim/HostedKey Failed point with reason auth on a 401, 402 or 403, the same
series the hosted-key dashboard already plots for executor tools, so an
alarm on that reason covers fal too.

* improvement(media): label fal auth failures with the refused key and use the shared env-flags mock

getFalApiKey now returns the env var its key came from, so a refused key in the
numbered pool is named on the metric. The metrics module reads isHosted on each
call instead of copying it at import, and the test sets it through the central
env-flags mock under fake timers.
* docs(library): update best-zapier-alternatives

* Pi Babysit: address PR #9592 feedback

---------

Co-authored-by: Sim Pi Agent <pi@sim.ai>
…he files it already wrote (#9596)

* improvement(sandbox): return a timed-out workbench run's output and the files it already wrote

A run_code call killed at its own timeout returned an empty stdout and only
"timed out after Nms", so models reran long jobs from scratch. E2B's SDK throws
a stream-less TimeoutError, which dropped the output the stream callbacks had
already observed.

- E2B adapter: a timed-out command returns the stdout/stderr its callbacks observed
- Workbench runs (session sandboxes) that hit their own timeout throw a timeout
  abort carrying the output tail (64 KB) and the files already in the call's
  output directory; every existing timeout check still accepts it
- The route returns that output in stdout with a 408 and says the workbench and
  its files persist, so the next call can rerun only the remaining work
- Output goes through the same session provenance check and secret-name
  reporting as any other result; one-shot sandboxes and billing are unchanged

* fix(sandbox): keep a cancellation during the timed-out output listing a cancellation
…ms-2026 (#9598)

* docs(library): update best-self-hosted-ai-workflow-automation-platforms-2026

* Pi Babysit: address PR #9598 feedback

---------

Co-authored-by: Sim Pi Agent <pi@sim.ai>
…launch (#9606)

Every warm workbench call ran a separate CLI integrity check command (ownership
write, launch, stop receipt, settle) before the user's command, about a third of
a warm call's fixed cost.

- The session supervisor's PID 1 now runs the same check as the ordinary user,
  after recording itself and before starting the command; a mismatch starts
  nothing and is reported on the stop receipt the call already fetches
- A refused launch is repaired under the session lock and relaunched once; a
  second refusal fails the call
- The check runs with an isolated interpreter instead of the user's login shell,
  never follows links or blocks on non-regular files, and treats an unreadable
  artifact as stale so repair overwrites it
- A reused machine runs no separate check command; a new machine still installs
  the CLI first
- Gated live test against real E2B covers refusal, repair, hooks, FIFOs, Stop
  during a slow check, and the warm-call cost
* fix(organizations): let admins rename their organization

* fix(organizations): keep the rename draft until it is saved or cancelled
* fix(credentials): let members leave a shared credential

* fix(credentials): type the stale keys list

* fix(credentials): match the last-admin guard to the server
… operation and let Chat rename workspaces (#9607)

* improvement(workspaces): move workspace updates behind an application operation and let Chat rename workspaces

PATCH/PUT /api/workspaces/[id] now run through defineInternalJsonRoute and the
session-only workspaces.update use case, keeping the legacy 403/400/500 bodies,
audit changes and response shape. Chat gets a workspace/general settings section
backed by workspaces.identity.read and workspaces.identity.update, which admit
only name and logo; billing payer and the personal-key policy stay session-only.

* fix(workspaces): recheck active state atomically on update

The workspace UPDATE now carries the not-archived predicate, so an archival
that commits after the use case's reads leaves nothing to write and answers
the same 404 as a missing workspace, on both the session route and Chat's
identity update. The integration suite holds the row lock, archives the row
while the update waits, and asserts the 404 and the unchanged name; the
archived-fixture refusal now checks that fixture's own row.
… out other devices (#9595)

* fix(organizations): let members leave their organization; remove sign out other devices

* fix(organizations): hide Leave when the caller's role is unknown

* fix(organizations): offer Leave only from an authoritative role

* fix(organizations): use only a freshly fetched summary role for Leave

* fix(organizations): refetch the summary role on mount
…ess connector (#9602)

* fix(knowledge): let members connect their own account to a member-access connector

* fix(knowledge): keep watching member enrollment until it connects
…tic card above the composer (#9608)

* improvement(billing): open a Chat plan popup on send instead of a static card above the composer

* improvement(billing): name the plan upgrade link input
…9597)

* fix(sim-links): hand off a departing member's links to the successor

* fix(sim-links): repair leftover links on account deletion

* fix(sim-links): lock leftover-link organizations before deletion barriers

* fix(sim-links): hold the creator's membership while creating a link
* improvement(chat): let Chat review organization access requests

Organization admins can list, preview, approve and deny access requests from an
organization conversation through the settings tool's new requests section.
The admin list, preview and resolve operations now admit organization-delegated
Copilot principals under the sim:settings audience; role, audit, outbox notice
and fingerprint checks are unchanged. Request settings stay session-only.

* fix(chat): default access request list to pending

The settings tool parses list input before calling the reader, so an omitted
status reached it as undefined and listed every status. The list schema now
defaults status to pending, matching get; explicit statuses still apply.
…nd keep the renamed name visible (#9609)

* fix(organizations): refuse self-leave for directory-managed members and keep the renamed name visible

* fix(organizations): refuse transfer-and-leave for directory-managed owners

* fix(organizations): transfer ownership for directory-managed owners and explain why they stay
…te them (#9611)

* fix(db): bootstrap Projects for development push databases that predate them

A push-managed database with workspaces but no Project schema could never pass
the schema-push guard: push cannot backfill workspace.project_id, and the
guard refuses every unenforced Project state. Under SIM_DEV_DB_PUSH=1 the
pre-push reconciler now replays migrations 0394 and 0406 (the foundation
commits atomically with the rollout marker) and runs the registered
0032_project_membership script migration on its single session, recording it
as the migration runner does. An interrupted bootstrap resumes; every other
unenforced state still refuses with the same message.

The pinned drizzle-kit patch also adds unique constraints before foreign keys,
so a composite foreign key on a new unique constraint of an existing table no
longer fails, and in the noninteractive push policy it answers the
unique-constraint truncate prompt with its non-destructive choice.

* fix(db): push the schema before the Project migration reads it

The bootstrap ran 0032_project_membership before Drizzle pushed anything, so a
development database from before a column the migration reads (such as the
fork parent) failed after committing the expansion, on every retry.

--prepare now only replays the expansion. push.ts then runs one Drizzle push
with workspace.project_id still nullable (SIM_DB_PUSH_PROJECT_BOOTSTRAP=1),
runs the migration through reconcile-project-membership.ts --bootstrap, and
finishes with the ordinary push. The connector and rollout marker are kept out
of Drizzle's diff until the migration retires them. A fresh bootstrap also
requires that no public table carries a project_id column.

* fix(db): pin the Project bootstrap to the public schema

The replayed migration SQL and the script runner name tables unqualified, so a
connection search path that lists another schema first created the Project
foundation outside public. The refusal snapshot now also covers folders and
Projects.
@vercel

vercel Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
docs Skipped Skipped Nov 3, 2026 6:47am UTC

Request Review

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 118 files

Reply with feedback, questions, or to request a fix.

Turn on auto-fix | Re-trigger cubic

Comment thread apps/sim/lib/settings/sections.ts Resolved
Comment thread packages/db/schema.ts Resolved
@greptile-apps

greptile-apps Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 4/5

[High impact] The PR changes organization-wide access workflows and shared sandbox and database paths.

The PR appears safe to merge, with a non-blocking gap in partial output for short workbench timeouts.

Findings

  1. P2 Short timeouts lose progress ▶

Summary

This PR expands organization self-service and Chat administration, and improves persistent workbench calls.

  • Organization members can leave, and admins can manage membership more clearly.
  • Chat can review organization requests and manage more settings.
  • Members can leave shared credentials from their workspace.
  • People can revoke organization accounts they connected themselves.
  • Members can connect their own account to a shared knowledge connector.
  • Workspace changes use one application operation, including Chat renames.
  • A Chat plan refusal opens an upgrade popup when someone sends a message.
  • Timed-out workbench runs return the output and files they already produced.
  • Warm workbench commands check the CLI as they launch.
  • Development database pushes can add Projects to eligible older databases.
  • Fal.ai account-auth failures are recorded when hosted-key requests fail.
  • Settings hide edits that the server refuses for a person’s role.
  • Three library guides add current comparisons and buyer details.
  • The recovery test checks backoff from saved claims.
  • The unused-export baseline follows the updated exports.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Workbench call] --> B[Acquire or reuse sandbox]
  B --> C[Verify CLI inside launch]
  C -->|Matches| D[Run command]
  C -->|Stale; nothing ran| E[Repair CLI under session lock]
  E --> C
  D -->|Completes| F[Collect outputs]
  D -->|Command times out before outer deadline| G[Collect partial output and file names]
  D -->|Outer deadline expires| H[Plain timeout response]
  F --> I[Check secret history]
  G --> I
  I --> J[Return response]
Loading

Reviews (1) · Last reviewed commit: "fix(db): bootstrap Projects for developm..." · Reviewed by Greptile

#9615)

Chat's settings list advertised the Sim links section to every organization. Its operations already refused when the rollout flag was off, but Chat would still offer it. describeSection now drops it for those organizations, so list omits it and open/get/describe/execute refuse it up front.
…ame the organization's plan on organization routes (#9614)
… settings, scope the Chat plan modal (#9616)

- A workbench run with a short budget kept no time for its own timeout to answer, so the call deadline won and the output it printed was lost; hold back a small report reserve and bound the output listing by the time left
- Chat listed the Sim links settings section to every organization; a settings adapter can now declare whether its section exists, and Sim links does so from its rollout flag
- The Chat plan modal stays with the workspace whose send opened it
- Organization conversations ask to upgrade the organization's plan
…n upgrade copy (#9618)

#9614 gave organization routes their own message, so the organization wording #9616 added to `action` is never read
…ire dev push for the Project bootstrap switch (#9617)

- A workbench run with a budget of 20 s or less hands the command its whole
  budget, so the run's own deadline can fire before the provider's timeout
  reply. The E2B session adapter now treats that timeout-reason abort like the
  provider's own timeout and returns the output it already streamed, and
  throwIfRunTimedOut lets only the run's deadline through, so a Stop stays a
  cancellation. No budget is taken from short runs.
- The nullable workspace.project_id switch now also requires SIM_DEV_DB_PUSH=1,
  like hnswIndexOptions, so a stray bootstrap flag cannot make an ordinary push
  or generation drop NOT NULL.
@waleedlatif1
waleedlatif1 merged commit f3596f0 into main Nov 3, 2026
83 checks passed
@waleedlatif1
waleedlatif1 deleted the release/v0.9.42 branch November 3, 2026 17:34

This branch was previously deployed

1 inactive deployment
Preview — 3919c12e Deployed Nov 3, 2026 by vercel[bot]
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