Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 34k
bpo-46436: Fix command-line option -d/--directory in module http.server#30701
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
geryogam commented Jan 19, 2022 • edited by miss-islington
Loading Uh oh!
There was an error while loading. Please reload this page.
edited by miss-islington
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
JelleZijlstra 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.
The substantive change looks good and I confirmed that it worked, but I agree that you should back out the unnecessary changes such as those in import order. They're not necessary to the fix.
merwok 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.
Thanks! Do revert the import change then this can be merged
bedevere-bot commented Jan 22, 2022
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated. Once you have made the requested changes, please leave a comment on this pull request containing the phrase |
geryogam commented Jan 22, 2022
@merwok Done. I have made the requested changes; please review again. |
bedevere-bot commented Jan 22, 2022
Thanks for making the requested changes! @merwok: please review the changes made to this pull request. |
merwok commented Jan 23, 2022
Please see https://bugs.python.org/issue46285 |
geryogam commented Jan 23, 2022 • 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.
Thanks for mentioning this issue @merwok. As you pointed out, function The But method I have just updated my PR to implement this. It fixes both #46285 and #46436. It also adds a command-line option |
merwok commented Jan 23, 2022
Thanks for fixing both issues! I’ll review the code to see if it also addresses my bad feeling about setting attributes directly on class objects. Can we reference two tickets in one pull request title? Also have two blurb notes? |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
merwok commented Jan 23, 2022 • 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.
Nice trick with using a closure to keep
|
geryogam commented Jan 24, 2022 • 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.
Yes that is another solution: moving the creation of Factory methods (like |
merwok commented Jan 24, 2022
I wasn’t suggesting to use |
geryogam commented Jan 25, 2022
Yes I think that is necessary. To instantiate a request handler with the
The designer of the class @orsenthil, do you a preference? |
geryogam commented Jan 31, 2022 • 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.
Thanks for reviewing it @merwok! I cleaned up my history and tested the HTTP server locally with Curl for both PRs and I confirm that they both work. You can merge them. |
merwok commented Jan 31, 2022
Can you add your name to Misc/ACKS? |
geryogam commented Jan 31, 2022
@merwok It is already there actually. |
miss-islington commented Jan 31, 2022
Sorry, I can't merge this PR. Reason: |
geryogam commented Feb 3, 2022
@merwok Is there anything that I can do to let miss-islington merge? |
miss-islington commented Feb 3, 2022
Thanks @maggyero for the PR 🌮🎉.. I'm working now to backport this PR to: 3.9, 3.10. |
…er (pythonGH-30701) Fix command-line option -d/--directory in http.server main function that was ignored when combined with --cgi. Automerge-Triggered-By: GH:merwok (cherry picked from commit 2d08034) Co-authored-by: Géry Ogam <gery.ogam@gmail.com>
bedevere-bot commented Feb 3, 2022
GH-31102 is a backport of this pull request to the 3.10 branch. |
…er (pythonGH-30701) Fix command-line option -d/--directory in http.server main function that was ignored when combined with --cgi. Automerge-Triggered-By: GH:merwok (cherry picked from commit 2d08034) Co-authored-by: Géry Ogam <gery.ogam@gmail.com>
bedevere-bot commented Feb 3, 2022
GH-31103 is a backport of this pull request to the 3.9 branch. |
merwok commented Feb 3, 2022
The main branch was locked temporarily, tests were always failing because of a missing indent in a new test. |
geryogam commented Feb 3, 2022
@merwok Thanks a lot for your careful review! It really improved the quality of this PR. I think we can now merge the other PR. |
…er (pythonGH-30701) Fix command-line option -d/--directory in http.server main function that was ignored when combined with --cgi. Automerge-Triggered-By: GH:merwok (cherry picked from commit 2d08034) Co-authored-by: Géry Ogam <gery.ogam@gmail.com> Co-authored-by: Géry Ogam <gery.ogam@gmail.com>
Fix command-line option -d/--directory in http.server main
function that was ignored when combined with --cgi.
https://bugs.python.org/issue46436
Automerge-Triggered-By: GH:merwok
Automerge-Triggered-By: GH:merwok