Repository navigation
release: promote dev to main (20 Oct cleanup, refactor, migration squash, explainer site) - #586
Open
Collaboration95 wants to merge 95 commits into
Open
Collaboration95 wants to merge 95 commits into
Collaboration95 wants to merge 95 commits into
Conversation
…bilities fix: detect Android camera and microphone hardware
fix: preserve JPEG MIME type for native photo sealing
Remove superseded planning documents, agent prompts, old evidence screenshots and Demo-era diagrams, and rewrite the repository, deploy, Terraform and learn pages to describe the current system. Co-Authored-By: Claude <noreply@anthropic.com>
docs: cull superseded plans and refresh current documentation
Add behavioural HTTP, CLI, and production-service tests for Cognito failures, group isolation, chat retries, cycle rollback, media tokens, web push, and queue diagnostics. Co-Authored-By: GPT-6.1 Sol <noreply@openai.com>
Every item was re-checked with git grep against origin/dev (aa13def) before deletion. Only tests that exercised deleted code were removed. Deleted files: - src/archive/ArchiveScreen.tsx (RealAccountArchiveScreen; replaced by src/real/Archive.tsx) and tests/real-account-archive.test.tsx - src/reminders/RealGroupSettings.tsx and src/reminders/PrivateReminderSubscription.tsx (superseded by src/real/Settings.tsx), tests/real-group-settings.test.tsx and tests/private-reminder-subscription.test.tsx - src/capsule/RevealEducationPanel.tsx and tests/reveal-education.test.tsx - test-only barrels src/capture/index.ts, src/chat/index.ts and src/chat/unread.ts (tests now import the source modules) - scripts/verify-real-login.mjs and tests/verify-real-login.test.mjs (one-off check for #241) - infra/scripts/emergency-stop-demo.sh (deploy/README.md now names the equivalent `aws lightsail stop-instance` command) Removed server/src/media/backfill.ts and server/tests/media-backfill.test.mjs (one-off local-to-S3 media backfill tool; restore from this commit if a backfill is ever needed). Deleted symbols: - src/domain/reveal-education.ts: revealStateForCycle, revealStateForPremiere - src/capture/video-review.ts: AsyncStoragePendingClipMetadataStore, isPendingMetadata (PENDING_CLIP_METADATA_KEY stays; reset.ts clears it) - src/ui/primitives.tsx: useEffectKey - src/chat/unread-owner.ts: chatConnectionLabel - src/invites/deep-links.ts: inviteLinkErrorMessage - src/domain/invites.ts: INVITE_CODE_LENGTH - src/real/home-model.ts: CLIP_MAX_SECONDS - src/domain/archive.ts: type ReleasedArchive - src/domain/cycles.ts: type CycleHistoryEntry - server/src/ffmpeg.ts: runFfmpegTransform - server/src/jobs/index.ts: processPendingClipJob - server/src/chat/index.ts: addChatReaction, removeChatReaction - server/src/auth/index.ts: lookupRealAccount - server/src/db.ts: isOwner - server/src/groups/real.ts: type RealGroupInputError - server/src/media/index.ts: waitForStagedIntakesIdle, registerStagedIntake and their counter state (only the removed Demo reset waited on it); the call in server/src/http.ts upload intake is removed with it Config and docs: - deploy/release-host.sh: drop the retired REWIND_ADMIN_PASSWORD key (neither the dev nor the release hosted settings object contains it) - package.json: drop unused scripts test:pwa, server:worker, server:migrate, server:reset (the CLI commands remain) - .githooks/pre-push and .github/workflows/quality.yml: drop the deploy/tests/*release*.test.sh glob, which matches nothing - infra/terraform/README.md: drop the stale claim that Deploy dev is not live until a human reviews the Terraform change (dev deploys on every merge), and delete the README-prose test in tests/terraform/environment-transition-policy.test.mjs that pinned it; the Lightsail name/address preservation test stays - Fix doc links that pointed at the deleted files Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…61020 test(server): cover API denials and lifecycle edge cases
…unt UI Adds 23 behavioural test files (error paths, offline, auth and rate-limit failures, empty states). Frontend coverage: statements 77.4% to 86.3%, branches 74.8% to 82.3%, functions 75.3% to 84.2%, lines 80.7% to 88.9%. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…1020 chore: delete dead code found by the 20 Oct audit
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
… route removal Each legacy direct-media assertion (/films/:id/play, /films/:id/download, /clips/:id/download, /films/:id, /downloads/:id) gains an equivalent on the capability path the client uses: cross-group and other-member capability reuse, tampered and missing bytes, sealed archives and session checks. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The client reaches media only through /media/access capabilities, so these routes and their database helpers go: - GET/HEAD /films/:id/play, /films/:id/download, /clips/:id/download - GET /films/:id and /downloads/:id (and the shared clip/film/download loop) - db.ts getMediaJob, getReleasedFilmDownload, getReleasedOwnClipDownload GET /clips/:id (upload status) stays. HEAD is now accepted only on /media/access. The ported tests from the previous commit keep the cross-group, other-member, tampered-media and sealed-archive denials. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The prepared dev/prod media roots were never applied: the state bucket holds no rewind/dev or rewind/prod state, and bootstrap's environment_identity module has zero instances. A read-only plan of bootstrap without environment-identity.tf shows no infrastructure change (only the empty environment_identity_roles output goes away), so no apply is needed. Removed: - infra/terraform/environments/ (dev, prod, backend examples, README) - infra/terraform/modules/private-media and modules/environment-identity - infra/terraform/bootstrap/environment-identity.tf - infra/scripts/terraform-environment.mjs, check-environment-backends.sh - .github/workflows/terraform-environments.yml (Reviewed media Terraform) - tests/terraform/environment-identity.test.mjs, private-media-policy.test.mjs The live roots (bootstrap, demo, media, release) are unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Add server/tests/helpers/runtime.mjs with configurable withRuntime(options, run) and withDatabase(options, run) (prefix, env, seedNow, serverOptions, setup, tolerateClosed) and replace the near-identical local copies. withRuntime migrated: account-safety, chat-replies-reactions, cognito-auth, contribution-ledger-api, http-limits, real-account-auth, real-account-photo, real-account-video, real-chat, real-group-invites, real-group-profiles, runtime. withDatabase migrated: compilation-jobs, contribution-policy, film-compilation, cycles, media-integrity, media-processing, media-upload, durable-worker, queue-observability. Each file keeps a one-line local wrapper so call sites and assertions are unchanged; unused imports were removed. Intentionally left local: real-groups withRuntime (restart() reopens the database and rebinds the server); provision/createGroup/joinGroup helpers in account-safety, real-chat, real-group-profiles, real-group-invites, real-groups, real-account-photo and real-account-video (each differs in return shape, headers vs authorization, clock and password, so sharing would need per-caller switches); boundary-runtime.mjs (already a shared helper with its own request API). Full server suite is identical before and after: 502 tests, 481 pass, 0 fail, 21 skipped. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
http.ts was a 3.9k-line file with three handlers built from long if-chains. The route bodies now move verbatim into named handlers under server/src/routes, one table per family, matched in the original order: - chat-routes: /realtime/groups/* history, SSE, messages, reactions - contribution-routes: /contributions/*, /clips/:id - archive-routes: /media/access/:token, premiere, /archive - real-routes: /real/* (after the transport and session checks) - auth-routes: /auth/* (after the transport check) - respond, limits, body, media-access, context: shared helpers and types http.ts keeps OPTIONS/method gating, family dispatch, /health and createRuntimeServer, and re-exports its previous public names. The HTTP route contract suite (507 cases) and the rest of the server suite pass unchanged, except one deliberate update: /films/* preflights are now the plain 204, since those routes were removed. Design-doc links point at the new modules. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
mediaDir(config, 'staging' | 'processed' | 'intent-scratch') replaces 21 copies of resolve(config.dataDir, 'media', ...) in cli.ts, the routes and configured-runtime.ts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…0261020 test(frontend): raise client coverage with behavioural tests
scaffold.test.mjs imported quality-classification, node-forge-security and braces-security, which run-root-tests already discovers, so they ran twice. It also imported native-build.test.mjs, which run-root-tests filtered out, so the native fixtures ran only through that import. The runner now discovers native-build.test.mjs directly and scaffold imports nothing. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
tests/deploy/run-fixtures.sh runs every tests/deploy/*.test.sh and deploy/tests/*.test.sh. Quality CI, the pre-push hook and the new npm run test:deploy call it instead of three hand-kept lists, and the six per-fixture npm aliases go (deploy/README.md names the bash commands). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The host lifecycle contract test asserted that the README mentions npm run test:host-lifecycle. The package.json script assertion beside it still pins the command itself. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The used-shutter hint and the shutter button could share a React key after the first press, so the hint never faded. A bare '/' realtime base URL was rejected because the trailing slash was stripped before the same-origin check. Re-enables the two tests that recorded these bugs (added in #579). Co-Authored-By: Claude <noreply@anthropic.com>
retryCapture called captureImage with requireAccess, which returns at once unless the screen is 'ready', and a failed capture leaves it at 'capture-failed'. Try again now re-checks access like the local-save card, which brings back the viewfinder for a fresh capture. Found by the client characterisation tests; the new test fails before this change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…0261020 fix: shutter hint key collision and bare same-origin realtime URL
Production renders CameraCaptureScreen only from RealAccountGroupExperience, always with onSubmitPhoto. The paths that need other props or the Demo platform are gone: - DemoCameraPlatform and every platform.kind === 'demo' branch (labelled fixture viewfinder and preview, synthetic-still fallback, in-memory stores); the double moves to tests/mocks/fixture-camera-platform.ts - the CameraPlatform.kind field and the 'demo-fixture' still/clip source - the local-only save path (onAccepted, Use this still, Discard, the saving and saved statuses), so onSubmitPhoto is now required - the browser system-camera option (browserSystemCamera and fileFallbackIsCamera), only enabled when onSubmitPhoto was missing - revealState, onOpenArchive and the capture reveal notice, which leaves src/domain/reveal-education.ts unused, so it is deleted Tests that only exercised removed paths are deleted (fixture metadata-only acceptance, the system-camera adapter case); the others use the fixture double and replace Discard with Retake. The client characterisation suite for both capture screens passes unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ci: retain DevSecOps artifacts for verified dev releases
The root-tests and browser jobs still ran a bare apt-get install of FFmpeg, which crawled past the 10-minute job timeout on #594 tonight. Move the static-build-with-apt-fallback install into scripts/ci/install-ffmpeg.sh and call it from all four jobs.
Playwright --with-deps installs system libraries through the same slow Ubuntu mirror; the root job finished its tests and then hit the 10-minute limit. Raise root to 20 and browser to 25 minutes.
…erywhere ci(quality): use the verified static FFmpeg install in every job
ops: activate release PostgreSQL in one approved deployment
test(perf): scripted load test and performance workflow
Enforce web CSP, patch runtime packages and rescan security risks
fix(deps): patch Expo glob and minimatch build chains
Both hosts idle (dev ~4% CPU, release no containers) and were rebuilt on nano_3_0 (512 MB, US$5/month) on 15 Nov 2026 with their static IPs, so the CloudFront origins and URLs are unchanged. Record the bundle so a later plan does not flip them back, and give new hosts 1 GiB swap and fewer idle daemons.
chore(infra): run dev and release hosts on Lightsail nano
Collaboration95
had a problem deploying
to
dev
November 14, 2026 18:22 — with
GitHub Actions
Failure
On nano the dev runtime's 1 s polling sits at the 5% CPU baseline, burst credit stays at 0% and the post-merge deploy failed its health check, so dev was restored from its micro snapshot. Release stays nano while idle.
chore(infra): keep the dev host on Lightsail micro
This branch was successfully deployed
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.
Promotes
dev(f6cd896) tomain.Included
server/src/media/backfill.ts).http.tsroute split,db.ts/schema.tssplit, large-screen splits, legacy media routes removed (bytes only via/media/access/:token), Demo capture paths and unapplied Terraform environments removed.release.pyreadsschema.ts) plus a guard test.pre-migration-squash); audit events record the real actor; power-controller Lambda removed (and destroyed in AWS); jobs/media modules split; SSE proxy leak and stale-session message fixed.docs/siteexplainer site for the presentation and report.Verification
d0e326b+: deploy succeeded, health ready on PostgreSQL schema v31; a headless browser smoke passed sign-in, group/invite, photo/video upload, Try again, chat + reactions, settings persistence, report sheet, Archive, removed routes 404, account deletion.Release database note:
mainis already at migration version 31, so a release SQLite database migrated by the currentmainopens unchanged after this promotion. Any older SQLite snapshot must be upgraded with tagpre-migration-squashfirst (relevant to the #562 cutover).Needs one approving review (main protection).