Fix database connection exhaustion in tests by setting max_conns=1
when creating pgxpool via pgxpool.ParseConfig().
- Update setupTestServer() in test_helpers.go
- Update setupSyncTestDB() in sync_integration_test.go
This reduces per-test connection usage from 4 to 1, keeping total
connections well under PostgreSQL's default max_connections=100.
78 tests × 1 connection = 78 connections (down from 312 potential)
Fixes test failures: "FATAL: sorry, too many clients already"
See PROJECT_GUIDELINES.md Testing section for details.
- Add explicit note that this is pre-production (no deployments)
- Document two options for updating local databases after schema changes
- Option 1: Recreate database (recommended, loses data)
- Option 2: Manual SQL migration (preserves data)
- Explicitly state: DO NOT create migration files
- Update checklist to include database update step
- Cross-reference from full-stack tasks section
Clarifies the 'no migration needed' philosophy for future developers
- Change 'Review warnings, fix if appropriate' to 'Note warnings'
- Clarify warnings are informational only
- Explicitly prohibit auto-fixing warnings
- Align with verification script instruction: DO NOT automatically fix
- Warnings require explicit user permission to address
- Separate error fixing (required) from warning review (informational)
- Remove ambiguous 'warnings should be reviewed' phrasing
- Align with script instruction: do not auto-fix issues
- Make clear: errors must be fixed, warnings are for acknowledgment
- Add 'Run verification script' as first step in Before Committing
- Add verification script to Phase Completion Verification
- Ensures guideline compliance before commits
- Catches errors early in development workflow
- Verification must pass (0 errors) before declaring complete
- Update PROJECT_GUIDELINES.md to reflect current architecture (Hybrid SSR)
- Integrate service layer and SSR rules into existing sections
- Update README.md paths to match new docs structure (docs/developer/api, docs/user/devices)
- Remove redundant README.md files from bruno/ directories
- Update bruno/collection.bru documentation to current API standard
- Fix architectural pattern description from API-driven to Hybrid SSR
Update Documentation section to reflect new docs/ structure:
- Add comprehensive documentation location table
- Clarify when to use docs/ vs README.md
- Include workflow for documentation updates
- Update all checklist sections with documentation guidance
Changes:
- README.md: Setup/onboarding only
- docs/: User-facing features and workflows
- docs/api/: API reference and endpoints
- docs/devices/: Device setup guides
- docs/contributing/: Development documentation
Ensures documentation is properly organized and searchable
via the new docs system with Lunr.js search.
Updated PROJECT_GUIDELINES.md and verification script to clarify:
1. OOP restriction applies to FRONTEND (TypeScript) only
2. Go methods are fine and encouraged
3. Avoid classes, inheritance, and OOP bloat in TypeScript
Changed verification script:
- Removed Go struct methods check (was incorrect)
- Added TypeScript class declaration check instead
- Now checks for 'class ' keyword in web/*.ts files
This clarifies the guideline was never about Go backend code,
only about avoiding OOP patterns in TypeScript frontend code.
Verification now shows: 13/13 checks passing, 0 warnings
Only 1 error remains: 12 legacy templates with custom CSS.
Documentation updates:
- Update README.md title and all references
- Update PROJECT_GUIDELINES.md title and guidelines
- Update all documentation files in docs/ directory
- Update device setup guides (Kobo, KOReader)
- Update API and architecture documentation
- Update completion summaries and progress reports
This is part 5 of the project rename to Bookhoard.
Added 110 lines of safety guidelines to prevent future bugs:
New CRITICAL PROHIBITIONS:
- NEVER delete code without reading full context (20 lines before/after)
- NEVER make cascading fix-up edits without git diff review
- NEVER skip post-edit verification
New MANDATORY REQUIREMENTS:
- Post-Edit Verification (mandatory for all file modifications)
- Backup Before Large Changes
- Large Deletion Safety Pattern
New ERROR RECOVERY PROTOCOL:
- Immediate actions when mistakes occur
- Recovery examples with git commands
- Prevention learning points
New WORKFLOW CHECKLISTS:
- Error Recovery Protocol
- Phase Completion Verification
These guidelines address the critical bug where auth functions were
accidentally deleted during cleanup, preventing recurrence.
- Document hybrid SSR architecture for frontend implementation
- Add project guidelines for development workflow
- Explain API preservation and SSR approach