fix(ext/node): util.parseEnv and process.loadEnvFile compatibility#32183
Merged
Tango992 merged 23 commits intodenoland:mainfrom Feb 20, 2026
Merged
fix(ext/node): util.parseEnv and process.loadEnvFile compatibility#32183Tango992 merged 23 commits intodenoland:mainfrom
util.parseEnv and process.loadEnvFile compatibility#32183Tango992 merged 23 commits intodenoland:mainfrom
Conversation
This is what node does
Hajime-san
reviewed
Feb 15, 2026
Co-authored-by: Hajime-san <41257923+Hajime-san@users.noreply.github.com>
Hajime-san
reviewed
Feb 16, 2026
util.parseEnvutil.parseEnv and process.loadEnvFile compatibility
Hajime-san
approved these changes
Feb 17, 2026
Comment on lines
+132
to
+133
| parse_env_content_hook(&contents, |key, value| { | ||
| // Follows Node.js behavior where null bytes are stripped from env keys and values |
Contributor
There was a problem hiding this comment.
Good catch!
probably related:
bartlomieju
reviewed
Feb 18, 2026
Signed-off-by: Daniel Osvaldo Rahmanto <daniel.rahmanto@gmail.com>
Member
|
LGTM, I'll let David take another look before approving |
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.
Continues the work from #31856. Closes #30952.
Ported the node's env parser instead of using dotenvy, since there are some differences that makes the node compat test won't pass if dotenvy was used.
Allows https://github.com/nodejs/node/blob/v24.12.0/test/parallel/test-util-parse-env.js to pass