Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #94239 > unrolled thread

Re: Does the Class UserGroup (issue 11588) exist for python 2.7 ?

Started byChris Angelico <rosuav@gmail.com>
First post2015-07-21 03:15 +1000
Last post2015-07-21 03:15 +1000
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Does the Class UserGroup (issue 11588) exist for python 2.7 ? Chris Angelico <rosuav@gmail.com> - 2015-07-21 03:15 +1000

#94239 — Re: Does the Class UserGroup (issue 11588) exist for python 2.7 ?

FromChris Angelico <rosuav@gmail.com>
Date2015-07-21 03:15 +1000
SubjectRe: Does the Class UserGroup (issue 11588) exist for python 2.7 ?
Message-ID<mailman.788.1437412511.3674.python-list@python.org>
On Mon, Jul 20, 2015 at 10:15 PM, Mark Lawrence <breamoreboy@yahoo.co.uk> wrote:
> On 20/07/2015 12:27, CARANNANTE, MARTINE wrote:
>>
>> Hi
>> Could you tell me if the Class UserGroup (method add_usage_group to
>> support inclusive groups) exist for python 2.7 ?
>> The patch that I found on internet is only for python 3.
>> Thanks in advance for your answer
>> Best regards
>> *Martine Carannante
>> *
>
>
> Almost certainly no as the patch has never been commited, which is why
> http://bugs.python.org/issue11588 is till open.  Even if the patch were
> committed there is no guarantee that the patch will be back ported to 2.7.

There's almost a guarantee that it will NOT be backported to 2.7,
actually; it looks like a completely new feature. But if you're
interested, you might be able to apply the patch to a backported
argparse, such as:

https://pypi.python.org/pypi/argparse

Or just patch your own local version, but that's a bit dodgier.

If you're willing to migrate your code to Python 3, and you want this
feature, post in the tracker issue; even better, help with testing the
patch. The patch was updated for Python 3.5 roughly a year ago, and I
suspect that that version will still work; the lack of response after
that suggests that nobody has the time to test it and make sure it
works in all cases.

Since argparse is written in Python, you don't even need to play
around with a C compiler to test this. It's a nice easy thing to play
with - have a shot!

ChrisA

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web