Martin Blais added the comment:
Well that just echoes exactly what I originally thought, but somebody else said
it was not needed because ExitStack already exists and could be used for that
purpose.
If this were at work and/or it were all just to me, I'd just implement a brand
Martin Blais added the comment:
Adding nullcontext = ExitStack in the source file would solve this problem in a
single line of code.
--
nosy: +blais
___
Python tracker
<http://bugs.python.org/issue10
Martin Blais added the comment:
I've been looking for this today; I would have used it.
Instead of an obvious (and explicit) null context manager, I had to read
through this entire thread to eventually find out that I can use something
called ExitStack(), which is designed for anothe
Martin Blais added the comment:
Thank you Martin!
--
___
Python tracker
<http://bugs.python.org/issue24278>
___
___
Python-bugs-list mailing list
Unsubscribe:
Martin Blais added the comment:
LGTM! Thanks for making the change.
--
___
Python tracker
<http://bugs.python.org/issue24278>
___
___
Python-bugs-list mailin
Martin Blais added the comment:
Oh, and yes, just adding this info at the top would be fine IMO. It shouldn't
have to be repeated.
--
___
Python tracker
<http://bugs.python.org/is
Martin Blais added the comment:
Adding information that tells developers where the memory for those returned
areas is stored and as you mention, its lifetime guarantees w.r.t. to the
Python object, would go a long way towards making this more clear. The
questions that immediately came to my
Martin Blais added the comment:
I don't think I'm the right person to propose a patch for this; I'm just
guessing how it works so far, I haven't had time to look into the source code
in detail, I'm sure there
New submission from Martin Blais:
Functions that parse arguments like PyArg_ParseTupleAndKeywords() have several
formatters that fill in C strings, e.g. "s".
In the C API doc:
https://docs.python.org/3.5/c-api/arg.html#c.PyArg_ParseTupleAndKeywords
There should be an explicit
New submission from Martin Blais :
The output of running "python setup.py --help-commands" does not include
the "upload" command.
--
components: Library (Lib)
messages: 84884
nosy: blais
severity: normal
status: open
title: Distutils "upload" command does
Changes by Martin Blais :
--
components: +Library (Lib)
type: -> feature request
___
Python tracker
<http://bugs.python.org/issue5206>
___
___
Python-bugs-lis
New submission from Martin Blais :
Here is a useful trick to restore the normal call syntax for delayed
evaluation for assertRaises():
from contextlib import contextmanager
@contextmanager
def raised(exctype):
try:
yield
raise AssertionError
12 matches
Mail list logo