-
Notifications
You must be signed in to change notification settings - Fork 29.6k
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.config is not cloneable anymore in v16.x #43581
Labels
process
Issues and PRs related to the process subsystem.
Comments
We cannot intercept modifications on frozen or sealed objects and print warnings about that. That seems to be the key point of runtime deprecation. |
The deprecation is here since v16.0.0. I think it should be fine to make it eol and lock the object in v19.0.0 |
gribnoysup
added a commit
to gribnoysup/node
that referenced
this issue
Jul 1, 2022
gribnoysup
added a commit
to gribnoysup/node
that referenced
this issue
Sep 9, 2022
nodejs-github-bot
pushed a commit
that referenced
this issue
Sep 10, 2022
Fixes: #43581 PR-URL: #43627 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Fyko
pushed a commit
to Fyko/node
that referenced
this issue
Sep 15, 2022
Fixes: nodejs#43581 PR-URL: nodejs#43627 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
v16.0.0 / process
#36902 made
process.config
immutable. That's fine in principle but the use of aProxy
breaks the following code:The properties themselves are proxies too so
Object.fromEntries(Object.entries(process.config))
is not an easy workaround.I suggest using
Object.freeze()
orObject.seal()
instead.cc @jasnell
The text was updated successfully, but these errors were encountered: