From 14976fa2d523566cfd5d0b04337a93525e2c1ef7 Mon Sep 17 00:00:00 2001 From: Waleed Latif Date: Sat, 21 Nov 2026 01:50:22 -0800 Subject: [PATCH 1/2] chore(cleanup): simplify what the Redis, config and removal changes left behind --- .claude/rules/sim-testing.md | 2 +- .cursor/rules/sim-testing.mdc | 2 +- .github/CONTRIBUTING.md | 3 +- apps/desktop/src/renderer/offline/index.tsx | 2 - .../docs/platform/enterprise/self-hosted.mdx | 2 - .../platform/self-hosting/authentication.mdx | 2 +- .../docs/platform/self-hosting/docker.mdx | 4 +- .../self-hosting/environment-variables.mdx | 3 +- .../docs/platform/self-hosting/platforms.mdx | 2 +- .../self-hosting/reference-architectures.mdx | 2 +- .../docs/platform/self-hosting/security.mdx | 10 ++- .../docs/platform/self-hosting/upgrades.mdx | 18 ++++- .../docs/platform/self-hosting/verify.mdx | 2 +- apps/docs/openapi-v2-workflows.json | 2 +- .../scripts/fixtures/content-baseline.json | 66 +++++++++++-------- apps/realtime/src/rooms/types.ts | 2 +- apps/realtime/vitest.integration.setup.ts | 1 - apps/sim/.env.example | 15 +++-- .../(auth)/components/auth-legal-footer.tsx | 2 +- apps/sim/app/(auth)/components/auth-shell.tsx | 3 +- .../app/(auth)/components/support-footer.tsx | 4 +- .../app/(auth)/oauth/sign-in/route.test.ts | 2 +- .../interfaces-support-footer.tsx | 4 +- .../[identifier]/otp/route.integration.ts | 1 - .../stream/desktop-executor.integration.ts | 9 +-- .../app/api/providers/litellm/models/route.ts | 61 +++++------------ .../app/api/providers/vllm/models/route.ts | 54 +++------------ apps/sim/app/cli/auth/page.test.tsx | 7 +- .../aws/aws-marketplace-onboarding.tsx | 5 +- .../workspace/[workspaceId]/layout.test.tsx | 2 +- .../app/workspace/[workspaceId]/layout.tsx | 2 +- .../components/tag-dropdown/tag-dropdown.tsx | 39 ++--------- .../w/components/sidebar/sidebar.tsx | 9 ++- apps/sim/components/emails/_styles/base.ts | 6 +- .../billing/enterprise-subscription-email.tsx | 6 +- .../emails/billing/payment-failed-email.tsx | 6 +- .../emails/components/email-footer.tsx | 34 ++-------- .../emails/components/email-layout.tsx | 16 ++--- .../hooks/queries/desktop-activity.test.tsx | 2 +- apps/sim/hooks/queries/desktop-activity.ts | 4 +- apps/sim/lib/api/contracts/v2/workflows.ts | 4 +- apps/sim/lib/api/contracts/workspaces.ts | 3 +- .../tool-permissions.integration.ts | 4 +- .../billing/aws-marketplace/notifications.ts | 6 +- .../usage-reservation.integration.ts | 8 +-- .../core/reporting-usage-cache.integration.ts | 1 - apps/sim/lib/branding/contact.ts | 2 - apps/sim/lib/branding/wordmark.ts | 26 -------- .../lib/core/config/appconfig.integration.ts | 5 +- .../lib/core/config/deployment-projection.ts | 28 +++----- .../core/config/enterprise-features.test.ts | 41 ------------ apps/sim/lib/core/config/env-flags.ts | 11 +--- apps/sim/lib/core/config/env.ts | 2 +- apps/sim/lib/core/config/registration.test.ts | 8 +-- .../lib/core/outbox/retention.integration.ts | 1 - .../provider-capacity.integration.ts | 1 - ...lack-shared-member-accounts.integration.ts | 9 +-- .../application/activity.integration.ts | 10 +-- .../lib/desktop/source-request.integration.ts | 12 +--- apps/sim/lib/events/pubsub.ts | 4 -- .../execution/blocked-run-log.integration.ts | 7 +- apps/sim/lib/execution/isolated-vm.test.ts | 14 +--- ...session-input-certification.integration.ts | 38 +++-------- .../provider-admission.integration.ts | 1 - .../search-mcp-setup.integration.ts | 4 -- .../lib/knowledge/documents/ocr-recovery.md | 2 +- apps/sim/lib/knowledge/reranker.test.ts | 2 +- .../sim/lib/logs/execution/logging-session.ts | 8 +-- .../lib/logs/execution/progress-markers.ts | 14 +--- .../content-delivery.integration.ts | 5 +- .../project-file-read.integration.ts | 14 +--- .../workbench-file-provenance.integration.ts | 4 -- .../async-runs/tool-identity.integration.ts | 50 +++++++------- .../request/session/viewer.integration.ts | 11 +--- .../desktop-tool-authorization.integration.ts | 12 ++-- ...esktop-tool-chat-view-lease.integration.ts | 15 +---- .../desktop-tool-executor.integration.ts | 15 +---- .../client/desktop-tool-pickup.integration.ts | 15 +---- .../credential-revocation.integration.ts | 54 +++++++-------- .../backfill-repair.integration.ts | 4 +- .../content-product.integration.ts | 10 +-- .../__integration__/uploads.integration.ts | 9 +-- apps/sim/lib/table/cascade-lock.ts | 5 -- apps/sim/next.config.ts | 6 +- .../sim/providers/openai-compat/model-list.ts | 33 ++++++++++ apps/sim/scripts/test-desktop-inbox-e2e.ts | 4 +- apps/sim/tools/powerbi/powerbi.integration.ts | 1 - apps/sim/vitest.integration.setup.ts | 5 -- docker-compose.ollama.yml | 2 +- helm/sim/.claude/skills/sim-helm/SKILL.md | 4 +- .../sim-helm/references/install-paths.md | 3 +- helm/sim/Chart.yaml | 2 +- helm/sim/README.md | 31 ++++++++- helm/sim/templates/removed-values.yaml | 2 +- helm/sim/tests/removed-values_test.yaml | 2 +- helm/sim/values.schema.json | 10 +-- helm/sim/values.yaml | 8 --- packages/auth-ui/src/compositions.tsx | 17 ++--- packages/auth-ui/src/index.ts | 1 - packages/db/testing/test-infrastructure.ts | 15 ++--- .../src/enterprise-features.ts | 25 +------ .../deployment-config/src/registration.ts | 6 -- .../emcn/src/components/popover/popover.tsx | 30 --------- packages/sim-setup/src/capability-config.ts | 17 ++--- packages/sim-setup/src/capability-setup.ts | 27 -------- packages/sim-setup/src/steps.ts | 2 +- packages/sim-setup/src/twins.ts | 10 ++- packages/testing/src/mocks/env-flags.mock.ts | 63 ++++++++++++------ .../testing/src/mocks/table-events.mock.ts | 2 +- packages/utils/src/site.ts | 3 + scripts/check-explicit-any.baseline.json | 1 - scripts/check-unused-exports.baseline.json | 3 - 112 files changed, 429 insertions(+), 823 deletions(-) delete mode 100644 apps/sim/lib/branding/contact.ts delete mode 100644 apps/sim/lib/branding/wordmark.ts diff --git a/.claude/rules/sim-testing.md b/.claude/rules/sim-testing.md index 52f947b8474..68453963bc0 100644 --- a/.claude/rules/sim-testing.md +++ b/.claude/rules/sim-testing.md @@ -34,7 +34,7 @@ contracts, and demonstrated regressions. | Suffix | Needs | Run with | In CI | |--------|-------|----------|-------| | `*.test.ts(x)` | nothing; global mocks from `vitest.setup.ts` | `bun run --cwd test` | `test` jobs | -| `*.integration.ts` | real PostgreSQL (`TEST_DATABASE_URL`) and Redis (`TEST_REDIS_URL`: required by `apps/sim` and `apps/realtime`; `packages/db` runs without it locally and requires it in CI) | `bun run --cwd test --mode integration` | `integration` jobs, by glob (sharded per provisioning path) | +| `*.integration.ts` | real PostgreSQL (`TEST_DATABASE_URL`) and Redis (`TEST_REDIS_URL`: required by `apps/sim`, `apps/realtime`, and `packages/db`; `apps/sim` needs a non-zero database index) | `bun run --cwd test --mode integration` | `integration` jobs, by glob (sharded per provisioning path) | | `*.live.test.ts` | provider APIs, hosted sandboxes, local runtimes, or sibling checkouts | `bun run --cwd apps/sim test --mode live ` | never | | `apps/desktop/e2e/*.spec.ts` | the packaged Electron app | Playwright | desktop E2E workflow | | `apps/sim/scripts/test-*-e2e.ts` | a running app over HTTP | its `package.json` script when one exists (`bun run test:scim:e2e`; `test:workflow-version-compare:e2e` adds `--no-env-file`), else `bun scripts/test--e2e.ts` from apps/sim | `e2e` jobs (`.github/scripts/http-e2e.sh`) | diff --git a/.cursor/rules/sim-testing.mdc b/.cursor/rules/sim-testing.mdc index a49fff9a55b..18378075937 100644 --- a/.cursor/rules/sim-testing.mdc +++ b/.cursor/rules/sim-testing.mdc @@ -31,7 +31,7 @@ contracts, and demonstrated regressions. | Suffix | Needs | Run with | In CI | |--------|-------|----------|-------| | `*.test.ts(x)` | nothing; global mocks from `vitest.setup.ts` | `bun run --cwd test` | `test` jobs | -| `*.integration.ts` | real PostgreSQL (`TEST_DATABASE_URL`) and Redis (`TEST_REDIS_URL`: required by `apps/sim` and `apps/realtime`; `packages/db` runs without it locally and requires it in CI) | `bun run --cwd test --mode integration` | `integration` jobs, by glob (sharded per provisioning path) | +| `*.integration.ts` | real PostgreSQL (`TEST_DATABASE_URL`) and Redis (`TEST_REDIS_URL`: required by `apps/sim`, `apps/realtime`, and `packages/db`; `apps/sim` needs a non-zero database index) | `bun run --cwd test --mode integration` | `integration` jobs, by glob (sharded per provisioning path) | | `*.live.test.ts` | provider APIs, hosted sandboxes, local runtimes, or sibling checkouts | `bun run --cwd apps/sim test --mode live ` | never | | `apps/desktop/e2e/*.spec.ts` | the packaged Electron app | Playwright | desktop E2E workflow | | `apps/sim/scripts/test-*-e2e.ts` | a running app over HTTP | its `package.json` script when one exists (`bun run test:scim:e2e`; `test:workflow-version-compare:e2e` adds `--no-env-file`), else `bun scripts/test--e2e.ts` from apps/sim | `e2e` jobs (`.github/scripts/http-e2e.sh`) | diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 4277061d49a..4b8a9c59d91 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -169,6 +169,7 @@ BETTER_AUTH_SECRET=$(openssl rand -hex 32) ENCRYPTION_KEY=$(openssl rand -hex 32) INTERNAL_API_SECRET=$(openssl rand -hex 32) CRON_SECRET=$(openssl rand -hex 32) +POSTGRES_PASSWORD=$(openssl rand -hex 24) EOF # Start Sim @@ -237,7 +238,7 @@ If you prefer not to use Docker. **All commands run from the repository root unl cp packages/db/.env.example packages/db/.env ``` - At minimum, each `.env` needs `DATABASE_URL`. `apps/sim/.env` and `apps/realtime/.env` additionally need matching values for `BETTER_AUTH_URL`, `BETTER_AUTH_SECRET`, `INTERNAL_API_SECRET`, and `NEXT_PUBLIC_APP_URL`. `apps/sim/.env` also needs `ENCRYPTION_KEY` and `API_ENCRYPTION_KEY`. Generate any 32-char secrets with `openssl rand -hex 32`. + At minimum, each `.env` needs `DATABASE_URL`. `apps/sim/.env` and `apps/realtime/.env` additionally need matching values for `BETTER_AUTH_URL`, `BETTER_AUTH_SECRET`, `INTERNAL_API_SECRET`, `NEXT_PUBLIC_APP_URL`, and `REDIS_URL`: both services refuse to start without Redis (for a local one, run `docker run -d -p 127.0.0.1:6379:6379 redis:7-alpine` and set `REDIS_URL=redis://localhost:6379`). `apps/sim/.env` also needs `ENCRYPTION_KEY` and `API_ENCRYPTION_KEY`. Generate any 32-char secrets with `openssl rand -hex 32`. The same `BETTER_AUTH_SECRET`, `INTERNAL_API_SECRET`, and `DATABASE_URL` must appear in both `apps/sim/.env` and `apps/realtime/.env` so the two services share auth and DB. After editing `apps/sim/.env`, you can mirror the shared subset into the realtime env in one shot: diff --git a/apps/desktop/src/renderer/offline/index.tsx b/apps/desktop/src/renderer/offline/index.tsx index 2b507f46e3b..f0997aee3b9 100644 --- a/apps/desktop/src/renderer/offline/index.tsx +++ b/apps/desktop/src/renderer/offline/index.tsx @@ -3,7 +3,6 @@ import { AuthRoot, AuthShellView, AuthTextLink, - AuthWordmark, AuthButton as Chip, AuthStatusContent as StatusPageContent, } from '@sim/auth-ui' @@ -71,7 +70,6 @@ function OfflinePage({ isSimCloud }: OfflinePageProps) { } titlebar={