Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 34.3k
src: allow absolute paths for --env-file#49232
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
Uh oh!
There was an error while loading. Please reload this page.
Conversation
nodejs-github-bot commented Aug 18, 2023
Review requested:
|
430d035 to 6b9587bComparenodejs-github-bot commented Aug 19, 2023
Uh oh!
There was an error while loading. Please reload this page.
aduh95 left a comment • edited
Loading Uh oh!
There was an error while loading. Please reload this page.
edited
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: we could limit the number of "magic strings" by using fixtures.path now that absolute paths are supported. This maybe deserves its own PR to refactor the other tests, so feel free to ignore for this PR.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
MoLow left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGMT. +1 to the comments
anonrig commented Aug 21, 2023 • edited
Loading Uh oh!
There was an error while loading. Please reload this page.
edited
Uh oh!
There was an error while loading. Please reload this page.
@nodejs/build It seems Any suggestions on the correct path to take? Referencing build logs: |
6b9587b to 127d263Comparenodejs-github-bot commented Aug 21, 2023
anonrig commented Aug 29, 2023
This PR is blocked by the Node.js CI machines having old GCC versions, despite the documentation saying GCC>9 is supported. cc @nodejs/build |
benjamingr commented Sep 4, 2023
@nodejs/build any chance anyone can take a look at the GCC version on the buiild machine? |
anonrig commented Sep 5, 2023
Blocked by nodejs/build#3317 |
e9fa8c9 to 1e0ca25Compareanonrig commented Oct 10, 2023
Fixed conflicts, rebased and force pushed. |
nodejs-github-bot commented Oct 10, 2023
nikelborm commented Dec 5, 2023
Hi! Is there anything blocking this pr from being merged? The feature will be quite useful in scripts. |
anonrig commented Dec 5, 2023
gcc 10 support is missing from certain CI machines. waiting for it to land to unblock this PR. |
| #include<cstdio> | ||
| #include<cstdlib> | ||
| #include<cstring> | ||
| #include<filesystem> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would recommend adding a comment here that <filesystem> is imported only to support path-processing operations and not actually performing any file system operations (which should always go through libuv)
| std::string path = cwd + kPathSeparator + file_path; | ||
| per_process::dotenv_file.ParsePath(path); | ||
| if (file_path.is_absolute()){ | ||
| per_process::dotenv_file.ParsePath(file_path.string()); | ||
| } else{ | ||
| std::string path = cwd + kPathSeparator + file_path.string(); | ||
| per_process::dotenv_file.ParsePath(path); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add a comment explaining why it is necessary to construct an absolute path here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see why any of this is necessary, so I've opened #51425 as an alternative.
anonrig commented Jan 12, 2024
Closing in favor of #51425 |
Ref: #49148