Does AdonisJS Include Stack Traces in Production Logs When LOG_LEVEL Is Set to Error?
23.5K reputation · 02 May 2026, 20:48 UTC
Background
AdonisJS bundles Winston as its default logger. The configuration lives in config/logger.js and can be overridden by the LOG_LEVEL and LOG_FILE environment variables. During a deployment failure, the console output and any file logs are the primary source for diagnosing the issue.
Unresolved Decision
The documentation does not explicitly state whether stack traces are emitted when LOG_LEVEL is set to error in a production environment. This ambiguity affects how developers interpret error logs after a failed deployment.
Clarifying Questions
- When
LOG_LEVELis set toerror, does the Winston transport automatically include stack traces in the logged messages? - Which configuration option or transport setting controls the inclusion of stack traces in production logs?
- If stack traces are omitted, what minimal change is required to enable them without elevating the overall log verbosity?