Re: [Python-Dev] breakpoint() and $PYTHONBREAKPOINT

2017-09-12 Thread Nick Coghlan
On 12 September 2017 at 11:15, Nathaniel Smith wrote: > On Mon, Sep 11, 2017 at 5:27 PM, Barry Warsaw wrote: >> On Sep 10, 2017, at 13:46, Nathaniel Smith wrote: >>> >>> On Sun, Sep 10, 2017 at 12:06 PM, Barry Warsaw wrote: For PEP 553, I think it’s a good idea to support the environment v

Re: [Python-Dev] breakpoint() and $PYTHONBREAKPOINT

2017-09-11 Thread Nathaniel Smith
On Mon, Sep 11, 2017 at 6:45 PM, Barry Warsaw wrote: > On Sep 11, 2017, at 18:15, Nathaniel Smith wrote: > >> Compared to checking it on each call to sys.breakpointhook(), I guess >> the two user-visible differences in behavior would be: >> >> - whether mutating os.environ["PYTHONBREAKPOINT"] ins

Re: [Python-Dev] breakpoint() and $PYTHONBREAKPOINT

2017-09-11 Thread Barry Warsaw
On Sep 11, 2017, at 18:15, Nathaniel Smith wrote: > Compared to checking it on each call to sys.breakpointhook(), I guess > the two user-visible differences in behavior would be: > > - whether mutating os.environ["PYTHONBREAKPOINT"] inside the process > affects future calls. I would find it quit

Re: [Python-Dev] breakpoint() and $PYTHONBREAKPOINT

2017-09-11 Thread Nathaniel Smith
On Mon, Sep 11, 2017 at 5:27 PM, Barry Warsaw wrote: > On Sep 10, 2017, at 13:46, Nathaniel Smith wrote: >> >> On Sun, Sep 10, 2017 at 12:06 PM, Barry Warsaw wrote: >>> For PEP 553, I think it’s a good idea to support the environment variable >>> $PYTHONBREAKPOINT[*] but I’m stuck on a design q

Re: [Python-Dev] breakpoint() and $PYTHONBREAKPOINT

2017-09-11 Thread Barry Warsaw
On Sep 10, 2017, at 13:46, Nathaniel Smith wrote: > > On Sun, Sep 10, 2017 at 12:06 PM, Barry Warsaw wrote: >> For PEP 553, I think it’s a good idea to support the environment variable >> $PYTHONBREAKPOINT[*] but I’m stuck on a design question, so I’d like to get >> some feedback. >> >> Shoul

Re: [Python-Dev] breakpoint() and $PYTHONBREAKPOINT

2017-09-11 Thread Barry Warsaw
On Sep 10, 2017, at 12:16, Guido van Rossum wrote: > > I think programmatic overrides should be able to decide for themselves if > they want to honor PYTHONBREAKPOINT or not, since I can imagine use cases > that go both ways. So it should be checked in sys.breakpointhook(). Thanks Guido, I’ll

Re: [Python-Dev] breakpoint() and $PYTHONBREAKPOINT

2017-09-10 Thread Nathaniel Smith
On Sun, Sep 10, 2017 at 12:06 PM, Barry Warsaw wrote: > For PEP 553, I think it’s a good idea to support the environment variable > $PYTHONBREAKPOINT[*] but I’m stuck on a design question, so I’d like to get > some feedback. > > Should $PYTHONBREAKPOINT be consulted in breakpoint() or in > sys.

Re: [Python-Dev] breakpoint() and $PYTHONBREAKPOINT

2017-09-10 Thread Guido van Rossum
I think programmatic overrides should be able to decide for themselves if they want to honor PYTHONBREAKPOINT or not, since I can imagine use cases that go both ways. So it should be checked in sys.breakpointhook(). On Sun, Sep 10, 2017 at 12:06 PM, Barry Warsaw wrote: > For PEP 553, I think it’

[Python-Dev] breakpoint() and $PYTHONBREAKPOINT

2017-09-10 Thread Barry Warsaw
For PEP 553, I think it’s a good idea to support the environment variable $PYTHONBREAKPOINT[*] but I’m stuck on a design question, so I’d like to get some feedback. Should $PYTHONBREAKPOINT be consulted in breakpoint() or in sys.breakpointhook()? If we support it in breakpoint() then it means