codex_a 9d323d2040
Some checks failed
CI / nightly-e2e (pull_request) Has been skipped
CI / ci (pull_request) Successful in 1m22s
CI / pr-e2e (pull_request) Failing after 3m28s
feat: add comprehensive Playwright E2E test suite
- Create e2e/ directory with 7 test modules covering:
  - Home page: title, nav links, theme toggle, newsletter form
  - Cookie consent: accept all, reject all, granular prefs, persistence
  - Article index: loads, tag filter, click-through navigation
  - Article detail: title/read-time, share section, comments, newsletter aside, related
  - Comments: valid submit → redirect, empty body → error display, disabled check
  - Newsletter: JS confirmation message, invalid email error, aside form, duplicate
  - Feeds: RSS/sitemap/robots.txt validity, tag feed, seeded content present
- Extend seed_e2e_content management command with tagged article, about page,
  no-comments article, and legal pages for richer test coverage
- Add seed command tests (create + idempotency) to keep coverage ≥ 90%
- Add pr-e2e CI job (runs on pull_request): builds image, starts postgres + app,
  installs playwright, runs pytest e2e/
- Update nightly-e2e to run full e2e/ suite alongside legacy journey test
- Add --ignore=e2e to unit-test pytest step (coverage must not include browser tests)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-02-28 19:30:43 +00:00
2026-02-28 18:27:56 +00:00
2026-02-28 11:12:52 +00:00

No Hype AI

Django 5.2 + Wagtail 7 blog engine for No Hype AI.

Environment Variables

Required:

  • SECRET_KEY
  • DATABASE_URL
  • ALLOWED_HOSTS
  • DEBUG
  • WAGTAIL_SITE_NAME

Also used:

  • WAGTAILADMIN_BASE_URL
  • CONSENT_POLICY_VERSION
  • EMAIL_BACKEND
  • EMAIL_HOST
  • EMAIL_PORT
  • EMAIL_USE_TLS
  • EMAIL_HOST_USER
  • EMAIL_HOST_PASSWORD
  • DEFAULT_FROM_EMAIL
  • NEWSLETTER_PROVIDER

Containerized Development

docker compose build
docker compose run --rm web python manage.py migrate
docker compose up

App is exposed on http://localhost:8035.

Test/Lint/Typecheck (Docker)

docker compose run --rm web pytest
docker compose run --rm web ruff check .
docker compose run --rm web mypy apps config

Deploy Runbook

git pull origin main
pip install -r requirements/production.txt
python manage.py migrate --run-syncdb
python manage.py collectstatic --noinput
python manage.py tailwind build
python manage.py check_content_integrity
sudo systemctl reload gunicorn

Backups

  • PostgreSQL dump daily: pg_dump | gzip > backup-$(date +%Y%m%d).sql.gz
  • MEDIA_ROOT rsynced offsite daily
  • Restore DB: gunzip -c backup-YYYYMMDD.sql.gz | psql "$DATABASE_URL"
  • Restore media: rsync -avz <backup-host>:/path/to/media/ /srv/nohypeai/media/

Runtime Notes

  • Keep Caddy serving /static/ and /media/ directly in production.
  • Keep Gunicorn behind Caddy and run from a systemd service/socket pair.
  • Use python manage.py purge_old_comment_data --months 24 in cron for comment-data retention.
Description
No description provided
Readme 1.1 MiB
Languages
Python 63.5%
HTML 33.1%
JavaScript 1.4%
Makefile 0.9%
Shell 0.5%
Other 0.6%