Title: src: add `--disable-warning` option by Ethan-Arrowood · Pull Request #50661 · nodejs/node · GitHub
Open Graph Title: src: add `--disable-warning` option by Ethan-Arrowood · Pull Request #50661 · nodejs/node
X Title: src: add `--disable-warning` option by Ethan-Arrowood · Pull Request #50661 · nodejs/node
Description: Fixes: #30810 Fixes: #47478 Fixes: #46862 Fixes: #40940 Rel: #31000 Rel: #36137 This PR adds a new --disable-warning option that allows users to disable specific warnings either by code (i.e. DEP0025) or type (i.e. DeprecationWarning, ExperimentalWarning). This option works alongside existing --warnings and --no-warnings. The implementation is based off of @jasnell comment here: #31000 (comment) and a previous TSC agreement noted here: #31000 (comment) I maintain that my preference is for an option to disable individual experimental warnings by code/id as opposed to all warnings, and for that not to be permitted on NODE_OPTIONS. We discussed in the TSC meeting today (note we only had 6 people so a smallish subset). From the discussion there would be no objection from those who were there if there was an option to disabled specific experimental warnings and that was also supported in NODE_OPTIONS. @bnoordhuis comment here #30810 (comment) is incorrect. --no-warnings does not accept a string. It is only a boolean flag. Passing anything to it disables all flags (I've added a test to confirm this). Issue #46862 is also invalid for the same reason. This new flag will achieve the same effect though. This was also proposed in another PR review comment (#36137 (review)), but I asked if this was even possible in the Node.js Slack and @aduh95 confirmed it was not possible. Checklist make -j4 test (UNIX), or vcbuild test (Windows) passes tests and/or benchmarks are included documentation is changed or added commit message follows commit guidelines
Open Graph Description: Fixes: #30810 Fixes: #47478 Fixes: #46862 Fixes: #40940 Rel: #31000 Rel: #36137 This PR adds a new --disable-warning option that allows users to disable specific warnings either by code (i.e. DEP00...
X Description: Fixes: #30810 Fixes: #47478 Fixes: #46862 Fixes: #40940 Rel: #31000 Rel: #36137 This PR adds a new --disable-warning option that allows users to disable specific warnings either by code (i.e. DEP00...
Opengraph URL: https://github.com/nodejs/node/pull/50661
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files/:range(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:6ee79ee3-e1fd-dc00-1b29-11cb5f4ac311 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | BBD8:1E9024:7B3910:AABE6A:699758D7 |
| html-safe-nonce | caecde5b4c3a0f7ba81a63fe0dc52482e43911f96d196d3f22173f1e151fbc08 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCQkQ4OjFFOTAyNDo3QjM5MTA6QUFCRTZBOjY5OTc1OEQ3IiwidmlzaXRvcl9pZCI6IjI1Nzc1MDA4MzQ5MTg1MjEwNDciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | b141d92214ae52d2762b9efd03907b618ba14cbc18243efb3736b71feb771dae |
| hovercard-subject-tag | pull_request:1596574689 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/nodejs/node/pull/50661/files/9e9c4c5a2a3fbca37e52b1f5e4833ce05ebac22c |
| twitter:image | https://avatars.githubusercontent.com/u/16144158?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/16144158?s=400&v=4 |
| og:image:alt | Fixes: #30810 Fixes: #47478 Fixes: #46862 Fixes: #40940 Rel: #31000 Rel: #36137 This PR adds a new --disable-warning option that allows users to disable specific warnings either by code (i.e. DEP00... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | c2f6b9675e9141deef3eda21e5cb896d461bd4d25aeaeeba804502ef0e8d01f2 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 06ceed63f0d4941788d6c52a00d38ad77b6eaf89 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width