bpo-45221: Fix handling of LDFLAGS and CPPFLAGS in setup.py#29031
bpo-45221: Fix handling of LDFLAGS and CPPFLAGS in setup.py#29031ned-deily merged 4 commits intopython:mainfrom
Conversation
Sounds good, thanks for testing it and reviewing! |
| @@ -0,0 +1,3 @@ | |||
| Fixed regression in handling of ``LDFLAGS`` options where | |||
There was a problem hiding this comment.
One small nit: the change also applies to flags in CPPFLAGS as well.
|
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 |
ned-deily
left a comment
There was a problem hiding this comment.
Thanks for the PR and the update!
| @@ -0,0 +1,3 @@ | |||
| Fixed regression in handling of ``LDFLAGS`` and ``CPPFLAGS`` options | |||
| where :meth:`argparse.parse_known_args` could interpret an option as | |||
There was a problem hiding this comment.
Looks like there's a trailing space after as.
|
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 |
|
Looking over it again, it might be nice to retain the old comment that goes with the regex, updating it for argparse, something along the lines of: Does that sound good? |
|
That looks good to me, thanks for taking the time to improve the PR. |
|
Thanks @akulakov for the PR, and @ned-deily for merging it 🌮🎉.. I'm working now to backport this PR to: 3.10. |
|
GH-29037 is a backport of this pull request to the 3.10 branch. |
…ythonGH-29031) (cherry picked from commit 6a533a4) Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
|
|
This processing was removed in 09b2bece78f when replacing optparse with argparse, because argparse will already ignore unknown arguments here; but the line is still useful to avoid mistakenly parsing known args.
I couldn't find any tests for setup.py, I can work on a test if someone can point me to where they are located..
https://bugs.python.org/issue45221