Open Bogatinovski opened 4 years ago
Hello I'm getting the same errors, any news on the subject @Bogatinovski ?
I just resolved this error for me. The application couldn't read the email properly from my S3 bucket because I had the standard encryption enabled in the SES rule set. Please make sure that you have disabled the encryption from the active rule set S3 action.
I am using the following configuration:
var overrides = { config: { fromEmail: "info@example.com", emailBucket: "emails-bucket", emailKeyPrefix: "incoming/", forwardMapping: { "info@example.com": [ "bogatinovski.dejan@gmail.com" ] } } };
I have already verified my email address (bogatinovski.dejan@gmail.com) in aws SES. Basically I am trying to send emails to info@example.com and forward them to bogatinovski.dejan@gmail.com.{ level: 'info', message: 'Fetching email at s3://hsty-media-emails/incoming/na9ampj3ilsul4rpfh09qe3ude5cb68okvgn2jo1' }
INFO { level: 'info', message: 'Reply-To address not added because From address was not properly extracted.' }
INFO { level: 'info', message: 'sendMessage: Sending email via SES. Original recipients: info@media.himalayanschool.com. Transformed recipients: bogatinovski.dejan@gmail.com.' }
INFO { level: 'error', message: 'sendRawEmail() returned error.', error: InvalidParameterValue: Empty header names are illegal. at Request.extractError (/var/task/node_modules/aws-sdk/lib/protocol/query.js:47:29) at Request.callListeners (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:105:20) at Request.emit (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:77:10) at Request.emit (/var/task/node_modules/aws-sdk/lib/request.js:673:14) at Request.transition (/var/task/node_modules/aws-sdk/lib/request.js:22:10) at AcceptorStateMachine.runTo (/var/task/node_modules/aws-sdk/lib/state_machine.js:14:12) at /var/task/node_modules/aws-sdk/lib/state_machine.js:26:10 at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:38:9) at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:675:12) at Request.callListeners (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:115:18) { code: 'InvalidParameterValue', time: 2020-08-09T12:58:44.393Z, requestId: '742405d9-50a2-4c38-a592-f4c3037a9edf', statusCode: 400, retryable: false, retryDelay: 11.106050736491092 }, stack: 'InvalidParameterValue: Empty header names are illegal.\n' + ' at Request.extractError (/var/task/node_modules/aws-sdk/lib/protocol/query.js:47:29)\n' + ' at Request.callListeners (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:105:20)\n' + ' at Request.emit (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:77:10)\n' + ' at Request.emit (/var/task/node_modules/aws-sdk/lib/request.js:673:14)\n' + ' at Request.transition (/var/task/node_modules/aws-sdk/lib/request.js:22:10)\n' + ' at AcceptorStateMachine.runTo (/var/task/node_modules/aws-sdk/lib/state_machine.js:14:12)\n' + ' at /var/task/node_modules/aws-sdk/lib/state_machine.js:26:10\n' + ' at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:38:9)\n' + ' at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:675:12)\n' + ' at Request.callListeners (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:115:18)' }
INFO { level: 'error', message: 'Step returned error: Error: Email sending failed.', error: Error: Error: Email sending failed. at Response.<anonymous> (/var/task/node_modules/aws-lambda-ses-forwarder/index.js:274:23) at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:360:18) at Request.callListeners (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:105:20) at Request.emit (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:77:10) at Request.emit (/var/task/node_modules/aws-sdk/lib/request.js:673:14) at Request.transition (/var/task/node_modules/aws-sdk/lib/request.js:22:10) at AcceptorStateMachine.runTo (/var/task/node_modules/aws-sdk/lib/state_machine.js:14:12) at /var/task/node_modules/aws-sdk/lib/state_machine.js:26:10 at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:38:9) at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:675:12), stack: 'Error: Error: Email sending failed.\n' + ' at Response.<anonymous> (/var/task/node_modules/aws-lambda-ses-forwarder/index.js:274:23)\n' + ' at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:360:18)\n' + ' at Request.callListeners (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:105:20)\n' + ' at Request.emit (/var/task/node_modules/aws-sdk/lib/sequential_executor.js:77:10)\n' + ' at Request.emit (/var/task/node_modules/aws-sdk/lib/request.js:673:14)\n' + ' at Request.transition (/var/task/node_modules/aws-sdk/lib/request.js:22:10)\n' + ' at AcceptorStateMachine.runTo (/var/task/node_modules/aws-sdk/lib/state_machine.js:14:12)\n' + ' at /var/task/node_modules/aws-sdk/lib/state_machine.js:26:10\n' + ' at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:38:9)\n' + ' at Request.<anonymous> (/var/task/node_modules/aws-sdk/lib/request.js:675:12)' }
ERROR Invoke Error { "errorType": "Error", "errorMessage": "Error: Step returned error.", "stack": [ "Error: Error: Step returned error.", " at /var/task/node_modules/aws-lambda-ses-forwarder/index.js:320:28", " at processTicksAndRejections (internal/process/task_queues.js:97:5)" ] }