Backend (mypy - 56 errors fixed):
- database.py: Fix async generator return type to AsyncGenerator
- database_models.py: Add type annotations for SQLEnum columns
- middleware.py: Use explicit Optional for exempt_paths parameter
- mail_processor.py: Fix type narrowing in fetch_emails, add Dict type annotation for KNOWN_PROVIDERS
- users.py, auth.py, providers.py, tasks.py: Add type: ignore comments for SQLAlchemy Column assignment patterns
Frontend (eslint - 3 errors, 2 warnings fixed):
- login/page.tsx: Replace any with unknown + type narrowing, prefix unused vars with underscore
- register/page.tsx: Replace any with unknown + type narrowing
Add .github/copilot-instructions.md with lint-check requirements
Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
Agent-Logs-Url: https://github.com/christianlouis/pop_puller_to_gmail/sessions/dac7ab78-fe27-4fe4-890f-32c6c1c6d881
Replace lint.yml, test.yml, security.yml, and docker-build.yml with a
single ci.yml that chains: Lint → Test → Security (CodeQL) → Build.
- Phase 1 (Lint): Black, Ruff, mypy for backend; ESLint for frontend
- Phase 2 (Test): pytest with coverage, PostgreSQL & Redis services
- Phase 3 (Security): Bandit, Safety, CodeQL (Python + JS/TS)
- Phase 4 (Build): Docker build+push, only on main branch or version tags
Each phase depends on the previous one passing. Docker images are only
built when pushing to main or tagging a release.
Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
Agent-Logs-Url: https://github.com/christianlouis/pop_puller_to_gmail/sessions/3903cad7-10be-46e6-8e2d-619d2a874235
- Add SECRET_KEY and ENCRYPTION_KEY validation on startup
- Implement security headers middleware (X-Frame-Options, CSP, HSTS)
- Add CSRF protection middleware
- Create comprehensive GitHub issue templates and PR template
- Add Makefile with common development tasks
- Configure pre-commit hooks (black, ruff, mypy, bandit, detect-secrets)
- Create docs/CODING_PATTERNS.md with best practices
- Create docs/ERRORS.md documenting all error codes
- Add Architecture Decision Records (ADR) for Celery and Fernet encryption
- Create CHANGELOG.md for version tracking
- Set up pytest test infrastructure with fixtures and factories
- Add sample unit tests for security and config validation
- Create CI/CD workflows (test, lint, security)
- Add comprehensive TODO.md with milestones and progress tracking
Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>