Feat/tdd skill - #537
Open
sarthak-playvision wants to merge 10 commits into
Open
Conversation
Implement template enhancements: automatic config updates, improved docs
A previous agent session left the repo unbuildable. It rewrote package.json
with an invented older stack (Expo 51 / RN 0.74 / React 18), overwrote .env,
and downgraded the eslint config. This restores the real toolchain and
finishes the Clerk work that was left half-wired.
Restored from HEAD:
- package.json / pnpm-lock.yaml: back to Expo 54, RN 0.81.5, React 19.1,
uniwind. Restores "main" and "packageManager" and ~55 dropped deps.
- eslint.config.mjs: @antfu/eslint-config 7, better-tailwindcss.
- .env: all six variables were deleted, leaving only Clerk keys, which broke
STRICT_ENV_VALIDATION and every prebuild script. Merged back.
Clerk auth (compiled, but could not work at runtime):
- login-screen: call signIn.password() and finalize(). The future API resolves
{ error } rather than throwing, so the old try/catch swallowed every failed
login, and without finalize() no session was ever activated.
- (app)/_layout: gate on Clerk's useAuth() instead of a Zustand flag nothing
set, which bounced successful sign-ins straight back to /login. Wait for
isLoaded so the guard cannot redirect during async session restore.
- _layout: pass tokenCache so sessions survive restart.
- api/client: resolve Clerk lazily with an explicit publishableKey. The bare
module-scope getClerkInstance() threw MissingPublishableKeyError at startup.
- settings: logout now actually reaches Clerk.
- delete use-auth-store: duplicated Clerk session state.
Spec enforcement (added but non-functional):
- drift-check.yml: the sed errored out and the base ref was never resolvable,
so the gate silently passed everything. Now calls check-specs directly.
- eslint-rule-spec: treated every loose file as its own module, demanding
src/components/ui/button.tsx/spec.md. Now wired in and enforcing.
- correct specs that described behavior which does not exist; drop the
invented renderWithProviders helper from the rules.
Also: jest ignores cli/test-project (its duplicate mocks poisoned the haste
map); expo-doctor 18/18 via SDK patch bumps; CLAUDE.md tracked as the
uppercase path so it survives a case-sensitive checkout.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Checks prerequisites (Node 20+, matching CI; activates the pinned pnpm via corepack), creates .env from .env.example without ever overwriting an existing one, and installs with --frozen-lockfile so lockfile drift fails loudly here instead of silently resolving different versions than CI. Warns when a variable in .env.example is missing from .env. env.ts validates these with Zod, but a gap only surfaces at prebuild time under STRICT_ENV_VALIDATION=1, which is a confusing place to find it. Also warns while the Clerk publishable key is still the placeholder. --verify additionally runs lint, type-check, tests, check-specs and expo-doctor. .env.example only listed the three Clerk variables, so copying it to .env produced a file that failed validation immediately on EXPO_PUBLIC_API_URL. Completed it to mirror every variable env.ts requires. Verified from a clean clone: creates a valid .env, installs, and passes strict env validation for development, preview and production. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
fix: repair toolchain damage and complete Clerk auth integration
✅ Deploy Preview for obytes-starter canceled.
|
agents/skills/argent/README.md described Argent as if it were available, and agents/commands.md listed argent:simulator:launch and friends in a file that says each command maps to a script or helper. None of them mapped to anything. This makes the docs true rather than deleting the claim, because it also closes a real gap: the Clerk auth flow has never run on a device. The unit tests mock Clerk entirely and the Android E2E jobs are label-gated and skipped. Installed via `argent init --local`, so it is a devDependency the team gets on pnpm install — no global install, no per-developer `argent init`. The MCP config launches the project-local copy and is committed for Claude Code (.mcp.json), opencode (opencode.json) and VS Code (.vscode/mcp.json). Telemetry is opted out. The default is enabled, but this config is shared by everyone on the repo, so opting in is not a choice to make on their behalf. Re-enable per machine with `pnpm exec argent telemetry enable`. Note .claude/settings.json auto-approves argent tool calls, which Argent writes by default. Remove the allow entry to approve each action by hand. Also ignore .agents/** and .claude/** in eslint. It was linting fenced snippets inside vendored skill docs as if they were project code. This was already breaking lint before this change: the tdd skill commit left 20 errors on this branch, and Argent's docs added 101 more. Drop the hand-written agents/skills/argent/README.md, superseded by the 16 real skills, and rewrite the commands.md section to name them instead of command strings that never existed. Verified: MCP server answers the initialize handshake; lint, type-check and 46 tests pass. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The README covered creating a project from the template and, since setup.sh, installing dependencies — but not running it. The only pointer was a one-line parenthetical, which is thin for the most likely place to get stuck: this app cannot run in Expo Go, and someone expecting to scan a QR code hits a wall with no explanation. Adds a Running the app section covering the Expo Go limitation up front, the per-platform toolchain (JDK 17 for Android, matching what CI builds with), the prebuild step, the three environment variants that existed as scripts but were undocumented, and that sign-in stays broken until a real Clerk key replaces the placeholder. ios/ and android/ are gitignored and generated, so a fresh clone always needs a prebuild. `pnpm ios` does it implicitly, but prebuild:development first pins APP_ENV and validates .env against the Zod schema up front instead of failing later. Verified every pnpm command referenced in the README resolves to a real script, and that --clean forwards through the nested prebuild script. Also fixes "Two things to know" sitting above three bullets in the Argent section. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
AGENTS.md is the first thing an agent reads and its lookup table had no row for running the app, so an agent asked to verify a change on a simulator had no path to the one constraint that matters: this app cannot run in Expo Go, and a fresh clone has no ios/ or android/ to build. Adds table rows for running the app and for Argent, a Detail entry spelling out that `pnpm start` alone is not enough on a fresh clone, and fills the gap in the commands.md expo section, which listed dev/ios/android but never mentioned prebuild, setup.sh, doctor, or the preview/production variants. Verified the relative link and its anchor resolve, and that every path named in the AGENTS.md table exists. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
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.
What does this do?
Why did you do this?
Who/what does this impact?
How did you test this?