Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Empty errors in production environment #1394

Open
scriptcoded opened this issue Sep 3, 2020 · 0 comments
Open

Empty errors in production environment #1394

scriptcoded opened this issue Sep 3, 2020 · 0 comments
Labels
type/bug Something is not working the way it should

Comments

@scriptcoded
Copy link

Description

When running inside Docker (production environment) logs are very sparse. So sparse in fact that the errors aren't even shown. This is the error output in Docker:

{"event":"uncaughtException","level":6,"path":["app"],"context":{"error":{}}}

And this is the same error in dev:

✕ app uncaughtException
  | error  Error: Missing environment variable APP_BASE_URL
  |            at Object.buildConfig (/usr/src/app/src/config.js:8:15)
  |            at Object.<anonymous> (/usr/src/app/src/app.js:24:14)
  |            at Module._compile (internal/modules/cjs/loader.js:1137:30)
  |            at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
  |            at Module.load (internal/modules/cjs/loader.js:985:32)
  |            at Function.Module._load (internal/modules/cjs/loader.js:878:14)
  |            at Module.require (internal/modules/cjs/loader.js:1025:19)
  |            at require (internal/modules/cjs/helpers.js:72:18)
  |            at Object.<anonymous> (/usr/src/app/index.js:30:1)

The only way to get hold of the error as far as I can tell is to use LOG_PRETTY=true which is far from perfect in a production environment with centralized logging.

Repro

Start nexus using LOG_PRETTY=false node .nexus/build after nexus build

@scriptcoded scriptcoded added the type/bug Something is not working the way it should label Sep 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/bug Something is not working the way it should
Projects
None yet
Development

No branches or pull requests

1 participant