osdir.com


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Python-Dev] Examples for PEP 572


On Wed, 4 Jul 2018 at 07:42 Antoine Pitrou <solipsis at pitrou.net> wrote:

> On Wed, 4 Jul 2018 09:43:04 -0300
> Brett Cannon <brett at python.org> wrote:
> >
> > I think this is a very key point that the "this is bad" crowd is
> > overlooking. Even if this syntax turns out to not be that useful, abusing
> > the walrus operator can be fixed with a comment of "hard to follow;
> please
> > simplify" without teaching any new concepts or idioms
>
> The same could be said of any language mis-feature.  Do we want to
> claim that questionable semantics in Javascript and PHP are not a
> problem, because the bad constructs can simply be turned away in code
> review?
>
> That sounds like a modern re-phrasing of the old argument, """C is not
> dangerous in itself, it's only the fault of incompetent programmers""".
> Just replace "incompetent programmers" with "complacent reviewers"...
>

I would disagree as for some things understanding why it needs a change is
much easier than others. For instance saying that some use of := is too
convoluted and should be simplified needs much less explanation than other
things like why you should typically avoid staticmethod.

Or another way to view it, saying := is abused  in a review should be
universally understood while something else may require a more
Python-specific explanation and deeper knowledge.

Now none of this isn't to say we should take any idea regardless of
potential abuses and maintenance cost. But for me, I don't view this as
requiring any innate knowledge to cause people not to abuse it.


>
> > Another point is we live in a dictatorship by choice, and yet some people
> > seem very upset our dictator dictated in the end.
>
> Not sure what you mean with "by choice".


As in people choose to join this team knowing that Guido is the BDFL and
what that entails. Since none of us have to be here I view it as a choice
to be here.

-Brett


>   When I arrived here, I
> certainly wasn't asked whether I wanted the place to be a dictatorship
> or not ;-)  Granted, I did choose to come here, but not because of a
> personal appeal for dictatorship.
>
> One could claim that the qualities of Python are due to it being a
> dictatorship.  I think it's impossible to answer that question
> rigorously, and all we're left with is our personal feelings and biases
> on the subject.
>
> Regards
>
> Antoine.
>
>
> _______________________________________________
> Python-Dev mailing list
> Python-Dev at python.org
> https://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe:
> https://mail.python.org/mailman/options/python-dev/brett%40python.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20180706/4d22a410/attachment.html>