You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
In the latest beta email generation for orders seems to be broken inside the mailbox. In the console the following error is logged:
[run:server] error [EmailPlugin] shippingLine.discounts is not iterable
[run:server] TypeError: shippingLine.discounts is not iterable
[run:server] at Order.get discounts [as discounts] (node_modules/@vendure/core/src/entity/order/order.entity.ts:126:49)
[run:server] at Job.ensureDataIsSerializable (node_modules/@vendure/core/src/job-queue/job.ts:226:53)
[run:server] at Job.ensureDataIsSerializable (node_modules/@vendure/core/src/job-queue/job.ts:219:36)
[run:server] at Job.ensureDataIsSerializable (node_modules/@vendure/core/src/job-queue/job.ts:219:36)
[run:server] at new Job (node_modules/@vendure/core/src/job-queue/job.ts:104:27)
[run:server] at JobQueue.add (node_modules/@vendure/core/src/job-queue/job-queue.ts:59:21)
[run:server] at EmailPlugin.handleEvent (node_modules/@vendure/email-plugin/src/plugin.ts:247:37)
[run:server] at processTicksAndRejections (internal/process/task_queues.js:97:5)
[run:server] at node_modules/@vendure/email-plugin/src/dev-mailbox.ts:44:21
To Reproduce
Steps to reproduce the behavior:
Install a new vendure instance
npm start
open http://localhost:3000/mailbox
Select "order-confirmation" and press "GENERATE TEST"
Expected behavior
No error.
Environment (please complete the following information):
@vendure/core version: 1.0.0-beta.3
Nodejs version: v15.10.0
Database (mysql/postgres etc): mysql
Additional context
The issue seems to come from line 226 in job.ts.
I can imagine that this issue is related to the mock event data as order emails are generated without any issues if the event isn't triggered from the mailbox.
I've discovered this issue only because in one environment an old node version (12) was installed and there email generation seemed to be totally broken. (No mails generating, no errors logged) But these issues were all resolved as soon as I updated node. I just wanted to mention this here in case someone searches for an existing issue.
The text was updated successfully, but these errors were encountered:
Tyratox
changed the title
order-confirmation email generation seems to be broken
order-confirmation email generation seems to be broken in devMode
Mar 17, 2021
Describe the bug
In the latest beta email generation for orders seems to be broken inside the mailbox. In the console the following error is logged:
To Reproduce
Steps to reproduce the behavior:
npm start
http://localhost:3000/mailbox
Expected behavior
No error.
Environment (please complete the following information):
Additional context
The issue seems to come from line 226 in job.ts.
vendure/packages/core/src/job-queue/job.ts
Lines 221 to 229 in ba8d411
EDIT:
I can imagine that this issue is related to the mock event data as order emails are generated without any issues if the event isn't triggered from the mailbox.
I've discovered this issue only because in one environment an old node version (12) was installed and there email generation seemed to be totally broken. (No mails generating, no errors logged) But these issues were all resolved as soon as I updated node. I just wanted to mention this here in case someone searches for an existing issue.
The text was updated successfully, but these errors were encountered: