l.python.org/mailman/listinfo/python-list or
> comp.lang.python on Usenet).
I'm not sure whether the speed list is still active. I'd personally try
python-...@python.org or the python-dev section on discuss.python.org. (Full
disclosure: I have see
.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/B6YJ6DNHYJ3PHMCXYROT7ZILFXYGCSRR/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido (mobile)
___
Python-ideas mailing list -- py
hon-ideas mailing list -- python-ideas@python.org
>> To unsubscribe send an email to python-ideas-le...@python.org
>> https://mail.python.org/mailman3/lists/python-ideas.python.org/
>> Message archived at
>> https://mail.python.org/archives/list/python-ideas@python.org/messa
> ___
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.or
as.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/HQI3ULA6ZAYEHU7JMKZYLLTAG2IFWIVI/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido (mobile)
___
Python-ideas mailing list -
x27;ll get an obvious IndexError when you hit a late-bound
> default, so even a basic adjustment will still be safe. By your
> method, unless something is aware of late defaults, it will subtly get
> things wrong.
>
> ChrisA
> ___
> Python-
gt; https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/4OHZ6QZWDI3U2ADI5A36UU73OOXFOGJE/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido van Rossum (python.org/~g
Oct 25, 2021 at 10:49 AM Chris Angelico wrote:
> On Tue, Oct 26, 2021 at 4:36 AM Guido van Rossum wrote:
> >
> > On Mon, Oct 25, 2021 at 10:28 AM Chris Angelico
> wrote:
> >>
> >> [...] The two options on the table are:
> >>
> >> 1) Allow re
reaking
new ground. Everywhere else in Python, undefined names are runtime errors
(NameError or UnboundLocalError).
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing.com/2015/02/03/how-using
er's
scope. It's no different than a function defined in the caller. I don't
think it would be a good substitute for late-binding default arguments.
(You could make something up that uses dynamic scoping, but that's a whole
different can of worms.)
--
--Guido van Rossum (p
; a, b = 3, 5
> > fn2(defer: x) # look for local a, b within fn2() if needed
> > # ... other stuff
> > return x # return 8 here
> >
>
> How would it know to look for a and b inside fn2's scope, instead of
> looking for x inside fn2's scope?
I like that you're trying to fix this wart! I think that using a different
syntax may be the only way out. My own bikeshed color to try would be `=>`,
assuming we'll introduce `(x) => x+1` as the new lambda syntax, but I can
see problems with both as well :-).
--
--Guido van Ro
efinitely not dead (as you seemed to imply).
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing.com/2015/02/03/how-using-they-as-a-singular-pronoun-can-change-the-world/>
___
Python-ideas mailing list -
r lists because unlike lists the over-allocation isn't permanent."
Finally, the bytecode generated for (*a, *b) creates a list first and then
turns that into a tuple (which will be allocated with the right size since
it's known at that point).
--
--Guido van Rossum (python.org/~gui
re
> involving both unpacking and comprehensions.
>
> Erik
> --
> Erik Demaine | edema...@mit.edu | http://erikdemaine.org/
> _______
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le
r advantage is purposefully linking variables names within python to
> names outside, making it easier to refactor and easier to trace usage
> across
> an entire service and across different environments.
>
> For the other use, in factory functions, I believe we have just come to
> a
lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/UGRD4QCDGRPOOCDMLPZ7EXWJFKM22AGO/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is
I would also like to remind various other posters that sarcasm is *not* a
good way to welcome newbies. The name of the list is python-ideas, not
python-ideas-to-shoot-down-sarcastically.
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing
) time.
Though what happens to the dense array when a key is deleted? It must leave
a gap there too. So, never mind, you’d have to walk through the array
counting items but not gaps, and that’s O(n). Which explains why we don’t
have such an API. But please check the C code!
—Guido
On Sun, Oct 10
it's a dumb idea :-)
>
At the very least it might lead to a recommendation based on which
operation is implemented most efficiently. Though you should just measure
it for various N.
Are you actually observing that people are doing this with regular lists?
Don't people working with Big
t; To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/K6ZOKOHBJQLCRDDWARTIPYGZB3IN25SG/
> Code of Conduct: http://pytho
e within the Groovy community, also used by
> projects such as `Spock`_.
>
> On top of that, it is very much needed in the Python community as well:
>
> * `Power Assertion was explicitly requested`_ as a feature in the
> `Nimoy`_ testing framework
> * There's a `
On Sat, Sep 25, 2021 at 00:56 Steven D'Aprano wrote:
> On Fri, Sep 24, 2021 at 11:23:00PM -0700, Guido van Rossum wrote:
>
> > > Is there no room for making it easier to do this with less invasive
> > > changes to the stdlib, or are Steven d'A's "
On Fri, Sep 24, 2021 at 22:07 Stephen J. Turnbull <
stephenjturnb...@gmail.com> wrote:
> Guido van Rossum writes:
>
> > I think this is by far the best option. Pytest can evolve much faster
> than
> > the stdlib.
>
> Is there no room for making it easier to do
faster than
the stdlib.
—Guido
> --
--Guido (mobile)
___
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message arc
yping-sig archives to learn more about the current
status:
https://mail.python.org/archives/list/typing-...@python.org/
--Guido
On Wed, Sep 22, 2021 at 1:04 AM Randolf Scholz
wrote:
> @Valentin Berlier
>
> That would probably be possible, but the question here is, given that
> `Callab
Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/U5UQFDAJ4KW
For the stdlib context managers that I know of, all-lowercase seems the
convention. Would it even be a class? The simplest implementation would use
contextlib.contextmanager (unless that’s a undesirable dependency for
os.py).
—Guido
On Tue, Sep 14, 2021 at 17:53 Finn Mason wrote:
> BTW, sho
7;d file a bug. :-)
"Bug magnet" is an extremely subjective pejorative term. When the *better*
way to do things (os.workdir()) is harder than the *easy* way to do
(os.chdir()), which is the real bug magnet?
--
--Guido van Rossum (python.org/
t;
> All that said, I wrote pretty much exactly what you describe just the
> other week for umask().
>
> Cheers,
> Cameron Simpson
> ___
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to pyth
Maybe you all could collaborate on a PEP? This sounds a worthy topic.
On Sun, Sep 12, 2021 at 08:37 Serhiy Storchaka wrote:
> 12.09.21 17:28, Guido van Rossum пише:
> > This is cool.
> >
> > AFAIK pytest does something like this. How does your implementation
> differ?
not want to incur the extra
cost.
—Guido
On Sun, Sep 12, 2021 at 07:09 wrote:
> Hi all,
>
> I’d like your comments and feedback on an enhancement that introduces
> power assertions to the Python language.
>
> Proposal
>
> This feature is inspired by a simil
that eventually the raise= keyword can become optional.
—Guido
On Thu, Sep 9, 2021 at 09:04 Juancarlo Añez wrote:
> Steven,
>
> The purpose is to make it easier to make software more resilient.
>
> The inspiration was this article that reminded me that software *_will
> alway
scipy, Cython
> ___
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> http
On Mon, Sep 6, 2021 at 21:45 Christopher Barker wrote:
> Just use pytest.
>
For third party code I agree, it’s the way to go.
—Guido
--
--Guido (mobile)
___
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to
On Fri, Sep 3, 2021 at 5:37 PM Christopher Barker
wrote:
> On Fri, Sep 3, 2021 at 1:13 PM Guido van Rossum wrote:
>
>> But the text of the error message will explain all you need for debugging
>> and testing.
>>
>
> debugging, probably yes.
>
> But it'
On Fri, Sep 3, 2021 at 5:04 PM Oscar Benjamin
wrote:
> On Fri, 3 Sept 2021 at 17:32, Guido van Rossum wrote:
> >
> > On Fri, Sep 3, 2021 at 4:24 AM Oscar Benjamin <
> oscar.j.benja...@gmail.com> wrote:
> >>
> >> On Fri, 3 Sept 2021 at 08:10, Serhiy S
But the text of the error message will explain all you need for debugging
and testing.
On Fri, Sep 3, 2021 at 10:08 AM Christopher Barker
wrote:
>
>
> On Fri, Sep 3, 2021 at 9:35 AM Guido van Rossum wrote:
>
>> The question is, would anyone ever want to make a distinction bet
deas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/3CLXFC52JIBCFXMXRFA5I6
My conclusion is that you should ignore PEP 8 for your use case and write
“if len(a) == 0”.
On Wed, Aug 25, 2021 at 06:13 Tim Hoffmann via Python-ideas <
python-ideas@python.org> wrote:
> Guido van Rossum wrote:
> > So then the next question is, what's the use case?
___
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/ar
“Container” is a kind of pun, it’s something with a __contains__ method.
The thing you’re looking for is “Collection”, which is the base for
sequences, mappings and sets.
I also note that the discussion seems quite stuck.
—Guido
On Tue, Aug 24, 2021 at 21:55 Christopher Barker
wrote:
>
On Tue, Aug 24, 2021 at 7:23 PM MRAB wrote:
> On 2021-08-25 00:48, Guido van Rossum wrote:
> > Hi Tim,
> >
> > I'm sorry if this has been brought up before, but *aside from PEP 8* is
> > there anything wrong with using "if len(a)" for nonempty, or "
archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/LRK6HHQKBH2Y4USB7DAJNOUF5NE62ZYD/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing.com
efault?
>
>
> --
> Steve
> ___
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message ar
, 2021 at 14:28 Paul Prescod wrote:
> On Thu, Aug 19, 2021 at 8:43 AM Guido van Rossum wrote:
>
>> Perhaps we need a library for creating/managing threads that inherits all
>> current context values?
>>
>
> Or is it a "kind of context variable that is shared
Z6WDWVJI7QEJKICJZN72B5FYOEV/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing.com/2015/02/03/how-using-they-as-a-singular-pronoun-can-change-the-world/>
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/VYZOMTCNSSAJNAYHRE5A5BJUMACY57SF/
> Code of Conduct: http
on-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/V2WFMNVJLUBXVQFPNHH4TJNRYNPK2
deas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/2SYIBL275IIHMSPAT6J4K3TIA7HXEKV5/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--G
f the evaluation is relatively expensive and may never be
needed, e.g. for logging at a level that is off in production. We can
debate whether it's better to mark individual substitutions with something
like {:...} or whether we should mark the template as a whole (obviously
the marking must be u
n
argument for backticks.
Separately, should there be a way to *delay* evaluation of the templated
expressions (like we explored in our private little prototype last year)?
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing.com/2015/02
On Fri, Jun 25, 2021 at 12:17 PM Christian Heimes
wrote:
> On 25/06/2021 20.17, Guido van Rossum wrote:
> > On Fri, Jun 25, 2021 at 8:22 AM Bluenix > <mailto:bluenix...@gmail.com>> wrote:
> >
> > I am not fully aware of how ssl.SSLContext is used, but addin
On Fri, Jun 25, 2021 at 11:42 AM Chris Angelico wrote:
> On Sat, Jun 26, 2021 at 4:20 AM Guido van Rossum wrote:
> >
> > On Fri, Jun 25, 2021 at 8:22 AM Bluenix wrote:
> >>
> >> I am not fully aware of how ssl.SSLContext is used, but adding
> __slots__
that could well become a non-trivial change to their code,
depending on where they get their SSLContext instances.)
So unless there's evidence that nobody does that, we're stuck with the
status quo. I'm adding Christian Heimes to the thread in case he has a
hunch either way.
--
--Gu
unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/RPD5OICSY3KLVXKIYWFTABNIA7F7YWG3/
> Code of Conduct: ht
On Fri, Jun 18, 2021 at 10:15 PM Steven D'Aprano
wrote:
> On Fri, Jun 18, 2021 at 09:33:49PM -0700, Guido van Rossum wrote:
>
> > Now, this shouldn't be considered an airtight argument against [*chunk
> for
> > ...], but it does show that there's no straightfo
On Fri, Jun 18, 2021 at 8:40 PM Steven D'Aprano wrote:
> On Fri, Jun 18, 2021 at 07:38:49AM -0700, Guido van Rossum wrote:
>
> > Note the ambiguity around whether the user might have meant
> >
> > [x,(y for y in a)]
> >
> > or
> >
> >
[x,(y for y in a)]
or
[(x, y) for y in a]
That’s a good enough reason for me to also disallow *chunks.
--
--Guido (mobile)
___
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@p
s@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/YH7COSZIV5BWQ3EOEA5MQMBHMB3OQNND/
> Code of Condu
ython-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/2T53ADB3TVQJF2UENEXKB5G5ZWTQOQVW/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
Python). Van Wijngaarden told us, somewhat ruefully, that, had the design
committee known that programmers would be happy to write that empty pair of
parentheses, they would have been able to simplify a significant corner of
Algol-68's type system.
This was one of the seminal ideas that went i
On Fri, Jun 4, 2021 at 3:08 PM Thomas Güttler
wrote:
>
>
> Am Fr., 4. Juni 2021 um 19:20 Uhr schrieb Guido van Rossum <
> gu...@python.org>:
>
>> PEP 501 is unlikely to be accepted *as is*. But it’s still a good
>> starting point.
>>
>>
> OK, bef
, Jun 4, 2021 at 07:24 Matt del Valle wrote:
> Interpolation templates were recently brought up here (
> https://mail.python.org/archives/list/python-ideas@python.org/thread/5AW73ICBD4CVCRUNISRNAERPPF2KSOGZ/),
> and Guido mentioned that in his opinion the SC would be unlikely to
> re
>> ___
>> Python-ideas mailing list -- python-ideas@python.org
>> To unsubscribe send an email to python-ideas-le...@python.org
>> https://mail.python.org/mailman3/lists/python-ideas.python.org/
>> Message archived at
>> htt
eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48
>> > D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg
>> > Registered at Amtsgericht Duesseldorf: HRB 46611
>> >https://www.egenix.com/company/c
Oh no, not the vertical bar hack. :-(
___
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at
https://mail.
t; (two/five)
> 0.4
> >>> (two/five).numerator
> Traceback (most recent call last):
> File "", line 1, in
> AttributeError: 'float' object has no attribute 'numerator'
>
This violates a basic property of Python. If 1/2 has a
digits of precision upon printing. This could be easily fixed by starting
an addition with an inexact zero, but this was often non-intuitive and hard
to debug for beginners.
"""
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://fem
e of commas and 'as' is different than the proposal here:
import foo.bar as foobar, bar.foo as barfoo
is parsed as
import (foo.bar as foobar), (bar.foo as barfoo)
Similarly,
with something as foo, something_else as bar:
...
is parsed as
with (something as foo), (something_
_
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archiv
ed symbols is just one avenue to prevent disappointment in the future.
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing.com/2015/02/03/how-using-they-as-a-singular-pronoun-can-change-the-world/>
org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/ASBHWYDCPR3D2FCVLGPHELPRJUJOWHLL/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido (mobile)
_
nd it will
> conflict with your idea.
>
> ___
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.pytho
here. So o.m(f()) needs to evaluate o.m (which may have a side
effect if o overrides __getattr__) before it calls f().
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing.com/2015/02/03/how-usin
isA
> ___
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.org/mailman3/lists/python-ideas.python.org/
> Message archived at
> https://mail.python.org/arch
s
proto-PEP (since it explicitly mentions registers). A version of the
example that exhibits the same questionable behavior would be this:
return create_pipeline()[-1].wait()
Presumably this would not work correctly with the PyQt5 process class.
--
--Guido van Rossum (python.org/~guido)
*Pro
-ideas@python.org/message/C7UQTGKJCSHBMIXGRMRDSZJOL3LLQF2Q/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido (mobile)
___
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.o
C(a, c, b=_,
d=_)` except it doesn't even care whether b and d are set at all.
On Tue, Mar 16, 2021 at 1:36 PM Eric V. Smith wrote:
> And now I have a question for you, Guido.
>
> I'm looking at the code and I see the additions for __match_args__. Is
> there any bad inte
with a comma is most
definitely not something one would do in English.
I hope to see you continue brainstorming on other ideas.
--Guido
On Fri, Mar 12, 2021 at 5:21 AM roland.puntaier--- via Python-ideas <
python-ideas@python.org> wrote:
> I had posted this as https://github.com/pytho
e` as just `None`, as we desire. And instead
> of being a `__contains__` with unusual semantics coupled with a constructor
> with unusual semantics, it's a pair of class methods that each have fairly
> unsurprising semantics.
>
> ~Matt
>
> On Mon, Mar 15, 2021 at 3:55 PM Gui
gt; field saying what type of __init__ argument it becomes: normal or
> keyword-only. Any of the 3 methods discussed above (kw_only flag to
> @dataclass(), kw_only flag to field(), or the KW_ONLY marker) all have
> the same result: setting the kw_only flag on one or more fields.
>
&g
+1
On Mon, Mar 15, 2021 at 12:48 PM Ethan Furman wrote:
> On 3/15/21 11:27 AM, Guido van Rossum wrote:
> > On Mon, Mar 15, 2021 at 10:53 AM Ethan Furman wrote:
>
> >> Part of the reason is that there are really two ways to identify an
> >> enum -- by name
On Mon, Mar 15, 2021 at 10:53 AM Ethan Furman wrote:
> On 3/12/21 5:28 PM, Guido van Rossum wrote:
> > On Fri, Mar 12, 2021 at 1:52 PM Ethan Furman wrote:
>
> >> A question that comes up quite a bit on Stackoverflow is how to test
> >> to see if a value will result
Hi Steve,
I don't think I can explain adequately why I challenged you, so I'll just
apologize. Your feedback (about the 'export' proposal, and about my
challenge of your credentials) is duly noted. Sorry!
--Guido
On Sun, Mar 14, 2021 at 4:11 PM Stestagg wrote:
> On Su
hat they implement their own
restrictive access controls (without resorting to writing C code).
On Sun, Mar 14, 2021 at 12:42 PM Stestagg wrote:
> On Sun, 14 Mar 2021 at 18:58, Guido van Rossum wrote:
>
>> On Sun, Mar 14, 2021 at 7:11 AM Theia Vogel wrote:
>>
>>> >
wrap
`Y` in another proxy, and then it becomes awkward, e.g. if `Y` is supposed
to represent a simple number or string -- we don't want any other part of
the language or stdlib to need to become aware of such proxies.)
Long answer short, yes, we can make it so that `the_module.sys` in your
On Fri, Mar 12, 2021 at 6:23 PM Peter Ludemann
wrote:
> [I wonder why C didn't adopt BCPL's convention for eliding semi-colons?
> ...]
>
[Presumably because it caused too many surprising behaviors...]
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why
x = 1
> y = 2
> export y
>
> # __all__ == ["y"]
>
>
> # Big Caveat
>
> For this scheme to work, __all__ needs to not be auto-populated with names.
> While the behavior is possibly suprising, I think the best way to handle
> t
> 2) add a recipe to the docs
>
But what would the recipe say? Apparently you're looking for a one-liner,
since you reject the try/except solution.
> 3) do nothing
>
Always a good option. :-) Where's that StackOverflow item? How many upvotes
does it have?
--
--Gui
essage archived at
> https://mail.python.org/archives/list/python-ideas@python.org/message/LWB3U5BTGC4CT26U4AB676SKGED3ZOEX/
> > Code of Conduct: http://python.org/psf/codeofconduct/
>
> ___
> Python-ideas mailing list -- python-idea
t; before. Feel free to point me to it if I've missed anything.
>
> Cheers,
> Matt
> ___
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email to python-ideas-le...@python.org
> https://mail.python.or
list/python-ideas@python.org/message/KPVB2G64BHFGGOTXZQXT3AU7SIO5ABJE/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://femini
27;t promise to review it though.
:-)
--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing.com/2015/02/03/how-using-they-as-a-singular-pronoun-can-change-the-world/>
___
Python-ideas mailing list -- pytho
d at
> https://mail.python.org/archives/list/python-ideas@python.org/message/6HLSLQMMKYNLSEQCIIDVKXIGV2TZFREE/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
--Guido (mobile)
___
Python-ideas mailing list -- python-ideas@pyt
acement for lambda, because many
other languages have jumped on the arrow bandwagon, and few Python
first-time programmers have enough of a CS background to recognize the
significance of the word lambda. But named functions? Why??
> But since Guido wants to save the right shaft operator for ty
hat is more readable, and supports extra
features that Callable doesn’t, like keyword args, varargs, and pos-only.
If you can do both with the same arrow, great, but if the arrows must
differ (for some technical reason, e.g. types in cast()), I want -> for
Callable, and you can have => for lam
I should add that I accidentally left out a word. It should be “... liable
to *overwrite* any or all names ...”
On Sun, Feb 14, 2021 at 12:10 Abdulla Al Kathiri <
alkathiri.abdu...@gmail.com> wrote:
> That makes sense. As Guido mentioned, this is similar to reusing a
> variable i
ther idea in how to prevent name binding due to partial matching from
> happening? Any previous discussions on this?
>
> Thanks,
>
> Abdulla
> ___
> Python-ideas mailing list -- python-ideas@python.org
> To unsubscribe send an email t
y be worth looking at what it would take to allow asynchronous
> lambdas. Syntactically, while "any lambda containing await" is tempting,
> the lack of static typing means that we need a way to specify async lambdas
> that do not contain await. Javascript prefixes the argument list wi
1 - 100 of 912 matches
Mail list logo