ai-news-writer-ci / test (pull_request) Failing after 24s
- Add PostgreSQL data layer: aggregation.js, article-store.js, engagement-store.js - Add JSONL event pipeline: engagement-events.js, daily-aggregation.js - Add cron scheduler: aggregation-scheduler.js with prometheus-metrics.js - Add analytics/index.js entry point exposing scheduler API - Wire analytics-api.js to real DB (replaces mock implementation) - Fix analytics-api.test.js: add module injection mocking for async DB calls - Fix daily-aggregation percentile: use true median for even-length arrays - Fix prometheus-metrics test: correct bucket count assertion for p≤5.0 - Make pageAnalytics handler async; wire ui-handlers to real async API - Add aggregation CLI command to index.js (run/stats/recalculate/scheduler) - Add voice (tone/audience_level) propagation through write pipeline and article log - Refactor cli/write.js to use fetchAndFilterSourceArticles pipeline Co-Authored-By: Paperclip <[email protected]>