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
process: disallow some uses of Object.defineProperty() on process.env #28006
base: master
Are you sure you want to change the base?
Conversation
I’m labelling this semver-major because it adds a throw, but I don’t have a strong opinion on that and we can remove it if somebody feels differently.
LGTM if CI is green. (I think I'd prefer that we throw an error with a code property, but that can always be changed later.)
This comment has been hidden.
This comment has been hidden.
|
sorry - missed to see the latest review comments |
|
Is this ready to land? |
I think an error message would be clearer if it explicitly said something like “process.env only supports a configurable, writable, enumerable data property”
| { | ||
| code: 'ERR_INVALID_OBJECT_DEFINE_PROPERTY', | ||
| name: 'TypeError', | ||
| message: 'Must set all attributes with true to \'value\' ' + |
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.
also this one
|
@Himself65 any chance you're still around to address @ljharb's comments and get this ready to land? |
|
Ok, i will take a look |
Disallow the use of Object.defineProperty() to hide entries in process.env or make them immutable.
|
hope the test will pass |
Download action repository 'actions/checkout@v2' (SHA:ec3a7ce113134d7a93b817d10a8272cb61118579)
Warning: Failed to download action 'https://api.github.com/repos/actions/checkout/tarball/ec3a7ce113134d7a93b817d10a8272cb61118579'. Error: Response status code does not indicate success: 503 (Service Unavailable).
Warning: Back off 25.2 seconds before retry.
Warning: Failed to download action 'https://api.github.com/repos/actions/checkout/tarball/ec3a7ce113134d7a93b817d10a8272cb61118579'. Error: Response status code does not indicate success: 503 (Service Unavailable).
Warning: Back off 12.773 seconds before retry.
Error: Response status code does not indicate success: 503 (Service Unavailable). |
|
why all ci crash and only happen in my pr? |
|
|
@ljharb could u please take a look? thanks |
|
LGTM! |
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
try to fix #27990
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passesThe text was updated successfully, but these errors were encountered: