Re: [Python-Dev] What's the status of PEP 505: None-aware operators?

2017-12-01 Thread Steven D'Aprano
On Fri, Dec 01, 2017 at 08:24:05AM -0500, Random832 wrote: > On Fri, Dec 1, 2017, at 05:31, Steven D'Aprano wrote: > > I'm more confused than ever. You seem to be arguing that Python > > functions CAN short-circuit their arguments and avoid evaluating them. > > Is that the case? > > > If this is

Re: [Python-Dev] Third and hopefully final post: PEP 557, Data Classes

2017-12-01 Thread Eric V. Smith
See https://github.com/ericvsmith/dataclasses/issues/104 for a discussion on making order=False the default. This matches regular classes in Python 3, which cannot be ordered. Eric. ___ Python-Dev mailing list Python-Dev@python.org https://mail.python

Re: [Python-Dev] What's the status of PEP 505: None-aware operators?

2017-12-01 Thread MRAB
On 2017-12-01 13:24, Random832 wrote: On Fri, Dec 1, 2017, at 05:31, Steven D'Aprano wrote: I'm more confused than ever. You seem to be arguing that Python functions CAN short-circuit their arguments and avoid evaluating them. Is that the case? If this is merely about when the name "function"

Re: [Python-Dev] iso8601 parsing

2017-12-01 Thread Alexander Belopolsky
> is there a strict deadline here if we want this for Python 3.7? The deadline for the new features is the date of the first beta currently scheduled for 2018-01-29, but if you can get this in before the last alpha (2018-01-08) it will be best. See PEP 537 (https://www.python.org/dev/peps/pep-053

Re: [Python-Dev] What's the status of PEP 505: None-aware operators?

2017-12-01 Thread Eric Fahlgren
On Fri, Dec 1, 2017 at 5:24 AM, Random832 wrote: > You're completely missing the context of the discussion, which was the > supposed reason that a *new* function call operator, with the proposed > syntax function?(args), that would short-circuit (based on the > 'function' being None) could not be

Re: [Python-Dev] iso8601 parsing

2017-12-01 Thread Paul G
As an update, I have the C version done and basically tested as an extension (I "cheated" on the tests by using hypothesis, so I still need to write unittest-style tests), just writing the Python version with tests now. I know there is a feature freeze coming in soon, is there a strict deadline

Re: [Python-Dev] iso8601 parsing

2017-12-01 Thread Chris Barker
On Wed, Nov 29, 2017 at 4:19 PM, Paul G wrote: > I can write at least a pure Python implementation in the next few days, if > not a full C implementation. Shouldn't be too hard since I've got a few > different Cython implementations sitting around anyway. > > Thanks! -CHB > On November 29, 2

[Python-Dev] Summary of Python tracker Issues

2017-12-01 Thread Python tracker
ACTIVITY SUMMARY (2017-11-24 - 2017-12-01) Python tracker at https://bugs.python.org/ To view or respond to any of the issues listed below, click on the issue. Do NOT respond to this message. Issues counts and deltas: open6281 (+14) closed 37665 (+55) total 43946 (+69) Open issues wi

Re: [Python-Dev] What's the status of PEP 505: None-aware operators?

2017-12-01 Thread Andrea Griffini
The PEP says that a None-aware function call operator (e.g. "f?(x, y)") would break the rule of python that arguments are evaluated before the function but this is not correct. In Python the function is evaluated before the arguments (but of course the CALL is made after the evaluation of the argu

Re: [Python-Dev] Third and hopefully final post: PEP 557, Data Classes

2017-12-01 Thread Eric V. Smith
Since this is easy enough to do in your own code, and I still don't see a use case, I'll just add a note to the PEP and delete isdataclass(). Plus, you can decide for yourself how to deal with the question of returning true for classes or instances or both. I've updated the PEP and reposted i

Re: [Python-Dev] What's the status of PEP 505: None-aware operators?

2017-12-01 Thread Random832
On Fri, Dec 1, 2017, at 05:31, Steven D'Aprano wrote: > I'm more confused than ever. You seem to be arguing that Python > functions CAN short-circuit their arguments and avoid evaluating them. > Is that the case? > If this is merely about when the name "function" is looked up, then I > don't se

Re: [Python-Dev] What's the status of PEP 505: None-aware operators?

2017-12-01 Thread Steve Holden
On Fri, Dec 1, 2017 at 10:31 AM, Steven D'Aprano wrote: > On Thu, Nov 30, 2017 at 11:54:39PM -0500, Random832 wrote: > > > The OP isn't confusing anything; it's Eric who is confused. The quoted > > paragraph of the PEP clearly and unambiguously claims that the sequence > > is "arguments -> functi

Re: [Python-Dev] What's the status of PEP 505: None-aware operators?

2017-12-01 Thread Steven D'Aprano
On Thu, Nov 30, 2017 at 11:54:39PM -0500, Random832 wrote: > The OP isn't confusing anything; it's Eric who is confused. The quoted > paragraph of the PEP clearly and unambiguously claims that the sequence > is "arguments -> function -> call", meaning that something happens after > the "function"

Re: [Python-Dev] Third and hopefully final post: PEP 557, Data Classes

2017-12-01 Thread Eric V. Smith
On 11/30/2017 3:35 PM, Carl Meyer wrote: On 11/29/2017 05:02 PM, Guido van Rossum wrote: I tried to look up the discussion but didn't find much except that you flagged this as an issue. To repeat, your concern is that isdataclass() applies to *instances*, not classes, which is how Eric has desig