diff --git a/Docs/ManuscriptReader/2026-11-13-development-deployment.md b/Docs/ManuscriptReader/2026-11-13-development-deployment.md new file mode 100644 index 00000000..3009a615 --- /dev/null +++ b/Docs/ManuscriptReader/2026-11-13-development-deployment.md @@ -0,0 +1,50 @@ +# Manuscript Reader Phase 1 — Development deployment + +Status: **successfully deployed**, with authenticated browser and real Windows acceptance outstanding. + +- Target: https://dev.plotdirector.com/ on Atlas, service `plotdirector-dev`, database `PlotDirector_Development`. +- Exact deployed source: `e67c6f9fb528026093ed3a043e062449d5558da8`, shared branch `codex/word-companion-native-phase1-20261104`. +- Deployment started: **13 November 2026 12:22:34 UTC**. Installation/startup checks finished **12:24:02 UTC**. Deployment including final smoke/integrity checks finished **12:24:59 UTC**. Total **145.02 seconds (2 minutes 25 seconds)**. +- Release: `/srv/apps/plotdirector-dev/releases/e67c6f9-20261113T122234Z`. +- Prior release: `1ad8e12ca89627f4e13c335e84f5fcb5711d61cb`; code-only rollback copy: `/srv/apps/plotdirector-dev/current-before-e67c6f9-20261113T122234Z`. +- Published/deployed `PlotLine.dll` SHA-256: `7f1cd3930bb7dbaf6064493e17b16ef7260529346076273102a1f8a0e343e8eb`. Deployed assembly contains the full candidate commit. Prior backup DLL hash matches the previously running release. + +## Preparation and installation + +Fetched the shared branch before preparation: local HEAD and remote both identified the qualified Reader commit; no later Windows/shared changes were present. The only existing untracked file was the architecture assessment, left untouched. No concurrent publish/deployment process was observed; chat-status discovery did not respond. Existing qualification logs and Phase1.md corresponded to the unchanged candidate. Between the previously deployed source and this candidate, the only other commits were deployment documentation. + +Verified the running process database configuration matched the protected Development environment file, then verified the effective SQL connection reports `PlotDirector_Development`. The established restart gate found no blocking queued/active import, Story Intelligence, synthesis, enrichment or marker work, and was repeated immediately before service interruption. + +Published the candidate in Release configuration, archived it, stopped the service, copied the physical current directory to the rollback location, installed with the established rsync exclusions, preserved ownership and restarted. The initial publish hit the per-user `/tmp` quota before any service interruption. Retried with fresh output on `/srv/repos/.plotdirector-builds/reader-deployment-e67c6f9/publish`, retaining the original deployment clock. No application correction was needed. + +No SQL migration, new database object, configuration change or Companion installer was required or applied. Protected configuration and data-protection key hashes match their pre-deployment values. Production was untouched. + +## Live checks + +Passed: + +- Service active; local HTTP and public HTTPS GETs return 200 with normal TLS validation. +- Public login page returns 200 with the existing email/password controls. Reader, Book, Chapter and native workspace status routes redirect unauthenticated requests to the existing login route without disclosing manuscript text. +- Existing native books/connection APIs return 401 without installation credentials. Reader CSS and JavaScript return 200. +- A read-only helper loaded the **actual deployed assembly** and used the existing repositories/stored procedures against an existing Development manuscript. First/middle/last chapters returned **537 exact ordered paragraphs**; checkpoint synchronisation and snapshot capture timestamps matched persisted sources. A foreign account was refused. +- Aggregate SHA-256 fingerprints taken before deployment and after all smoke reads match for all paragraph manuscript payloads/revisions/request IDs (including paragraph GUIDs and chapter checkpoints), chapter validations, paragraph positions, manuscript document bindings and database object definitions. Reader smoke reads did not change accepted manuscript or synchronisation state. +- Startup has no new application errors. The previously documented HTTPS-port detection warning occurs on local HTTP; public HTTPS succeeds normally. No configuration change was made for this existing warning. + +**Unverified on the live site:** successful authenticated author login, the three rendered navigation entry points, Reader DOM/text selection, previous/next/selector interaction, rendered timestamps, live empty state, and cross-account HTTP requests. No existing authenticated browser session or supplied credentials were available. These are distinct from the deployed-assembly/database checks above and the previously qualified synthetic Chromium tests. No login was forged, account provisioned, real author prose changed or manuscript data exported for testing. + +Real Word-to-Reader acceptance and an actual installed Windows PWA remain unverified. + +## Code-only rollback + +The previous application directory remains available. If needed, stop `plotdirector-dev`, rsync the backup above into `/srv/apps/plotdirector-dev/current/` with `--delete` and the normal exclusions (`appsettings*.json`, `.env*`, `App_Data/`, `wwwroot/uploads/`, `uploads/`, `logs/`, `Logs/`), restore `plotdirector:plotdirector` ownership, start the service, and verify local/public GETs and the previous DLL hash. **Do not restore or roll back the database** to reverse this code release. + +## Windows acceptance procedure + +1. Sign in to https://dev.plotdirector.com/ using the account owning the existing bound book. Open that manuscript in Windows Word with the current Companion. +2. Make a small identifiable change within an existing chapter, save, and wait for the Companion to report successful synchronisation. Record the chapter and acknowledgment time; do not proceed on pending, rejected or needs-review status. +3. In PlotDirector, open the book's Chapters list and choose **Read manuscript** for that chapter (also available in chapter details and the Book menu). Refresh if the Reader was already open. +4. Confirm the new text appears exactly once in the correct paragraph position. Check the separately labelled chapter synchronisation and accepted snapshot capture times using the meanings in [Phase1.md](Phase1.md); both are explicitly UTC. +5. Drag-select several paragraphs normally and copy/paste into a plain-text document. Confirm the new phrase and paragraph order are selectable and copied accurately. +6. Navigate to another chapter using previous/next and the selector, then return. Confirm Reader navigation did not change Word text or the Companion accepted revision. Repeat in the installed desktop PWA/mobile browser as required. + +This procedure has **not** been performed on real Word during this deployment.