[BUG] ERROR: Failed to fetch dashboard statistics SqlLiteError after upgrade to latest version v0.8.4
Bug Description
after upgrade from 0.8.3 -> 0.8.4, I got internal server error for watchlist
Steps To Reproduce
- upgrade docker from 0.8.3 -> 0.8.4
- after login, I got internal server error for the watchlist.
Expected Behavior
loading watchlist correctly
Screenshots
Environment
- Pulsarr Version: v0.8.4
- Deployment: Docker
- OS: Debian 13
- Browser: Chrome 143
Logs
pulsarr | [13:59:13 UTC] ERROR: Failed to fetch dashboard statistics
pulsarr | route: "GET /v1/stats/all"
pulsarr | error: {
pulsarr | "message": "select watchlist_items.title, watchlist_items.guids, MIN(watchlist_items.thumb) as thumb, GROUP_CONCAT(DISTINCT u.name, '||') as user_names, count() as count from watchlist_items left join users as u on watchlist_items.user_id = u.id where type = 'show' and added >= '2025-11-29 13:59:13.261' group by watchlist_items.title, watchlist_items.guids order by count desc limit 10 - DISTINCT aggregates must have exactly one argument",
pulsarr | "name": "SqliteError",
pulsarr | "type": "Error",
pulsarr | "stack":
pulsarr | SqliteError: select watchlist_items.title, watchlist_items.guids, MIN(watchlist_items.thumb) as thumb, GROUP_CONCAT(DISTINCT u.name, '||') as user_names, count() as count from watchlist_items left join users as u on watchlist_items.user_id = u.id where type = 'show' and added >= '2025-11-29 13:59:13.261' group by watchlist_items.title, watchlist_items.guids order by count desc limit 10 - DISTINCT aggregates must have exactly one argument
pulsarr | at Database.prepare (/app/node_modules/better-sqlite3/lib/methods/wrappers.js:5:21)
pulsarr | at Client_BetterSQLite3._query (/app/node_modules/knex/lib/dialects/better-sqlite3/index.js:35:34)
pulsarr | at executeQuery (/app/node_modules/knex/lib/execution/internal/query-executioner.js:37:17)
pulsarr | at Client_BetterSQLite3.query (/app/node_modules/knex/lib/client.js:154:12)
pulsarr | at Runner.query (/app/node_modules/knex/lib/execution/runner.js:141:36)
pulsarr | at ensureConnectionCallback (/app/node_modules/knex/lib/execution/internal/ensure-connection-callback.js:13:17)
pulsarr | at Runner.ensureConnection (/app/node_modules/knex/lib/execution/runner.js:318:20)
pulsarr | at process.processTicksAndRejections (node:internal/process/task_queues:103:5)
pulsarr | at async Runner.run (/app/node_modules/knex/lib/execution/runner.js:30:19)
pulsarr | at async DatabaseService.getMostWatchlistedShows (file:///app/dist/services/database/methods/analytics.js:68:21)
pulsarr | "code": "SQLITE_ERROR"
pulsarr | }
pulsarr | [13:59:13 UTC] ERROR: Internal server error occurred
pulsarr | reqId: "req-19"
pulsarr | request: {
pulsarr | "id": "req-19",
pulsarr | "method": "GET",
pulsarr | "path": "/v1/stats/all",
pulsarr | "route": "/v1/stats/all"
pulsarr | }
pulsarr | err: {
pulsarr | "message": "Unable to fetch dashboard statistics",
pulsarr | "name": "InternalServerError",
pulsarr | "status": 500,
pulsarr | "statusCode": 500,
pulsarr | "type": "Error",
pulsarr | "stack":
pulsarr | InternalServerError: Unable to fetch dashboard statistics
pulsarr | at Object.internalServerError (/app/node_modules/@fastify/sensible/lib/httpErrors.js:137:12)
pulsarr | at _Reply.sensibleInternalServerError [as internalServerError] (/app/node_modules/@fastify/sensible/index.js:55:44)
pulsarr | at Object.
๐ CodeRabbit Plan Mode
Generate an implementation plan and prompts that you can use with your favorite coding agent.
- [ ] Create Plan
๐ Similar Issues
Related Issues
- https://github.com/jamcalli/Pulsarr/issues/769
- https://github.com/jamcalli/Pulsarr/issues/173
- https://github.com/jamcalli/Pulsarr/issues/466
- https://github.com/jamcalli/Pulsarr/issues/302
๐ Related PRs
jamcalli/Pulsarr#813 - fix(database): prevent status regression during metadata refresh [merged]
๐งช Issue enrichment is currently in open beta.
You can configure auto-planning by selecting labels in the issue_enrichment configuration.
To disable automatic issue enrichment, add the following to your .coderabbit.yaml:
issue_enrichment:
auto_enrich:
enabled: false
๐ฌ Have feedback or questions? Drop into our discord!
Same issue here.
Corresponding Log Entry:
[15:18:26 UTC] ERROR: Internal server error occurred
reqId: "req-a1"
request: {
"id": "req-a1",
"method": "GET",
"path": "/v1/stats/all",
"route": "/v1/stats/all"
}
err: {
"message": "Unable to fetch dashboard statistics",
"name": "InternalServerError",
"status": 500,
"statusCode": 500,
"type": "Error",
"stack":
InternalServerError: Unable to fetch dashboard statistics
at Object.internalServerError (/app/node_modules/@fastify/sensible/lib/httpErrors.js:137:12)
at _Reply.sensibleInternalServerError [as internalServerError] (/app/node_modules/@fastify/sensible/index.js:55:44)
at Object.
Hey @NoLife141
Thanks for reporting. The stats function has a bug in the sqlite branch. I'll push a hot fix shortly.
Should be all fixed and released!