[issue29195] Get rid of supporting outdated wrong keyword arguments in re methods

2017-03-31 Thread Donald Stufft

Changes by Donald Stufft :


--
pull_requests: +901

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29195] Get rid of supporting outdated wrong keyword arguments in re methods

2017-01-12 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29195] Get rid of supporting outdated wrong keyword arguments in re methods

2017-01-12 Thread Roundup Robot

Roundup Robot added the comment:

New changeset f8678135c042 by Serhiy Storchaka in branch 'default':
Issue #29195: Removed support of deprecated undocumented keyword arguments
https://hg.python.org/cpython/rev/f8678135c042

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29195] Get rid of supporting outdated wrong keyword arguments in re methods

2017-01-08 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

"pattern" is not more informative, it is just wrong. The argument of the 
match() method is not a pattern, it is a string with which a pattern is matched.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29195] Get rid of supporting outdated wrong keyword arguments in re methods

2017-01-07 Thread Raymond Hettinger

Raymond Hettinger added the comment:

It's too bad that "pattern" lost out to the less informative "string".

+1 for finishing the work and applying this patch.

--
nosy: +rhettinger

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29195] Get rid of supporting outdated wrong keyword arguments in re methods

2017-01-07 Thread Serhiy Storchaka

New submission from Serhiy Storchaka:

Many re methods accepted the string parameter as a keyword argument by wrong 
name. This was fixed in issue20283. Wrong keyword names were still accepted, 
but a deprecation warning was emitted if use them. Proposed patch finishes the 
deprecation period (started since 3.4) and removes the support of wrong names.

Python 2.7.7, 3.3.6, 3.4-3.6:

>>> import re
>>> re.compile('.').match(pattern='a')
__main__:1: DeprecationWarning: The 'pattern' keyword parameter name is 
deprecated.  Use 'string' instead.
<_sre.SRE_Match object; span=(0, 1), match='a'>
>>> re.compile('.').match(string='a')
<_sre.SRE_Match object; span=(0, 1), match='a'>

Python 3.7:

>>> re.compile('.').match(pattern='a')
Traceback (most recent call last):
  File "", line 1, in 
TypeError: Required argument 'string' (pos 1) not found

--
components: Extension Modules
files: re_wrong_string_argument_name.patch
keywords: patch
messages: 284911
nosy: serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Get rid of supporting outdated wrong keyword arguments in re methods
type: enhancement
versions: Python 3.7
Added file: http://bugs.python.org/file46192/re_wrong_string_argument_name.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com