-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
feat: remove deprecated CLI flags for HTTP/2, HTTPS, and web socket server options #5634
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
base: next
Are you sure you want to change the base?
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## next #5634 +/- ##
==========================================
+ Coverage 83.58% 83.68% +0.10%
==========================================
Files 11 11
Lines 1955 1955
Branches 725 725
==========================================
+ Hits 1634 1636 +2
+ Misses 288 286 -2
Partials 33 33 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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.
Can you add this change (and replacement for these options) in migration guide to ensure we don't remove something more than expected
|
|
||
| - The following CLI options were deprecated and have now been removed. Please use the recommended alternatives: | ||
| - http2 -> server | ||
| - https -> server |
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.
Will just server work? Maybe server-type? Just to ensure we don't make a typo 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.
oh, do you provide here not CLI options, let's write CLI options 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.
Just write webpack help serve --verbose and you will see all CLI options
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.
Thanks, I was looking for a way to reproduce and see them
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.
@alexander-akait I’m not fully understanding this. At what point is the cli-flags.js file executed within webpack-cli?
I’m asking because many of these options were removed in webpack-dev-server v5 — for example in this commit: 1e86e37
And this is the commit that updated the README accordingly 5c4006a
So it feels like those options no longer exist starting from webpack-dev-server v5, and this file was simply never updated — or maybe I’m missing something?
In any case, even when running from main, those options still don’t show up in the CLI. From what I understand, the file that actually defines the CLI options is options.json, which would make cli-flags.js unnecessary.
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’m not fully understanding this. At what point is the cli-flags.js file executed within webpack-cli?
Yes, webpack-cli reads this file and getting all CLI flag from this file. Looks like we forgot to remove them. To avoid such things let's add a test case in CLI with --help and --verbose so we will have all CLI arguments in our tests
Summary
removing these options that are deprecate
What kind of change does this PR introduce?
Did you add tests for your changes?
Does this PR introduce a breaking change?
If relevant, what needs to be documented once your changes are merged or what have you already documented?