[issue43862] warnings: -W option and PYTHONWARNINGS now use the message as a regex

2021-12-13 Thread STINNER Victor
STINNER Victor added the comment: I mark this issue as a duplicate of bpo-34624. -- resolution: -> duplicate stage: patch review -> resolved status: open -> closed superseder: -> -W option and PYTHONWARNINGS env variable does not accept module regexes

[issue43862] warnings: -W option and PYTHONWARNINGS now use the message as a regex

2021-04-22 Thread STINNER Victor
STINNER Victor added the comment: I also created a thread on python-dev: https://mail.python.org/archives/list/python-...@python.org/thread/JMKLA4RUJLTORBPPTM4BWL76VNNMKYVG/ -- ___ Python tracker

[issue43862] warnings: -W option and PYTHONWARNINGS now use the message as a regex

2021-04-16 Thread STINNER Victor
STINNER Victor added the comment: New changeset 62ec63864822de1dd1933225584e8503ac40c1f9 by Victor Stinner in branch 'master': bpo-43862: Enhance -W cmdline option documentation (GH-25439) https://github.com/python/cpython/commit/62ec63864822de1dd1933225584e8503ac40c1f9 --

[issue43862] warnings: -W option and PYTHONWARNINGS now use the message as a regex

2021-04-16 Thread STINNER Victor
STINNER Victor added the comment: > Sadly, the current -W option documentation is wrong :-( I started by writing > PR 25439 to fix the documentation, before changing its behavior. Hum, "wrong" may be too strong. I would say that it is at least misleading. It starts with "file:line:

[issue43862] warnings: -W option and PYTHONWARNINGS now use the message as a regex

2021-04-16 Thread STINNER Victor
STINNER Victor added the comment: Sadly, the current -W option documentation is wrong :-( I started by writing PR 25439 to fix the documentation, before changing its behavior. -- ___ Python tracker

[issue43862] warnings: -W option and PYTHONWARNINGS now use the message as a regex

2021-04-16 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +24169 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25439 ___ Python tracker ___

[issue43862] warnings: -W option and PYTHONWARNINGS now use the message as a regex

2021-04-16 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: See also https://bugs.python.org/issue34624 -- nosy: +xtreak ___ Python tracker ___

[issue43862] warnings: -W option and PYTHONWARNINGS now use the message as a regex

2021-04-16 Thread STINNER Victor
New submission from STINNER Victor : I propose to change the -W command line option and the PYTHONWARNINGS environment variable to use the message as a regular expression in Python 3.10. Or does anyone have a reason to keep the current behavior as it is? -- Python provides two ways to