docs: add Cursor Cloud development environment setup instructions - #702
Conversation
Co-authored-by: Leo <leoisadev1@users.noreply.github.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
🚀 Preview Deployment ReadyVercel is rebuilding the frontend with the new Convex backend URL. Vercel will post the preview URL automatically. Convex Preview Backend
🤖 Deployed automatically by GitHub Actions |
Greptile SummaryThis PR adds a
Confidence Score: 3/5
Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Cursor Cloud Agent Starts] --> B[Install Bun via ~/.bun/bin]
B --> C[Add ~/.bun/bin to PATH]
C --> D[Run bun install]
D --> E{Create .env.local files}
E --> |apps/web/.env.local| F[Set VITE_CONVEX_URL\nVITE_CONVEX_SITE_URL]
E --> |apps/server/.env.local| G[Set AUTH_GITHUB_ID\nAUTH_GITHUB_SECRET\nBETTER_AUTH_SECRET]
F --> H[Start Services]
G --> H
H --> I[bun dev:web\nVite on :3000]
H --> J[bun dev:server\nRequires Convex Cloud credentials]
H --> K[bun dev:extension\nOptional]
I --> L{Verify}
J --> L
L --> M[bun check — Lint]
L --> N[bun run test — Vitest]
L --> O[bun check-types — TypeScript]
|
| ### Environment | ||
| - Bun is installed at `~/.bun/bin/bun`; ensure `~/.bun/bin` is on `PATH`. | ||
| - Use `bun run test` (not bare `bun test`) to invoke the `vitest run --coverage` script from `package.json`. Bare `bun test` triggers Bun's built-in test runner, which fails because the `bunfig.toml` root (`.bun-tests/`) doesn't exist. | ||
| - The `.env.local` files for `apps/web` and `apps/server` are not checked in. They must be created before starting dev servers. Minimal dev defaults: `VITE_CONVEX_URL=http://localhost:3210`, `VITE_CONVEX_SITE_URL=http://localhost:3210` in `apps/web/.env.local`. |
There was a problem hiding this comment.
Localhost placeholder contradicts Convex cloud requirement
The "Known caveats" section of this same PR explicitly states that bun dev:server requires a Convex cloud project — there is no local Convex server. Setting VITE_CONVEX_URL=http://localhost:3210 as the default will cause the web app to fail to connect to Convex and auth (via VITE_CONVEX_SITE_URL) to break entirely.
Standard Convex cloud dev URLs take the form https://<deployment-name>.convex.cloud. Using localhost:3210 as a placeholder looks like a working local default (which it is not) and will silently fail when a developer follows these instructions.
A more honest placeholder would make clear that a real URL is needed:
| - The `.env.local` files for `apps/web` and `apps/server` are not checked in. They must be created before starting dev servers. Minimal dev defaults: `VITE_CONVEX_URL=http://localhost:3210`, `VITE_CONVEX_SITE_URL=http://localhost:3210` in `apps/web/.env.local`. | |
| - The `.env.local` files for `apps/web` and `apps/server` are not checked in. They must be created before starting dev servers. Minimal dev defaults: `VITE_CONVEX_URL=https://<your-deployment>.convex.cloud`, `VITE_CONVEX_SITE_URL=https://<your-deployment>.convex.cloud` in `apps/web/.env.local`. |
Confidence this is a real issue: 4/5 — The contradiction between the caveat ("requires a Convex cloud project") and the placeholder (localhost:3210) is clear-cut. Convex does not expose a local endpoint on 3210 in the standard cloud-based dev workflow.
| - Bun is installed at `~/.bun/bin/bun`; ensure `~/.bun/bin` is on `PATH`. | ||
| - Use `bun run test` (not bare `bun test`) to invoke the `vitest run --coverage` script from `package.json`. Bare `bun test` triggers Bun's built-in test runner, which fails because the `bunfig.toml` root (`.bun-tests/`) doesn't exist. | ||
| - The `.env.local` files for `apps/web` and `apps/server` are not checked in. They must be created before starting dev servers. Minimal dev defaults: `VITE_CONVEX_URL=http://localhost:3210`, `VITE_CONVEX_SITE_URL=http://localhost:3210` in `apps/web/.env.local`. |
There was a problem hiding this comment.
apps/server/.env.local mentioned but no example given
The Environment section correctly notes that .env.local files are needed for both apps/web and apps/server, but only provides example variables for apps/web. An agent following these instructions would not know which variables to put in apps/server/.env.local (e.g., CONVEX_DEPLOYMENT, AUTH_GITHUB_ID, AUTH_GITHUB_SECRET, BETTER_AUTH_SECRET are all referenced in the Known caveats as requirements). The omission makes the setup incomplete and could leave agents (and humans) stuck.
Consider adding a minimal example for apps/server/.env.local alongside the web example, even if it is just a list of required variable names with placeholder values.
Confidence this is a real issue: 2/5 — The information gap is real, but it is also possible that the Convex CLI and server setup document required variables elsewhere, making this a minor omission rather than a blocker.
Summary
Adds Cursor Cloud-specific development environment instructions to
AGENTS.mdso future cloud agents can properly set up and use the development environment.Changes
## Cursor Cloud specific instructionssection toAGENTS.mdcovering:Testing
bun check— 3/3 workspaces pass (warnings only, 0 errors)bun run test— 100 test files, 2589 tests all passingbun check-types— passes for web and extension workspacesbun dev:web(Vite v7.3.1) starts successfully on port 3000Notes
bun install.env.localfiles are created at setup time (not committed)apps/web/src/routes/share/$shareId.tsxuses.validator()which was renamed to.inputValidator()in the locked@tanstack/react-start@1.165.0Note
Add Cursor Cloud development environment setup instructions to AGENTS.md
Adds a new 'Cursor Cloud specific instructions' section to AGENTS.md covering setup steps, required environment variables, and known caveats for running the project in Cursor Cloud.
bun run testinstead ofbun test.env.localexamples forapps/webandapps/serverwith Convex URL placeholdersMacroscope summarized 3647403.