Re: [Python-Dev] PEP 466: Proposed policy change for handling network security enhancements

2014-03-22 Thread R. David Murray
On Sun, 23 Mar 2014 01:01:38 +0100, Antoine Pitrou wrote: > On Sun, 23 Mar 2014 07:11:07 +1000 > Nick Coghlan wrote: > > This PEP does *not* grant any general exemptions to the usual backwards > > compatibility policy for maintenance releases. Instead, it is designed > > to make it easier to prov

Re: [Python-Dev] cpython: #20145: assert[Raises|Warns]Regex now raise TypeError on bad regex.

2014-03-23 Thread R. David Murray
On Sun, 23 Mar 2014 21:43:14 +0100, Antoine Pitrou wrote: > On Sun, 23 Mar 2014 20:47:28 +0100 (CET) > r.david.murray wrote: > > http://hg.python.org/cpython/rev/ec556e45641a > > changeset: 89936:ec556e45641a > > user:R David Murray > > date:

Re: [Python-Dev] PEP 466: Proposed policy change for handling network security enhancements

2014-03-24 Thread R. David Murray
On Sun, 23 Mar 2014 21:31:12 -0400, Barry Warsaw wrote: > On Mar 24, 2014, at 11:38 AM, Chris Angelico wrote: > > >Easy. Just set PYTHONPATH to import the SEPython [1] lib ahead of the > >standard lib. Then you can go back to the standard 2.7 (if you want > >to) by unsetting PYTHONPATH. > > > >It

Re: [Python-Dev] PEP 461: Adding % formatting to bytes and bytearray -- Final, Take 3

2014-03-27 Thread R. David Murray
On Thu, 27 Mar 2014 12:24:49 +0100, Antoine Pitrou wrote: > On Tue, 25 Mar 2014 15:37:11 -0700 > Ethan Furman wrote: > > > > ``%a`` will call ``ascii()`` on the interpolated value. This is intended > > as a debugging aid, rather than something that should be used in production. > > Non-ASCII va

Re: [Python-Dev] Status of PEP 3145 - Asynchronous I/O for subprocess.popen

2014-03-28 Thread R. David Murray
On Fri, 28 Mar 2014 10:45:01 -0400, Tres Seaver wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > On 03/27/2014 09:16 PM, Josiah Carlson wrote: > > But here's the thing: I can build enough using asyncio in 30-40 lines > > of Python to offer something like the above API. The problem is

Re: [Python-Dev] Status of PEP 3145 - Asynchronous I/O for subprocess.popen

2014-03-29 Thread R. David Murray
On Sat, 29 Mar 2014 16:30:25 +0100, Antoine Pitrou wrote: > On Sat, 29 Mar 2014 04:44:32 -0400 > Terry Reedy wrote: > > On 3/28/2014 5:12 PM, Antoine Pitrou wrote: > > > On Fri, 28 Mar 2014 16:58:25 -0400 > > > Terry Reedy wrote: > > > > >> However, the code below creates a subprocess for one c

Re: [Python-Dev] Python 4?

2014-04-03 Thread R. David Murray
On Thu, 03 Apr 2014 09:59:55 -0400, Brett Cannon wrote: > On Thu, Apr 3, 2014 at 9:51 AM, Skip Montanaro wrote: > > > I saw mention recently of Python 4 and assumed all such references > > were either April Fool's jokes or pie-in-the-sky dreams for a new > > version of Python which may never arr

Re: [Python-Dev] Incorrect behavior in str.format() method when padding with '\x00'

2014-04-03 Thread R. David Murray
On Thu, 03 Apr 2014 11:20:20 -0400, "Eric V. Smith" wrote: > On 04/02/2014 04:08 PM, John Tyree wrote: > > > > Hi all, > > > > Is there any particularly reason for the following behavior on both > > 2.7.6 and 3.4.0 ? > > > > >>> "{:\x00<5}".format(2) > > '2' > > >>> > > "{:\

Re: [Python-Dev] static typing of input arguments in signatures

2014-04-13 Thread R. David Murray
On Sun, 13 Apr 2014 15:59:36 -0400, Terry Reedy wrote: > On 4/13/2014 4:11 AM, Łukasz Langa wrote: > > On Apr 13, 2014, at 12:48 AM, Stefan Behnel wrote: > > > >> Stefan Behnel, 12.04.2014 19:11: > >> > >> So, what I've learned from seven years of Cython is that static typing in > >> signatures

Re: [Python-Dev] Appeal for reviews

2014-04-14 Thread R. David Murray
On Mon, 14 Apr 2014 08:18:13 -0400, Nick Coghlan wrote: > On 14 Apr 2014 01:56, "Stephen J. Turnbull" wrote: > > > > mar...@v.loewis.de writes: > > > > > For gaining commit access, it's really more important that the patch > > > is factually finished, than that it's author believes it to. If pe

[Python-Dev] New mailing list for workflow/workflow infrastructure discussion/tasks

2014-04-16 Thread R. David Murray
Based on a number of conversations at PyCon, we've created a new mailing list: https://mail.python.org/mailman/listinfo/core-workflow The purpose of this list is to facilitate the conversations and coordinate the work that needs to happen to improve our development workflow. Nick's PEP is one

Re: [Python-Dev] Language Summit notes

2014-04-16 Thread R. David Murray
On Wed, 16 Apr 2014 15:38:21 -0700, Benjamin Peterson wrote: > On Wed, Apr 16, 2014, at 15:26, Antoine Pitrou wrote: > > > > Hi Taavi, > > > > Thanks for the report! > > > > > Disussion about packaging continues. Glyph asks if the PSF could fund a > > > usability study on installing Python. Pe

Re: [Python-Dev] Language Summit notes

2014-04-17 Thread R. David Murray
On Thu, 17 Apr 2014 01:23:13 -0400, Terry Reedy wrote: > On 4/16/2014 6:26 PM, Antoine Pitrou wrote: > > >> AP exams are starting to allow Python, but it's 10% of the AP CS exams. > > > > "AP"? > > (I thought that was me, but it sounds unlikely :-)) > > AP = Advanced Placement. US and Canadian h

Re: [Python-Dev] ref leaks

2014-04-24 Thread R. David Murray
On Thu, 24 Apr 2014 17:17:41 +0200, Stefan Krah wrote: > Ethan Furman wrote: > > >>Any words of wisdom for tracking those leaks? > > Often the easiest way is to compile --with-valgrind and run the test > under Valgrind (obviously). > > In the Valgrind output, search for "definitely lost" and ig

Re: [Python-Dev] API and process questions (sparked by Claudiu Popa on 16104

2014-04-28 Thread R. David Murray
On Mon, 28 Apr 2014 23:24:16 +0300, Claudiu Popa wrote: > - Will raise NotImplementedError if multiprocessing can't be used > (when `workers` equals to 0 or > 1) I think the most common use case for this ability will be "run with the appropriate number of processes for the system I'm on", where '

Re: [Python-Dev] pep8 reasoning

2014-04-28 Thread R. David Murray
On Mon, 28 Apr 2014 18:01:32 -0400, Terry Reedy wrote: > On 4/28/2014 2:12 PM, Chris Barker wrote: > > > I don't think anyone should write code with variable width fonts, > > The problem is that fixed pitch does not work well for even a half-way > complete unicode font and I don't know that the

Re: [Python-Dev] Behaviour change of object().format() in 3.4

2014-05-06 Thread R. David Murray
On Tue, 06 May 2014 16:45:52 +0200, James Swift wrote: > Hi, > > In 3.3 I could do the following > > >>> "{x:s}".format(**{'x': [1, 2, 3]}) > '[1, 2, 3]' > > But in 3.4 > > >>> "{x:s}".format(**{'x': [1, 2, 3]}) > Traceback (most recent call last): > File "", line 1, in > TypeError: non-emp

Re: [Python-Dev] pip: cdecimal an externally hosted file and may be unreliable [sic]

2014-05-08 Thread R. David Murray
On Thu, 08 May 2014 09:58:08 -0400, Donald Stufft wrote: > I don't think the warning is FUD, and it doesn't mention anything security > related at all. The exact text of the warning is in the subject of the email > here: > > cdecimal an externally hosted file and may be unreliable > > Which

Re: [Python-Dev] pip: cdecimal an externally hosted file and may be unreliable [sic]

2014-05-08 Thread R. David Murray
On Thu, 08 May 2014 10:11:39 -0400, "R. David Murray" wrote: > On Thu, 08 May 2014 09:58:08 -0400, Donald Stufft wrote: > > I don't think the warning is FUD, and it doesn't mention anything security > > related at all. The exact text of the warning is i

Re: [Python-Dev] pip: cdecimal an externally hosted file and may be unreliable [sic]

2014-05-08 Thread R. David Murray
On Thu, 08 May 2014 10:37:15 -0400, Donald Stufft wrote: > Most users are not going to care up until the point where the external server > is unavailable, and then they care a whole lot. On the tin it sounds > reasonable > to just download the external file if the server is up however we've done

Re: [Python-Dev] pip: cdecimal an externally hosted file and may be unreliable [sic]

2014-05-08 Thread R. David Murray
On Thu, 08 May 2014 11:32:28 -0400, Donald Stufft wrote: > On May 8, 2014, at 11:21 AM, R. David Murray wrote: > > Ah, I understand now. > > > > Your perspective is as someone who is using pip for *deployment*. > > Deployment, or any kind of situation where you

Re: [Python-Dev] pip: cdecimal an externally hosted file and may be unreliable [sic]

2014-05-09 Thread R. David Murray
On Fri, 09 May 2014 11:39:02 -0400, Donald Stufft wrote: > > On May 9, 2014, at 9:58 AM, M.-A. Lemburg wrote: > > On 09.05.2014 13:44, Donald Stufft wrote: > >> On May 9, 2014, at 4:12 AM, M.-A. Lemburg wrote: > > I snipped the rest of the discussion and reliability, using > > unmaintained pack

Re: [Python-Dev] [Python-checkins] cpython (merge 3.4 -> default): Merge 3.4->default: asyncio: Fix upstream issue 168: StreamReader.read(-1) from

2014-05-12 Thread R. David Murray
These changes appear to have caused several builbot failures, and there doesn't appear to be a bugs.python.org issue to report it to. One failure example: http://buildbot.python.org/all/builders/PPC64%20PowerLinux%203.4/builds/119 test_asyncio fails similarly for me on tip. On Mon, 12 May 20

Re: [Python-Dev] Where is our official policy of what platforms we do support?

2014-05-14 Thread R. David Murray
On Wed, 14 May 2014 11:31:15 -0300, "Joao S. O. Bueno" wrote: > +1 for an official policy that comes with a "permanent maintainer for > this platform required" as part of the list > of requisites. > > js > -><- > > On 14 May 2014 11:20, Brett Cannon wrote: > > Over the past week or so ther

Re: [Python-Dev] Where is our official policy of what platforms we do support?

2014-05-15 Thread R. David Murray
On Thu, 15 May 2014 19:14:55 +0200, Antoine Pitrou wrote: > On Thu, 15 May 2014 09:40:33 -0500 > Skip Montanaro wrote: > > On Thu, May 15, 2014 at 9:35 AM, Brett Cannon wrote: > > > I view stable buildbots as staying up and testing critical platforms. > > > > Would "supported" and "unsupported"

Re: [Python-Dev] Returning None from methods that mutate object state

2014-05-20 Thread R. David Murray
On Tue, 20 May 2014 09:30:47 -0700, Chris Barker wrote: > > > > [].sort() is None > > > True > > "ABC".lower() is None > > > False > > > > > > That's a deliberate design choice, and one that has been explained a > > > few times on the list when folks ask why "[].sort().reverse()" doesn't

Re: [Python-Dev] Internal representation of strings and Micropython

2014-06-04 Thread R. David Murray
On Thu, 05 Jun 2014 00:14:32 +0300, Paul Sokolovsky wrote: > That said, and unlike previous attempts to develop a small Python > implementations (which of course existed), we're striving to be exactly > a Python language implementation, not a Python-like language > implementation. As there's no fo

Re: [Python-Dev] Request: new "Asyncio" component on the bug tracker

2014-06-05 Thread R. David Murray
On Thu, 05 Jun 2014 12:03:15 +0200, Victor Stinner wrote: > Would it be possible to add a new "Asyncio" component on > bugs.python.org? If this component is selected, the default nosy list > for asyncio would be used (guido, yury and me, there is already such > list in the nosy list completion).

Re: [Python-Dev] asyncio/Tulip: use CPython as the new upstream

2014-06-06 Thread R. David Murray
On Fri, 06 Jun 2014 11:31:23 +0200, Victor Stinner wrote: > Hi, > > I added a new BaseEventLoop.is_closed() method to Tulip and Python 3.5 > to fix an issue (see Tulip issue 169 for the detail). The problem is > that I don't want to add this method to Python 3.4 because usually we > don't add ne

Re: [Python-Dev] asyncio/Tulip: use CPython as the new upstream

2014-06-06 Thread R. David Murray
On Fri, 06 Jun 2014 10:05:52 -0400, Antoine Pitrou wrote: > Le 06/06/2014 07:00, R. David Murray a écrit : > > > > I don't have any opinion on the workflow. > > > > My understanding is that part of the purpose of the "provisional" > > designation i

Re: [Python-Dev] Moving Python 3.5 on Windows to a new compiler

2014-06-06 Thread R. David Murray
On Fri, 06 Jun 2014 16:37:01 -, dw+python-...@hmmz.org wrote: > On Fri, Jun 06, 2014 at 03:41:22PM +, Steve Dower wrote: > > > [snip] > > Speaking as a third party who aims to provide binary distributions for > recent Python releases on Windows, every new compiler introduces a > licensing

Re: [Python-Dev] namedtuple implementation grumble

2014-06-07 Thread R. David Murray
On Fri, 06 Jun 2014 19:50:57 +0100, Chris Withers wrote: > I've been trying to add support for explicit comparison of namedtuples > into testfixtures and hit a problem which lead me to read the source and > be sad. > > Rather than the mixin and class assembly in the function I expected to > f

Re: [Python-Dev] namedtuple implementation grumble

2014-06-08 Thread R. David Murray
On Sat, 07 Jun 2014 10:50:16 -0400, Antoine Pitrou wrote: > Le 07/06/2014 09:25, R. David Murray a écrit : > > On Fri, 06 Jun 2014 19:50:57 +0100, Chris Withers > > wrote: > >> I've been trying to add support for explicit comparison of namedtuples > >> int

Re: [Python-Dev] Criticism of execfile() removal in Python3

2014-06-10 Thread R. David Murray
On Tue, 10 Jun 2014 19:07:40 +1000, Nick Coghlan wrote: > On 10 Jun 2014 18:41, "Paul Moore" wrote: > > > > On 10 June 2014 08:36, Nick Coghlan wrote: > > > The standard implementation of run_path reads the whole file into > > > memory, but MicroPython would be free to optimise that and do > > >

Re: [Python-Dev] subprocess shell=True on Windows doesn't escape ^ character

2014-06-11 Thread R. David Murray
Also notice that using a list with shell=True is using the API incorrectly. It wouldn't even work on Linux, so that torpedoes the cross-platform concern already :) This kind of confusion is why I opened http://bugs.python.org/issue7839. On Wed, 11 Jun 2014 16:58:30 -0500, Ryan wrote: > Of cours

Re: [Python-Dev] subprocess shell=True on Windows doesn't escape ^ character

2014-06-13 Thread R. David Murray
On Fri, 13 Jun 2014 16:57:49 +1200, Greg Ewing wrote: > Nikolaus Rath wrote: > > you almost certainly want to do > > > > Popen(['/bin/sh', 'for i in `seq 42`; do echo $i; done'], shell=False) > > > > because if your shell happens to be tcsh or cmd.exe, things are going to > > break. > > On Uni

Re: [Python-Dev] Examples for PEP 572

2018-07-04 Thread Sven R. Kunze
Sorry for adding yet another mail. :-( On 04.07.2018 10:54, Serhiy Storchaka wrote: Sorry, this PEP was rewritten so many times that I missed your Appendix. while total != (total := total + term):     term *= mx2 / (i*(i+1))     i += 2 return total This very example here caught my eye. Is

Re: [Python-Dev] Examples for PEP 572

2018-07-04 Thread Sven R. Kunze
On 04.07.2018 21:18, Steven D'Aprano wrote: Read the Appendix to the PEP: https://github.com/python/peps/blob/master/pep-0572.rst Yes, I did after I realized where that example came from. But my point was actually to understand the evaluation order because Uncle Timmy won't be around to expla

[Python-Dev] Re: Comments on PEP 558

2021-02-03 Thread Sven R. Kunze
Hi Mark, I've been working on a project heavily relying on frame.f_locals. Are you planning to remove it? On 30.01.21 13:18, Mark Shannon wrote: Given that f_locals is broken, why is keeping compatibility for this obscure, and probably unused case worthwhile? The break in compatibility wi

[Python-Dev] Re: Comments on PEP 558

2021-02-04 Thread Sven R. Kunze
On 03.02.21 23:37, Nick Coghlan wrote: No, PEP 558 doesn't remove it, it enhances it to be a live view of the frame state instead of an inconsistently updated snapshot. As long as it is possible to **write** to existing keys to **add new keys** to frame.f_locals, I am actually quite happy.

[Python-Dev] Re: Comments on PEP 558

2021-02-08 Thread Sven R. Kunze
Hi Mark, On 04.02.21 12:47, Mark Shannon wrote: Hi Sven, On 04/02/2021 9:06 am, Sven R. Kunze wrote: As long as it is possible to **write** to existing keys to **add new keys** to frame.f_locals, I am actually quite happy. Out of interest, why would you want to add new keys to the locals of

[Python-Dev] Re: PEP 654 -- Exception Groups and except* : request for feedback for SC submission

2021-03-02 Thread Sven R. Kunze
very issue with existing code. Once that is clear, it should be easy for everybody to apply the same pattern to their code. Here is the copy from github: try:     r = call_item.fn(*call_item.args, **call_item.kwargs) except BaseException as e:     exc = _ExceptionWithTraceback(e, e.__tra

[Python-Dev] Re: PEP 654 -- Exception Groups and except* : request for feedback for SC submission

2021-03-02 Thread Sven R. Kunze
Hey Irit, cool proposal. I just have two questions regarding "except Exception" or "except BaseException" as it is used e.g. by concurrent.futures.process (def _process_worker) from the stdlib. Almost similarly, I maintain a library using this pattern to wrap/unwrap exceptions from remote P

[Python-Dev] Re: PEP 654 -- Exception Groups and except* : request for feedback for SC submission

2021-03-03 Thread Sven R. Kunze
Hey Irit, find my 3 answers below: On 03.03.21 13:17, Irit Katriel wrote: Hi Sven, I like your formatting suggestion, thanks. I will do something like that. You're welcome. I'm not sure I understand your question. ExceptionGroup is a subclass of Exception (which is a subclass of BaseExce

[Python-Dev] Re: PEP 654 -- Exception Groups and except* : request for feedback for SC submission

2021-03-04 Thread Sven R. Kunze
is no reason to ever do anything else. I hope that makes sense. On Wed, Mar 3, 2021 at 7:32 PM Sven R. Kunze <mailto:srku...@mail.de>> wrote: Hey Irit, find my 3 answers below: On 03.03.21 13:17, Irit Katriel wrote: > Hi Sven, > > I like your

[Python-Dev] Immutable view classes - inherit from dict or from Mapping?

2021-04-12 Thread Andreas R Maier
Hi, I have written some classes that represent immutable views on collections (see "immutable-views" package on Pypi). Currently, these view classes inherit from the abstract collection classes such as Mapping, Sequence, Set. However, they implement the read-only methods of dict, list and set,

[Python-Dev] Re: In support of PEP 649

2021-04-17 Thread jacob . r . hayes
Related, `inspect.Parameter.annotation` is affected too, but at least this attribute is called `annotation` instead of `type`. I noticed this today with `multipledispatch` (though [reported](https://github.com/mrocklin/multipledispatch/issues/104) in 2019) and some other internal code, both usi

[Python-Dev] Windows buildbots may be broken

2021-07-30 Thread Jason R. Coombs
g this command on your repo to bypass the issue: git rm -r :/ ; git checkout HEAD -- :/ You may want to consider adding this command after every update to the repo to avoid the stale state. ___ Python-Dev mailing list -- python-dev@python.org To unsub

[Python-Dev] Re: Windows buildbots may be broken

2021-08-03 Thread Jason R. Coombs
umaran Sent: Tuesday, August 3, 2021 09:29 To: Jason R. Coombs Cc: python-dev@python.org Subject: Re: [Python-Dev] Windows buildbots may be broken On Fri, Jul 30, 2021 at 02:28:08PM +, Jason R. Coombs wrote: > If you run such a buildbot, please consider running this command on >

Re: [Python-Dev] Cut/Copy/Paste items in IDLE right click context menu

2013-02-16 Thread R. David Murray
On Sun, 17 Feb 2013 14:00:24 +1100, Neil Hodgson wrote: > Nick Coghlan: > > > - no need for extensive cross-OS testing prior to commit, that's a key > > part of the role of the buildbots > >Are the buildbots able to test UI features like menu selections? Not to mention that the test suite i

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-20 Thread R. David Murray
On Thu, 21 Feb 2013 11:35:23 +1300, Greg Ewing wrote: > Carl Meyer wrote: > > An XML parser that follows the XML standard is never safe to expose to > > untrusted input. > > Does the XML standard really mandate that a conforming parser > must blindly download any DTD URL given to it from the rea

Re: [Python-Dev] [Python-checkins] peps: Pre-alpha draft for PEP 435 (enum). The name is not important at the moment, as

2013-02-23 Thread R. David Murray
On Sun, 24 Feb 2013 01:31:09 +1000, Nick Coghlan wrote: > On Sun, Feb 24, 2013 at 1:06 AM, Antoine Pitrou wrote: > > On Sat, 23 Feb 2013 16:02:31 +0100 > > Stefan Krah wrote: > >> eli.bendersky wrote: > >> > +Ordered comparisons between enumeration values are *not* supported. > >> > Enums are

Re: [Python-Dev] [Python-checkins] peps: Pre-alpha draft for PEP 435 (enum). The name is not important at the moment, as

2013-02-23 Thread R. David Murray
On Sat, 23 Feb 2013 08:27:50 -0800, Eli Bendersky wrote: > On Sat, Feb 23, 2013 at 7:57 AM, R. David Murray wrote: > > > On Sun, 24 Feb 2013 01:31:09 +1000, Nick Coghlan > > wrote: > > > On Sun, Feb 24, 2013 at 1:06 AM, Antoine Pitrou > > wrote: > >

Re: [Python-Dev] [Python-checkins] peps: Pre-alpha draft for PEP 435 (enum). The name is not important at the moment, as

2013-02-23 Thread R. David Murray
On Sat, 23 Feb 2013 09:15:54 -0800, Eli Bendersky wrote: > On Sat, Feb 23, 2013 at 9:04 AM, Antoine Pitrou wrote: > > > On Sat, 23 Feb 2013 08:27:50 -0800 > > Eli Bendersky wrote: > > > > See also http://bugs.python.org/issue16801#msg178542 for another use > > > > case for named values. > > > >

Re: [Python-Dev] [Python-checkins] peps: Pre-alpha draft for PEP 435 (enum). The name is not important at the moment, as

2013-02-25 Thread R. David Murray
On Mon, 25 Feb 2013 07:12:03 -0800, Ethan Furman wrote: > I must admit I find it mildly amusing (but a lot frustrating) that we > are talk about /enumerations/ not needing to be based on ints. > Checking out Merrian-Webster gives this: > > Definition of ENUMERATE > 1 > : to ascertain the number o

Re: [Python-Dev] [Python-checkins] peps: Pre-alpha draft for PEP 435 (enum). The name is not important at the moment, as

2013-02-25 Thread R. David Murray
On Mon, 25 Feb 2013 09:03:06 -0800, Eli Bendersky wrote: > On Mon, Feb 25, 2013 at 8:56 AM, Antoine Pitrou wrote: > > > Le Mon, 25 Feb 2013 10:44:33 -0600, > > Skip Montanaro a écrit : > > > > Besides "we just don't need them int-based in these use-cases" what > > > > are the reasons for the s

Re: [Python-Dev] cffi in stdlib

2013-02-26 Thread R. David Murray
On Tue, 26 Feb 2013 18:14:26 +, Paul Moore wrote: > BTW, I assume that the intention is that both cffi and ctypes remain > available indefinitely? Nobody's looking to deprecate ctypes? I would expect that ctypes would be deprecated eventually simply because there aren't very many people inter

Re: [Python-Dev] Introducing Electronic Contributor Agreements

2013-03-05 Thread R. David Murray
On Tue, 05 Mar 2013 15:22:07 -0500, Brett Cannon wrote: > On Tue, Mar 5, 2013 at 11:48 AM, Baptiste Carvello < > de...@baptiste-carvello.net> wrote: > > > Le 05/03/2013 04:13, Stephen J. Turnbull a écrit : > > > Mark Lawrence writes: > > > > > > > People already use the bug tracker as an excuse

Re: [Python-Dev] Difference in RE between 3.2 and 3.3 (or Aaron Swartz memorial)

2013-03-06 Thread R. David Murray
On Wed, 06 Mar 2013 14:09:54 +0100, =?UTF-8?Q?Mat=C4=9Bj?= Cepl wrote: > So, in the end, I have went the long way and bisected cpython to > find the commit which broke my tests, and it seems that the > culprit is http://hg.python.org/cpython/rev/123f2dc08b3e so it is > clearly something Unicod

Re: [Python-Dev] FileCookieJars

2013-03-10 Thread R. David Murray
On Sat, 09 Mar 2013 12:13:54 +1100, Steven D'Aprano wrote: > On 02/03/13 02:43, Demian Brecht wrote: > > Cross-posting from python-ideas due to no response there. Perhaps it's > > due to a general lack of usage/caring for cookiejar, but figured > > /someone/'s got to have an opinion about my propo

Re: [Python-Dev] FileCookieJars

2013-03-11 Thread R. David Murray
On Sun, 10 Mar 2013 22:46:26 -0700, Demian Brecht wrote: > On 2013-03-10 1:59 PM, R. David Murray wrote: > I was hoping that there would be a little more interest (and potentially > some further historical context on why the module was implemented as it > was) from those in th

Re: [Python-Dev] [Python-checkins] cpython: #15927: Fix cvs.reader parsing of escaped \r\n with quoting off.

2013-03-19 Thread R. David Murray
On Wed, 20 Mar 2013 03:16:53 -, =?utf-8?B?S3Jpc3Rqw6FuIFZhbHVyIErDs25zc29u?= wrote: > The compiler complains about this line: > if (c == '\n' | c=='\r') { > > Perhaps you wanted a Boolean operator? Indeed, yes. --David __

Re: [Python-Dev] IDLE in the stdlib

2013-03-20 Thread R. David Murray
On Wed, 20 Mar 2013 09:41:53 -0700, Eli Bendersky wrote: > Personally, I think that IDLE reflects badly on Python in more ways than > one. It's badly maintained, quirky and ugly. It serves a very narrow set of > uses, and does it badly. > > Being part of Python *distributions* and being part of c

Re: [Python-Dev] [Python-checkins] cpython: Issue #13248: removed deprecated and undocumented difflib.isbjunk, isbpopular.

2013-03-20 Thread R. David Murray
On Wed, 20 Mar 2013 05:23:43 -0700, Eli Bendersky wrote: > A mention in Misc/NEWS can't hurt here, Terry. Even though it's > undocumented, some old code could rely on it being there and this code will > break with the transition to 3.4 Note that we also have a list of deprecated things that were

Re: [Python-Dev] PyCon Sprints - Thank you

2013-03-20 Thread R. David Murray
Thank you for your contributions, and we look forward to anything else you may choose to contribute! --David ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman

Re: [Python-Dev] cpython: Issue #13248: removed deprecated and undocumented difflib.isbjunk, isbpopular.

2013-03-21 Thread R. David Murray
On Thu, 21 Mar 2013 01:19:42 -0400, Terry Reedy wrote: > On 3/20/2013 2:13 PM, R. David Murray wrote: > > On Wed, 20 Mar 2013 05:23:43 -0700, Eli Bendersky wrote: > >> A mention in Misc/NEWS can't hurt here, Terry. Even though it's > >> undocumented, some

Re: [Python-Dev] Can we triple quoted string as a comment?

2013-03-26 Thread R. David Murray
On Mon, 25 Mar 2013 18:16:47 -0700, Raymond Hettinger wrote: > If you're editing with Emacs, it is really easy to reflow paragraphs > and to insert or remove multiline comments each prefixed with #. > But with other editors, it can be a PITA and a multiline string is > the easiest to maintain and

Re: [Python-Dev] noob contributions to unit tests

2013-03-26 Thread R. David Murray
On Tue, 26 Mar 2013 16:59:06 -0700, Maciej Fijalkowski wrote: > On Tue, Mar 26, 2013 at 4:49 PM, Sean Felipe Wolfe > wrote: > > Hey everybody how are you all :) > > > > I am an intermediate-level python coder looking to get help out. I've > > been reading over the dev guide about helping increas

Re: [Python-Dev] A bit about the GIL

2013-03-31 Thread R. David Murray
On Mon, 01 Apr 2013 01:14:11 +0200, =?UTF-8?Q?Alfredo_Solano_Mart=C3=ADnez?= wrote: > Simply put, make the reference counter a sharded one. That is, separate it > into several subcounters, in this case one for each thread. It seems to me this has a family resemblance to some of the stuff Trent i

Re: [Python-Dev] Is file.readlines(sizehint=N) broken on 2.7?

2013-04-05 Thread R. David Murray
On Fri, 05 Apr 2013 20:24:43 +0200, =?ISO-8859-1?Q?Giampaolo_Rodol=E0?= wrote: > 2013/4/5 INADA Naoki : > > The builtin open() was replaced with io.open(). > > It's difference between file.readlines() and io.IOBase.readlines(). > > Should that justify this difference in behavior? Yes. The 'fil

Re: [Python-Dev] The end of 2.7

2013-04-07 Thread R. David Murray
On Mon, 08 Apr 2013 00:25:12 +0900, "Stephen J. Turnbull" wrote: > 2.x's EOL was discussed in the past (the thread about "why no 2.8?"), > and what we observe is nobody coming forward to maintain Python 2 for > the fun of it. People not only work on Python 3 for the fun of it, > but they even po

Re: [Python-Dev] The end of 2.7

2013-04-07 Thread R. David Murray
On Sun, 07 Apr 2013 11:48:28 -0400, "R. David Murray" wrote: > (much more if the fix doesn't apply cleanly), and I find myself more and > more likely to say "well, it's been that way in Python2 for a long while, > fixing it there is more likely to break things

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-12 Thread R. David Murray
On Fri, 12 Apr 2013 05:55:00 -0700, Eli Bendersky wrote: > Link to the PEP: http://www.python.org/dev/peps/pep-0435/ [it's also pasted > fully below for convenience]. This looks great. There's just one bit I don't understand. I'm sure it was discussed in the python-ideas thread, but the discuss

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-12 Thread R. David Murray
On Fri, 12 Apr 2013 10:19:29 -0400, Davis Silverman wrote: > I think the reason they are not supporting __lt__, __gt__,etc. is because > ints are optional values for enums, therefore it wouldnt be a good idea to > compare enums of different types in that way. > > example: > > >>>class MyEnum(En

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-12 Thread R. David Murray
On Fri, 12 Apr 2013 10:50:44 -0400, Barry Warsaw wrote: > Nick brought this up in private email, and my response was basically that > iteration order for Enums should not be guaranteed, even if that happens to > work in the current implementation. The reason why it works in the current > implemen

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-12 Thread R. David Murray
On Fri, 12 Apr 2013 11:02:54 -0400, Barry Warsaw wrote: > On Apr 12, 2013, at 03:31 PM, Dirkjan Ochtman wrote: > >On Fri, Apr 12, 2013 at 2:55 PM, Eli Bendersky wrote: > >> >>> Colors.blue >= Colors.green > >> Traceback (most recent call last): > >> ... > >> NotImplementedError >

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-12 Thread R. David Murray
On Fri, 12 Apr 2013 15:33:02 -0400, Barry Warsaw wrote: > On Apr 12, 2013, at 11:21 AM, Russell E. Owen wrote: > > >I, too, would strongly prefer to see ordering within an enum. I use > >home-made enums heavily in my code and find ordering comparisons useful > >there. > > This was all hashed o

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-12 Thread R. David Murray
On Fri, 12 Apr 2013 14:06:55 -0700, Eli Bendersky wrote: > I actually think that having values with different types within a single > Enum is conceptually wrong and should be disallowed at creation time. With > enums, you either care or don't care about their actual value. If you don't > care (the

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-12 Thread R. David Murray
On Fri, 12 Apr 2013 18:35:58 -0400, Barry Warsaw wrote: > On Apr 12, 2013, at 05:17 PM, R. David Murray wrote: > > >Now, you could *further* require that the type of enum values be > >sortablebut that point you really have no excuse for not allowing > >enum values to

Re: [Python-Dev] mimetypes broken on Windows

2013-04-16 Thread R. David Murray
On Tue, 16 Apr 2013 14:00:53 -0400, Terry Jan Reedy wrote: > On 4/15/2013 10:04 PM, Ben Hoyt wrote: > > So my proposal is simply to get rid of read_windows_registry() > > altogether, and fall back to the default type mapping in mimetypes.py on > > Windows systems. This is correct and fast, even if

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-20 Thread R. David Murray
On Sat, 20 Apr 2013 14:10:32 -0400, Barry Warsaw wrote: > On Apr 13, 2013, at 08:37 AM, Tim Delaney wrote: > > >Just using definition order as the stable iteration order would do the > >trick - no need for any comparisons at all. Subclasses (e.g. IntEnum) can > >then override it. > > I think thi

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-20 Thread R. David Murray
On Sun, 21 Apr 2013 08:34:39 +1000, Tim Delaney wrote: > On 21 April 2013 04:10, Barry Warsaw wrote: > > > On Apr 13, 2013, at 08:37 AM, Tim Delaney wrote: > > > > >Just using definition order as the stable iteration order would do the > > >trick - no need for any comparisons at all. Subclasses

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-21 Thread R. David Murray
On Sun, 21 Apr 2013 20:28:16 -0400, Barry Warsaw wrote: > On Apr 22, 2013, at 09:02 AM, Nick Coghlan wrote: > > >Iteration order matters a lot if you don't want people complaining about > >enums being broken: > > > > class Days(enum.Enum): > >Monday = 1 > >Tuesday = 2 > >Wednesday =

Re: [Python-Dev] Why can't I encode/decode base64 without importing a module?

2013-04-22 Thread R. David Murray
On Mon, 22 Apr 2013 09:50:14 -0400, Devin Jeanpierre wrote: > On Mon, Apr 22, 2013 at 7:39 AM, Calvin Spealman wrote: > > if two lines is cumbersome, you're in for a cumbersome life a programmer. > > Other encodings are either missing completely from the stdlib, or have > corrupted behavior. Fo

Re: [Python-Dev] Why can't I encode/decode base64 without importing a module?

2013-04-22 Thread R. David Murray
On Tue, 23 Apr 2013 11:16:20 +1200, Greg Ewing wrote: > Victor Stinner wrote: > > The last proposition is to add transform() and untransform() methods > > to bytes and str types. ... If I remember > > correctly, the missing point is how to define which types are > > supported by a codec > > Also

Re: [Python-Dev] Why can't I encode/decode base64 without importing a module?

2013-04-23 Thread R. David Murray
On Tue, 23 Apr 2013 22:29:33 +0900, "Stephen J. Turnbull" wrote: > R. David Murray writes: > > > You transform *into* the encoding, and untransform *out* of the > > encoding. Do you have an example where that would be ambiguous? > > In the bytes-to

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-23 Thread R. David Murray
On Tue, 23 Apr 2013 15:44:58 +0200, Antoine Pitrou wrote: > Le Fri, 12 Apr 2013 05:55:00 -0700, > Eli Bendersky a écrit : > > > > We're happy to present the revised PEP 435, collecting valuable > > feedback from python-ideas discussions as well as in-person > > discussions and decisions made du

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-23 Thread R. David Murray
On Tue, 23 Apr 2013 16:33:02 +0200, Antoine Pitrou wrote: > Le Tue, 23 Apr 2013 10:24:18 -0400, > "R. David Murray" a écrit : > > > > > > I'm having a problem with the proposed implementation. I haven't > > > found any mention of it,

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-23 Thread R. David Murray
On Tue, 23 Apr 2013 08:11:06 -0700, Guido van Rossum wrote: > I gotta say, I'm with Antoine here. It's pretty natural (also coming > from other languages) to assume that the class used to define the > enums is also the type of the enum values. Certainly this is how it > works in Java and C++, and

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-23 Thread R. David Murray
On Tue, 23 Apr 2013 08:44:21 -0700, Guido van Rossum wrote: > On Tue, Apr 23, 2013 at 8:31 AM, R. David Murray > wrote: > > On Tue, 23 Apr 2013 08:11:06 -0700, Guido van Rossum > > wrote: > >> I gotta say, I'm with Antoine here. It's pretty natural (also

Re: [Python-Dev] Why can't I encode/decode base64 without importing a module?

2013-04-23 Thread R. David Murray
On Wed, 24 Apr 2013 01:49:39 +0900, "Stephen J. Turnbull" wrote: > R. David Murray writes: > > On Tue, 23 Apr 2013 22:29:33 +0900, "Stephen J. Turnbull" > wrote: > > > R. David Murray writes: > > > > > > > You transform *into*

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-23 Thread R. David Murray
On Wed, 24 Apr 2013 11:37:16 +1200, Greg Ewing wrote: > R. David Murray wrote: > > The first False looks correct to me, I would not expect an enum value to > > be an instance of the class that holds it as an attribute. The second > > certainly looks odd, but what does it

Re: [Python-Dev] slow hg clone of python repo?

2013-04-24 Thread R. David Murray
On Wed, 24 Apr 2013 18:14:18 -0700, Eli Bendersky wrote: > On Wed, Apr 24, 2013 at 4:37 PM, Sean Felipe Wolfe wrote: > > > On Wed, Apr 24, 2013 at 4:24 PM, Guido van Rossum > > wrote: > > > It's a big repo. Patience. > > > > > > On Wed, Apr 24, 2013 at 4:17 PM, Sean Felipe Wolfe > > wrote: > >

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-25 Thread R. David Murray
On Thu, 25 Apr 2013 14:37:29 -0700, Ethan Furman wrote: > On 04/25/2013 02:25 PM, Eli Bendersky wrote: > > On Thu, Apr 25, 2013 at 2:17 PM, Barry Warsaw > > wrote: > >> On Apr 25, 2013, at 01:18 PM, Ethan Furman wrote: > > > >>> For me, the getitem syntax on a class seems

Re: [Python-Dev] PEP 368

2013-05-10 Thread R. David Murray
On Fri, 10 May 2013 17:14:21 +1000, Nick Coghlan wrote: > S 368 Standard image protocol and class > Mastrodomenico I haven't read through it in detail yet, but this PEP looks interesting in the context of the further enhancements planned for the email module (ie: a MIME

Re: [Python-Dev] Purpose of Doctests [Was: Best practices for Enum]

2013-05-20 Thread R. David Murray
On Mon, 20 May 2013 12:45:57 +0200, Antoine Pitrou wrote: > On Sat, 18 May 2013 23:41:59 -0700 > Raymond Hettinger wrote: > > > > We should continue to encourage users to make thorough unit tests > > and to leave doctests for documentation. That said, it should be > > recognized that some testi

Re: [Python-Dev] Why is documentation not inline?

2013-05-20 Thread R. David Murray
On Mon, 20 May 2013 15:02:08 +0200, Stefan Drees wrote: > On 20.05.13 14:37, Serhiy Storchaka wrote: > > 20.05.13 01:33, Benjamin Peterson написав(ла): > >> 2013/5/19 Demian Brecht : > >>> It seems like external docs is standard throughout the stdlib. Is > >>> there an actual reason for t

Re: [Python-Dev] PEP 409 and the stdlib

2013-05-20 Thread R. David Murray
On Mon, 20 May 2013 06:12:41 -0700, Ethan Furman wrote: > As a quick reminder, PEP 409 allows this: > > try: > ... > except AnError: > raise SomeOtherError from None > > so that if the exception is not caught, we get the traditional single > exception traceback, inst

Re: [Python-Dev] Purpose of Doctests [Was: Best practices for Enum]

2013-05-20 Thread R. David Murray
On Mon, 20 May 2013 15:57:35 +0200, Antoine Pitrou wrote: > On Mon, 20 May 2013 09:37:32 -0400 > "R. David Murray" wrote: > > On Mon, 20 May 2013 12:45:57 +0200, Antoine Pitrou > > wrote: > > > On Sat, 18 May 2013 23:41:59 -0700 > > > Raymon

Re: [Python-Dev] PEP 409 and the stdlib

2013-05-20 Thread R. David Murray
On Mon, 20 May 2013 07:12:07 -0700, Ethan Furman wrote: > As a case in point, base64.py is currently getting a bug fix, and also > contains this code: > > def b32decode(s, casefold=False, map01=None): > . > . > . > for i in range(0, len(s), 8): > quanta = s[i: i + 8]

<    1   2   3   4   5   6   7   8   9   10   >