fix(workflow-executor): accept LOG_LEVEL case-insensitively#1684
Merged
Conversation
When the executor shares an environment/secret with other services, LOG_LEVEL often comes in lowercase (e.g. "info"). The strict Debug/Info/Warn/Error enum rejected it, throwing ConfigurationError at startup and crashing the process. Normalize the value to the canonical case before validating, so "info", "INFO", "debug", etc. are accepted; genuinely unknown levels (trace, verbose, …) still throw. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Coverage Impact This PR will not change total coverage. Modified Files with Diff Coverage (1)
🛟 Help
|
forest-bot
added a commit
that referenced
this pull request
Jun 19, 2026
## @forestadmin/workflow-executor [1.5.1](https://github.com/ForestAdmin/agent-nodejs/compare/@forestadmin/workflow-executor@1.5.0...@forestadmin/workflow-executor@1.5.1) (2026-06-19) ### Bug Fixes * **workflow-executor:** accept LOG_LEVEL case-insensitively ([#1684](#1684)) ([dcb8769](dcb8769))
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Problem
When the executor runs alongside other services sharing an environment/secret,
LOG_LEVELis often set in lowercase (e.g.info). The CLI validated it against a strictDebug | Info | Warn | Errorenum, soinfothrewConfigurationErrorat startup → the process exits → the container never serves (deploy goes unhealthy, 100% 5xx).Hit in real life deploying the executor as a Beanstalk service: the shared
staging/env-varssecret setsLOG_LEVEL=info, crashing the executor on boot.Fix
parseLoggerLevelEnvnow normalizes the raw value to canonical case (raw[0].toUpperCase() + rest.toLowerCase()) before validating. Soinfo,INFO,debug,WARN, … are accepted and mapped toInfo/Debug/Warn; genuinely unknown levels (trace,verbose, …) still throw the sameConfigurationError.Tests
info/INFO/debug/WARN/errorparse to the canonical level.debug/info(now valid);trace/fatal/verbose/xxxstill throw.cli.test.tsgreen (68 tests).🤖 Generated with Claude Code
Note
Accept
LOG_LEVELenv var case-insensitively in workflow-executorNormalizes the
LOG_LEVELvalue inparseLoggerLevelEnvby capitalizing the first character and lowercasing the rest before validating against the schema, so values likeinfo,INFO, orWarnare all accepted. Tests are updated to cover the new case-insensitive behavior and remove previously invalid cases that are now valid.Macroscope summarized 9c9c5c6.