I've been toying with a similar idea myself. I've felt the pain
described by Brian, and I share Marco's dislike for the suggested
syntax. Moreover, I dislike the idea that the conditional should
somehow refer to the function's default arguments.
My half-baked idea is along the lines of
f(
Hi Pythonistas,
The -b flag, which turns on checks which emit BytesWarnings on
operations mixing bytes and str objects, is very useful.
However, the only way to set this flag is via the Python invocation.
This limits its usability in contexts where the user's control of the
Python invocation is l
On Fri, 7 Feb 2020 20:08:35 -0800
Andrew Barnert wrote:
> > On Feb 7, 2020, at 16:11, Steven D'Aprano
> > wrote:
> >
> > Shai Berger wants to set it implicily, based on where the raise is.
> > If it is "directly" under the except line, impl
Hi,
In the Django thread, I suggested that an implicit "raise from" should
be the behavior whenever an exception is raised directly in
exception-handling code (that is, within an except: or finally:
clause). Ram claimed there were problems with that, but gave no
details; I would be happy to know w