I am facing the same issue.
On Ghost 4.5.0
Ubuntu: 18.04
Digital Ocean
MailGun
The post was public & email was getting sent to paid & free members. Funny thing is that it’s working when sending an email to a specific person but failing to send to 35 subscribers (paid & free).
Subscription emails & all are going fine.
My error log is below:
{“name”:“Log”,“hostname”:“ghost-s-1vcpu-2gb-blr1-01”,“pid”:15807,“level”:50,“req”:{“meta”:{“requestId”:“2b77b6e6-206a-4929-abb3-0c8ff363b6c1”,“userId”:“1”},“url”:“/notifications/”,“method”:“GET”,“originalUrl”:“/ghost/api/canary/admin/notifications/”,“params”:{},“headers”:{“x-forwarded-for”:“xxx.xx.xx.xx”,“x-forwarded-proto”:“https”,“x-real-ip”:“xxx.xx.xx.xx”,“host”:“ankitsawant.com”,“connection”:“close”,“sec-ch-ua”:“" Not;A Brand";v="99", "Google Chrome";v="91", "Chromium";v="91"”,“sec-ch-ua-mobile”:“?0”,“app-pragma”:“no-cache”,“user-agent”:“Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.77 Safari/537.36”,“content-type”:“application/json; charset=UTF-8”,“accept”:“application/json, text/javascript, /; q=0.01”,“x-requested-with”:“XMLHttpRequest”,“x-ghost-version”:“4.5”,“sec-fetch-site”:“same-origin”,“sec-fetch-mode”:“cors”,“sec-fetch-dest”:“empty”,“referer”:“https://ankitsawant.com/ghost/",“accept-encoding”:"gzip, deflate, br”,“accept-language”:“en-US,en;q=0.9”,“cookie”:“REDACTED”},“query”:{}},“res”:{“_headers”:{“x-powered-by”:“Express”,“cache-control”:“no-cache, private, no-store, must-revalidate, max-stale=0, post-check=0, pre-check=0”,“content-type”:“application/json; charset=utf-8”,“content-length”:“259”,“etag”:“W/"103-hkrtG3KtYASDTC/z/neaimNnUwM"”,“vary”:“Accept-Encoding”},“statusCode”:500,“responseTime”:“90ms”},“err”:{“id”:“0f182df0-c2c9-11eb-b30c-3f02b66b0516”,“domain”:“https://ankitsawant.com”,“code”:null,“name”:“InternalServerError”,“statusCode”:500,“level”:“normal”,“message”:“allNotifications.forEach is not a function”,“stack”:"InternalServerError: allNotifications.forEach is not a function\n
> at new GhostError (/var/www/ghost/versions/4.5.0/node_modules/@tryghost/errors/lib/errors.js:10:26)\n
> at _private.prepareError (/var/www/ghost/versions/4.5.0/core/server/web/shared/middlewares/error-handler.js:53:19)\n
> at Layer.handle_error (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/layer.js:71:5)\n
> at trim_prefix (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:315:13)\n
> at /var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:284:7\n
> at Function.process_params (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:335:12)\n
> at next (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:275:10)\n
> at Layer.handle_error (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/layer.js:67:12)\n
> at trim_prefix (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:315:13)\n
> at /var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:284:7\n
> at Function.process_params (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:335:12)\n
> at next (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:275:10)\n
> at /var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:635:15\n
> at next (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/index.js:260:14)\n
> at next (/var/www/ghost/versions/4.5.0/node_modules/express/lib/router/route.js:127:14)\n
> at /var/www/ghost/versions/4.5.0/core/server/api/shared/http.js:124:17\n\nTypeError: allNotifications.forEach is not a function\n
> at Notifications.fetchAllNotifications (/var/www/ghost/versions/4.5.0/core/server/services/notifications/notifications.js:26:26)\n
> at Notifications.browse (/var/www/ghost/versions/4.5.0/core/server/services/notifications/notifications.js:42:37)\n
> at Object.query (/var/www/ghost/versions/4.5.0/core/server/api/canary/notifications.js:11:34)\n
> at Object.query (/var/www/ghost/versions/4.5.0/core/server/api/shared/pipeline.js:156:24)\n
> at /var/www/ghost/versions/4.5.0/core/server/api/shared/pipeline.js:243:35\n
> at tryCatcher (/var/www/ghost/versions/4.5.0/node_modules/bluebird/js/release/util.js:16:23)\n
> at Promise._settlePromiseFromHandler (/var/www/ghost/versions/4.5.0/node_modules/bluebird/js/release/promise.js:547:31)\n
> at Promise._settlePromise (/var/www/ghost/versions/4.5.0/node_modules/bluebird/js/release/promise.js:604:18)\n
> at Promise._settlePromise0 (/var/www/ghost/versions/4.5.0/node_modules/bluebird/js/release/promise.js:649:10)\n
> at Promise._settlePromises (/var/www/ghost/versions/4.5.0/node_modules/bluebird/js/release/promise.js:729:18)\n
> at _drainQueueStep (/var/www/ghost/versions/4.5.0/node_modules/bluebird/js/release/async.js:93:12)\n
> at _drainQueue (/var/www/ghost/versions/4.5.0/node_modules/bluebird/js/release/async.js:86:9)\n
> at Async._drainQueues (/var/www/ghost/versions/4.5.0/node_modules/bluebird/js/release/async.js:102:5)\n
> at Immediate.Async.drainQueues [as _onImmediate] (/var/www/ghost/versions/4.5.0/node_modules/bluebird/js/release/async.js:15:14)\n
> at processImmediate (internal/timers.js:462:21)"},"msg":"allNotifications.forEach is not a function","time":"2021-06-01T11:03:56.251Z","v":0}`
Can anyone assist?