Skip to content
This repository has been archived by the owner on Feb 28, 2022. It is now read-only.

context.request.headers is undefined on production #413

Closed
tripodsan opened this issue Jul 16, 2019 · 2 comments · Fixed by #421
Closed

context.request.headers is undefined on production #413

tripodsan opened this issue Jul 16, 2019 · 2 comments · Fixed by #421
Assignees
Labels
bug Something isn't working released

Comments

@tripodsan
Copy link
Contributor

tripodsan commented Jul 16, 2019

seen on adobe dev site:

2019-07-16T00:48:36.918Z       stdout: error: Exception during #13/once:once from /nodejsAction/XXbdNKOd/html.js:257559:
TypeError: Cannot read property 'x-strain' of undefined
    at pre (/nodejsAction/XXbdNKOd/html.js:383905:56)
    at invoker (/nodejsAction/XXbdNKOd/html.js:383826:43)
    at once (/nodejsAction/XXbdNKOd/html.js:383850:14)
    at execFns (/nodejsAction/XXbdNKOd/html.js:109351:17)
    at process._tickCallback (internal/process/next_tick.js:68:7)
2019-07-16T00:48:36.920Z       stdout: debug: context.error -> 500

probably from:

  logger.info(`strain header: ${context.request.headers['x-strain']}`);

/cc @ryanbetts

@tripodsan tripodsan self-assigned this Jul 16, 2019
@tripodsan tripodsan added the bug Something isn't working label Jul 16, 2019
@tripodsan
Copy link
Contributor Author

very unlikely, but this happens when action is invoked not via web-gateway.

tripodsan added a commit that referenced this issue Jul 18, 2019
adobe-bot pushed a commit that referenced this issue Jul 18, 2019
## [4.0.5](v4.0.4...v4.0.5) (2019-07-18)

### Bug Fixes

* **pipe:** ensure request.headers is present ([#421](#421)) ([91aa8e4](91aa8e4)), closes [#413](#413)
@adobe-bot
Copy link

🎉 This issue has been resolved in version 4.0.5 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants