From bussonniermatthias at gmail.com  Tue Jul  5 19:41:40 2016
From: bussonniermatthias at gmail.com (Matthias Bussonnier)
Date: Tue, 5 Jul 2016 16:41:40 -0700
Subject: [IPython-dev] IPython 5.0.0rc1
Message-ID: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>

Hi all,

I'm happy to announce IPython 5.0.0rc1, hopefully that will be the last before
the final version. Upgrade with

    $ pip install ipython --upgrade --pre

We have 1 outstanding issue where `%matplotlib qt` on Windows is currently
broken, we would need help in getting that fixed as most of the dev dont have
windows available.

- https://github.com/ipython/ipython/issues/9652


The time since Beta4 have been longer than usual as we were waiting for some
upstream fixes.

Big improvement and efforts on the documentation side, that you can view on
readthedocs:

    http://ipython.readthedocs.io/en/latest/

In particular the what's new is of interest:

    http://ipython.readthedocs.io/en/latest/whatsnew/version5.html



Since Beta 4 we had the following noticeable points.
 - Attempt to document most of prompt_toolkit shortcuts (vi and emacs mode)
 - lots of cleanup of readline-relative code that should be unused, and added
   quite a bit of DeprecationWarnings in places that needed them.
 - restore color in IPython.embed()
 - TerminalInteractiveShell.colors gain a "Neutral" theme now the default, that
   should be visible both on light and dark BG. the `linux` and `lightbg`
   variant have now  more contrast, and can be switched live with `%colors`
   magic.
 - lots of edge-case bug fix/crash.



Related info:

- There were upload issue  with warehouse, If install fail, or you have weirds
  issue, feel free to tell us.

- Jupyter console 5 is out, not much change from beta. It fix compatibility
  issues with IPython 5.0

- Hopefully I'll release 5.0 by end of week/early next week, before or during
  SciPy with a bigger announce on the Jupyter blog.

Thanks all
-- 
M


From asmeurer at gmail.com  Tue Jul  5 20:22:09 2016
From: asmeurer at gmail.com (Aaron Meurer)
Date: Tue, 5 Jul 2016 20:22:09 -0400
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
Message-ID: <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>

Minor annoyance with the emacs bindings: C-k at the end of a line
should delete the newline. Probably also the reverse for C-u.

Question: with the new multiline editing, up arrow (and C-p) just move
up a line. Is there a fast way to cycle through the history without
going up one line at a time in each history item?

Bug under the emacs bindings: M-d under a single character doesn't
delete the character.

Aaron Meurer

On Tue, Jul 5, 2016 at 7:41 PM, Matthias Bussonnier
<bussonniermatthias at gmail.com> wrote:
> Hi all,
>
> I'm happy to announce IPython 5.0.0rc1, hopefully that will be the last before
> the final version. Upgrade with
>
>     $ pip install ipython --upgrade --pre
>
> We have 1 outstanding issue where `%matplotlib qt` on Windows is currently
> broken, we would need help in getting that fixed as most of the dev dont have
> windows available.
>
> - https://github.com/ipython/ipython/issues/9652
>
>
> The time since Beta4 have been longer than usual as we were waiting for some
> upstream fixes.
>
> Big improvement and efforts on the documentation side, that you can view on
> readthedocs:
>
>     http://ipython.readthedocs.io/en/latest/
>
> In particular the what's new is of interest:
>
>     http://ipython.readthedocs.io/en/latest/whatsnew/version5.html
>
>
>
> Since Beta 4 we had the following noticeable points.
>  - Attempt to document most of prompt_toolkit shortcuts (vi and emacs mode)
>  - lots of cleanup of readline-relative code that should be unused, and added
>    quite a bit of DeprecationWarnings in places that needed them.
>  - restore color in IPython.embed()
>  - TerminalInteractiveShell.colors gain a "Neutral" theme now the default, that
>    should be visible both on light and dark BG. the `linux` and `lightbg`
>    variant have now  more contrast, and can be switched live with `%colors`
>    magic.
>  - lots of edge-case bug fix/crash.
>
>
>
> Related info:
>
> - There were upload issue  with warehouse, If install fail, or you have weirds
>   issue, feel free to tell us.
>
> - Jupyter console 5 is out, not much change from beta. It fix compatibility
>   issues with IPython 5.0
>
> - Hopefully I'll release 5.0 by end of week/early next week, before or during
>   SciPy with a bigger announce on the Jupyter blog.
>
> Thanks all
> --
> M
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev


From nathan12343 at gmail.com  Tue Jul  5 20:34:01 2016
From: nathan12343 at gmail.com (Nathan Goldbaum)
Date: Tue, 5 Jul 2016 19:34:01 -0500
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>
Message-ID: <CAJXewO=m6ZrJW5uQv0pfpaJ8T7=yTx=_-grDLSpiPiQb=nep0w@mail.gmail.com>

On Tue, Jul 5, 2016 at 7:22 PM, Aaron Meurer <asmeurer at gmail.com> wrote:

> Minor annoyance with the emacs bindings: C-k at the end of a line
> should delete the newline. Probably also the reverse for C-u.
>
> Question: with the new multiline editing, up arrow (and C-p) just move
> up a line. Is there a fast way to cycle through the history without
> going up one line at a time in each history item?
>

C-up arrow and C-down arrow.


>
> Bug under the emacs bindings: M-d under a single character doesn't
> delete the character.
>
> Aaron Meurer
>
> On Tue, Jul 5, 2016 at 7:41 PM, Matthias Bussonnier
> <bussonniermatthias at gmail.com> wrote:
> > Hi all,
> >
> > I'm happy to announce IPython 5.0.0rc1, hopefully that will be the last
> before
> > the final version. Upgrade with
> >
> >     $ pip install ipython --upgrade --pre
> >
> > We have 1 outstanding issue where `%matplotlib qt` on Windows is
> currently
> > broken, we would need help in getting that fixed as most of the dev dont
> have
> > windows available.
> >
> > - https://github.com/ipython/ipython/issues/9652
> >
> >
> > The time since Beta4 have been longer than usual as we were waiting for
> some
> > upstream fixes.
> >
> > Big improvement and efforts on the documentation side, that you can view
> on
> > readthedocs:
> >
> >     http://ipython.readthedocs.io/en/latest/
> >
> > In particular the what's new is of interest:
> >
> >     http://ipython.readthedocs.io/en/latest/whatsnew/version5.html
> >
> >
> >
> > Since Beta 4 we had the following noticeable points.
> >  - Attempt to document most of prompt_toolkit shortcuts (vi and emacs
> mode)
> >  - lots of cleanup of readline-relative code that should be unused, and
> added
> >    quite a bit of DeprecationWarnings in places that needed them.
> >  - restore color in IPython.embed()
> >  - TerminalInteractiveShell.colors gain a "Neutral" theme now the
> default, that
> >    should be visible both on light and dark BG. the `linux` and `lightbg`
> >    variant have now  more contrast, and can be switched live with
> `%colors`
> >    magic.
> >  - lots of edge-case bug fix/crash.
> >
> >
> >
> > Related info:
> >
> > - There were upload issue  with warehouse, If install fail, or you have
> weirds
> >   issue, feel free to tell us.
> >
> > - Jupyter console 5 is out, not much change from beta. It fix
> compatibility
> >   issues with IPython 5.0
> >
> > - Hopefully I'll release 5.0 by end of week/early next week, before or
> during
> >   SciPy with a bigger announce on the Jupyter blog.
> >
> > Thanks all
> > --
> > M
> > _______________________________________________
> > IPython-dev mailing list
> > IPython-dev at scipy.org
> > https://mail.scipy.org/mailman/listinfo/ipython-dev
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160705/98e0d82f/attachment.html>

From fperez.net at gmail.com  Tue Jul  5 20:43:15 2016
From: fperez.net at gmail.com (Fernando Perez)
Date: Tue, 5 Jul 2016 17:43:15 -0700
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CAJXewO=m6ZrJW5uQv0pfpaJ8T7=yTx=_-grDLSpiPiQb=nep0w@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>
 <CAJXewO=m6ZrJW5uQv0pfpaJ8T7=yTx=_-grDLSpiPiQb=nep0w@mail.gmail.com>
Message-ID: <CAHAreOp51BgnAdchNVwCrrsW2AC8Z3-eYJw6nwiACgEq_10gYA@mail.gmail.com>

On Tue, Jul 5, 2016 at 5:34 PM, Nathan Goldbaum <nathan12343 at gmail.com>
wrote:

> On Tue, Jul 5, 2016 at 7:22 PM, Aaron Meurer <asmeurer at gmail.com> wrote:
>
>> Minor annoyance with the emacs bindings: C-k at the end of a line
>> should delete the newline. Probably also the reverse for C-u.
>>
>> Question: with the new multiline editing, up arrow (and C-p) just move
>> up a line. Is there a fast way to cycle through the history without
>> going up one line at a time in each history item?
>>
>
> C-up arrow and C-down arrow.
>

Mmmh, I don't think that's what Aaron is asking: those still make you walk
through each line of a multi-line history entry.  At least that's what I'm
getting on OSX with master (git 74b0369)

I think what Aaron wants is a way to retrieve entire history items one at a
time, even if they are multi-line...  I couldn't find a way to do that, but
Matthias is much more up to speed on the intricacies of the new keybinding
machinery.

Cheers

f

-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160705/7e33fa93/attachment.html>

From bussonniermatthias at gmail.com  Tue Jul  5 21:22:41 2016
From: bussonniermatthias at gmail.com (Matthias Bussonnier)
Date: Tue, 5 Jul 2016 18:22:41 -0700
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CAHAreOp51BgnAdchNVwCrrsW2AC8Z3-eYJw6nwiACgEq_10gYA@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>
 <CAJXewO=m6ZrJW5uQv0pfpaJ8T7=yTx=_-grDLSpiPiQb=nep0w@mail.gmail.com>
 <CAHAreOp51BgnAdchNVwCrrsW2AC8Z3-eYJw6nwiACgEq_10gYA@mail.gmail.com>
Message-ID: <CANJQusXCXBT-_8mfvt8t-odbm10jYUjvtYJRyX5OvG7U1O8tMA@mail.gmail.com>

>>
>> On Tue, Jul 5, 2016 at 7:22 PM, Aaron Meurer <asmeurer at gmail.com> wrote:
>>>
>>> Minor annoyance with the emacs bindings: C-k at the end of a line
>>> should delete the newline. Probably also the reverse for C-u.

Can you open issues for these ? I guess we might bring them upstream
to Prompt_toolit.

>>>
>>> Question: with the new multiline editing, up arrow (and C-p) just move
>>> up a line. Is there a fast way to cycle through the history without
>>> going up one line at a time in each history item?

Page-Up / Page-Down (fn-up/fn-down should work too
At least it works for me on mac), and indeed it's one of the things
that annoyed me a bit,
but my muscle memory adjusted quite fast.

>> C-up arrow and C-down arrow.
>
> Mmmh, I don't think that's what Aaron is asking: those still make you walk
> through each line of a multi-line history entry.  At least that's what I'm
> getting on OSX with master (git 74b0369)
>
> I think what Aaron wants is a way to retrieve entire history items one at a
> time, even if they are multi-line...  I couldn't find a way to do that, but
> Matthias is much more up to speed on the intricacies of the new keybinding
> machinery.

I thought you were the IPython Guru.
-- 
M


From fperez.net at gmail.com  Tue Jul  5 21:31:43 2016
From: fperez.net at gmail.com (Fernando Perez)
Date: Tue, 5 Jul 2016 18:31:43 -0700
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CANJQusXCXBT-_8mfvt8t-odbm10jYUjvtYJRyX5OvG7U1O8tMA@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>
 <CAJXewO=m6ZrJW5uQv0pfpaJ8T7=yTx=_-grDLSpiPiQb=nep0w@mail.gmail.com>
 <CAHAreOp51BgnAdchNVwCrrsW2AC8Z3-eYJw6nwiACgEq_10gYA@mail.gmail.com>
 <CANJQusXCXBT-_8mfvt8t-odbm10jYUjvtYJRyX5OvG7U1O8tMA@mail.gmail.com>
Message-ID: <CAHAreOozfxBfWe-ETbfwVnNXsD-p48g5A5pboqO+wjRswpF7SA@mail.gmail.com>

On Tue, Jul 5, 2016 at 6:22 PM, Matthias Bussonnier <
bussonniermatthias at gmail.com> wrote:

> Page-Up / Page-Down (fn-up/fn-down should work too
> At least it works for me on mac), and indeed it's one of the things
> that annoyed me a bit,
> but my muscle memory adjusted quite fast.
>

Unfortunately on OSX that only works on iTerm2.

On the default OSX Termina, for me Page up/down simply scroll the entire
terminal.

-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160705/725e862f/attachment.html>

From bussonniermatthias at gmail.com  Tue Jul  5 21:43:19 2016
From: bussonniermatthias at gmail.com (Matthias Bussonnier)
Date: Tue, 5 Jul 2016 18:43:19 -0700
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CAHAreOozfxBfWe-ETbfwVnNXsD-p48g5A5pboqO+wjRswpF7SA@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>
 <CAJXewO=m6ZrJW5uQv0pfpaJ8T7=yTx=_-grDLSpiPiQb=nep0w@mail.gmail.com>
 <CAHAreOp51BgnAdchNVwCrrsW2AC8Z3-eYJw6nwiACgEq_10gYA@mail.gmail.com>
 <CANJQusXCXBT-_8mfvt8t-odbm10jYUjvtYJRyX5OvG7U1O8tMA@mail.gmail.com>
 <CAHAreOozfxBfWe-ETbfwVnNXsD-p48g5A5pboqO+wjRswpF7SA@mail.gmail.com>
Message-ID: <CANJQusW1T+s3eTTVcpoE6YfbLo+3h44MgMJSjHyO5nR7O2Q6cg@mail.gmail.com>

Just bind your PageUp/Down in Terminal.App to the correct escape sequeces:

Terminal > preferences > keyboard > +

To respectively  PgUp: \033[5~ and PgDown: \033[6~  the `\033` can be
obtain by pressing `Esc` and **not** by pressing `\`,`0`,`3`,`3` in
sequence.
-- 
M


On Tue, Jul 5, 2016 at 6:31 PM, Fernando Perez <fperez.net at gmail.com> wrote:
>
> On Tue, Jul 5, 2016 at 6:22 PM, Matthias Bussonnier
> <bussonniermatthias at gmail.com> wrote:
>>
>> Page-Up / Page-Down (fn-up/fn-down should work too
>> At least it works for me on mac), and indeed it's one of the things
>> that annoyed me a bit,
>> but my muscle memory adjusted quite fast.
>
>
> Unfortunately on OSX that only works on iTerm2.
>
> On the default OSX Termina, for me Page up/down simply scroll the entire
> terminal.
>
> --
> Fernando Perez (@fperez_org; http://fperez.org)
> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
> fernando.perez-at-berkeley: contact me here for any direct mail
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Screen Shot 2016-07-05 at 18.39.31.png
Type: image/png
Size: 326702 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160705/75b16dbe/attachment.png>

From fperez.net at gmail.com  Tue Jul  5 21:47:43 2016
From: fperez.net at gmail.com (Fernando Perez)
Date: Tue, 5 Jul 2016 18:47:43 -0700
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CANJQusW1T+s3eTTVcpoE6YfbLo+3h44MgMJSjHyO5nR7O2Q6cg@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>
 <CAJXewO=m6ZrJW5uQv0pfpaJ8T7=yTx=_-grDLSpiPiQb=nep0w@mail.gmail.com>
 <CAHAreOp51BgnAdchNVwCrrsW2AC8Z3-eYJw6nwiACgEq_10gYA@mail.gmail.com>
 <CANJQusXCXBT-_8mfvt8t-odbm10jYUjvtYJRyX5OvG7U1O8tMA@mail.gmail.com>
 <CAHAreOozfxBfWe-ETbfwVnNXsD-p48g5A5pboqO+wjRswpF7SA@mail.gmail.com>
 <CANJQusW1T+s3eTTVcpoE6YfbLo+3h44MgMJSjHyO5nR7O2Q6cg@mail.gmail.com>
Message-ID: <CAHAreOoy+AM2iknMQ5StuT7_PrE_qfc3SY_nTh5R6kQ-E2xN2Q@mail.gmail.com>

On Tue, Jul 5, 2016 at 6:43 PM, Matthias Bussonnier <
bussonniermatthias at gmail.com> wrote:

> Just bind your PageUp/Down in Terminal.App to the correct escape sequeces:
>
> Terminal > preferences > keyboard > +
>
> To respectively  PgUp: \033[5~ and PgDown: \033[6~  the `\033` can be
> obtain by pressing `Esc` and **not** by pressing `\`,`0`,`3`,`3` in
> sequence.
>

Thanks for that solution!  I actually like Pg Up/Down to scroll as I use it
a lot, so I'll probably give this up for now.

The issue remains that the default for OSX terminal users won't do this,
but at least

a) it works on iTerm
b) there's a workaround if you're willing to sacrifice easy keyboard
scrolling on Terminal.


-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160705/9f0bade8/attachment.html>

From asmeurer at gmail.com  Tue Jul  5 21:53:11 2016
From: asmeurer at gmail.com (Aaron Meurer)
Date: Tue, 5 Jul 2016 21:53:11 -0400
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CAHAreOoy+AM2iknMQ5StuT7_PrE_qfc3SY_nTh5R6kQ-E2xN2Q@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>
 <CAJXewO=m6ZrJW5uQv0pfpaJ8T7=yTx=_-grDLSpiPiQb=nep0w@mail.gmail.com>
 <CAHAreOp51BgnAdchNVwCrrsW2AC8Z3-eYJw6nwiACgEq_10gYA@mail.gmail.com>
 <CANJQusXCXBT-_8mfvt8t-odbm10jYUjvtYJRyX5OvG7U1O8tMA@mail.gmail.com>
 <CAHAreOozfxBfWe-ETbfwVnNXsD-p48g5A5pboqO+wjRswpF7SA@mail.gmail.com>
 <CANJQusW1T+s3eTTVcpoE6YfbLo+3h44MgMJSjHyO5nR7O2Q6cg@mail.gmail.com>
 <CAHAreOoy+AM2iknMQ5StuT7_PrE_qfc3SY_nTh5R6kQ-E2xN2Q@mail.gmail.com>
Message-ID: <CAKgW=6+Xp+B0PJuOm-+fk2sYf+VRRM=Sn3Ri9-XCLua0oOMMdQ@mail.gmail.com>

Could we also map C-v and M-v to page down/up in emacs mode then?

Aaron Meurer

On Tue, Jul 5, 2016 at 9:47 PM, Fernando Perez <fperez.net at gmail.com> wrote:
>
> On Tue, Jul 5, 2016 at 6:43 PM, Matthias Bussonnier
> <bussonniermatthias at gmail.com> wrote:
>>
>> Just bind your PageUp/Down in Terminal.App to the correct escape sequeces:
>>
>> Terminal > preferences > keyboard > +
>>
>> To respectively  PgUp: \033[5~ and PgDown: \033[6~  the `\033` can be
>> obtain by pressing `Esc` and **not** by pressing `\`,`0`,`3`,`3` in
>> sequence.
>
>
> Thanks for that solution!  I actually like Pg Up/Down to scroll as I use it
> a lot, so I'll probably give this up for now.
>
> The issue remains that the default for OSX terminal users won't do this, but
> at least
>
> a) it works on iTerm
> b) there's a workaround if you're willing to sacrifice easy keyboard
> scrolling on Terminal.
>
>
> --
> Fernando Perez (@fperez_org; http://fperez.org)
> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
> fernando.perez-at-berkeley: contact me here for any direct mail
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>


From bussonniermatthias at gmail.com  Tue Jul  5 22:12:38 2016
From: bussonniermatthias at gmail.com (Matthias Bussonnier)
Date: Tue, 5 Jul 2016 19:12:38 -0700
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CAKgW=6+Xp+B0PJuOm-+fk2sYf+VRRM=Sn3Ri9-XCLua0oOMMdQ@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAKgW=6Jvhz6O2Mv8PZcCsKR2rBYFq4Ufp2UAOFr5x9jH0173bg@mail.gmail.com>
 <CAJXewO=m6ZrJW5uQv0pfpaJ8T7=yTx=_-grDLSpiPiQb=nep0w@mail.gmail.com>
 <CAHAreOp51BgnAdchNVwCrrsW2AC8Z3-eYJw6nwiACgEq_10gYA@mail.gmail.com>
 <CANJQusXCXBT-_8mfvt8t-odbm10jYUjvtYJRyX5OvG7U1O8tMA@mail.gmail.com>
 <CAHAreOozfxBfWe-ETbfwVnNXsD-p48g5A5pboqO+wjRswpF7SA@mail.gmail.com>
 <CANJQusW1T+s3eTTVcpoE6YfbLo+3h44MgMJSjHyO5nR7O2Q6cg@mail.gmail.com>
 <CAHAreOoy+AM2iknMQ5StuT7_PrE_qfc3SY_nTh5R6kQ-E2xN2Q@mail.gmail.com>
 <CAKgW=6+Xp+B0PJuOm-+fk2sYf+VRRM=Sn3Ri9-XCLua0oOMMdQ@mail.gmail.com>
Message-ID: <CANJQusXADPwa_wdBT2xD+NC4HYSU49fxu_akvhMcPmqcrONHBw@mail.gmail.com>

If they are available, likely yes.
We still haven't completly figured out the prompt_toolkit keyboard
configuration for it to be easy and declarative.

On Tue, Jul 5, 2016 at 6:53 PM, Aaron Meurer <asmeurer at gmail.com> wrote:
> Could we also map C-v and M-v to page down/up in emacs mode then?
>
> Aaron Meurer
>
> On Tue, Jul 5, 2016 at 9:47 PM, Fernando Perez <fperez.net at gmail.com> wrote:
>>
>> On Tue, Jul 5, 2016 at 6:43 PM, Matthias Bussonnier
>> <bussonniermatthias at gmail.com> wrote:
>>>
>>> Just bind your PageUp/Down in Terminal.App to the correct escape sequeces:
>>>
>>> Terminal > preferences > keyboard > +
>>>
>>> To respectively  PgUp: \033[5~ and PgDown: \033[6~  the `\033` can be
>>> obtain by pressing `Esc` and **not** by pressing `\`,`0`,`3`,`3` in
>>> sequence.
>>
>>
>> Thanks for that solution!  I actually like Pg Up/Down to scroll as I use it
>> a lot, so I'll probably give this up for now.
>>
>> The issue remains that the default for OSX terminal users won't do this, but
>> at least
>>
>> a) it works on iTerm
>> b) there's a workaround if you're willing to sacrifice easy keyboard
>> scrolling on Terminal.
>>
>>
>> --
>> Fernando Perez (@fperez_org; http://fperez.org)
>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
>> fernando.perez-at-berkeley: contact me here for any direct mail
>>
>> _______________________________________________
>> IPython-dev mailing list
>> IPython-dev at scipy.org
>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev


From klonuo at gmail.com  Wed Jul  6 09:15:42 2016
From: klonuo at gmail.com (klo uo)
Date: Wed, 6 Jul 2016 15:15:42 +0200
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
Message-ID: <CAA-8Ld9K5tZMJO4q_8AYvA_5RU_j_+5k9-2erYmwY_sR+NtRFA@mail.gmail.com>

On Wed, Jul 6, 2016 at 1:41 AM, Matthias Bussonnier <
bussonniermatthias at gmail.com> wrote:

>
> Since Beta 4 we had the following noticeable points.
>  - Attempt to document most of prompt_toolkit shortcuts (vi and emacs mode)
>


Matthias, it seems shortcuts tables didn't get thorough:
http://ipython.readthedocs.io/en/latest/config/shortcuts/index.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160706/a3f4c17f/attachment.html>

From stuart at cadair.com  Wed Jul  6 10:23:13 2016
From: stuart at cadair.com (Stuart Mumford)
Date: Wed, 6 Jul 2016 15:23:13 +0100
Subject: [IPython-dev] Need help review change that affect IPython/Emacs
 integration.
In-Reply-To: <CAOvn4qjAdcBvFesf8w-CYX0Es8=ph9N1itOd4XZ81mkUtkSfNA@mail.gmail.com>
References: <CANJQusWQE2Hq7=GWhmApokrOP-AApUA8E+wXcQVUi26mJ9JO+g@mail.gmail.com>
 <CAKgW=6+_x5BUUvDNsmd9A_8TKS+NnBMz=rG2-LKeu3684hX+Sw@mail.gmail.com>
 <17ec3bbb-edd2-941b-045a-0a7f7778748c@cadair.com>
 <CAOvn4qjAdcBvFesf8w-CYX0Es8=ph9N1itOd4XZ81mkUtkSfNA@mail.gmail.com>
Message-ID: <2790533b-5ae7-30c2-ebdb-6d5144ecbca4@cadair.com>

That seems to have fixed it.


On 24/06/16 14:07, Thomas Kluyver wrote:
> Are you using the --simple-prompt flag to instantiate IPython for the
> inferior shell?
>
> On 24 June 2016 at 10:01, Stuart Mumford <stuart at cadair.com
> <mailto:stuart at cadair.com>> wrote:
>
>     Hello,
>
>     I am far from an advanced emacs user, but I have installed IPython
>     5.0b4
>     and prompt_toolkit 1.0.3 and when I run my inferior ipython shell, it
>     seems to "work" but no input prompt is shown (see attached
>     screenshot).
>
>     If you can guide me on debugging and or testing patches I am happy to
>     help, but can not offer any insight on the emacs side.
>
>     Stuart
>
>
>     On 25/05/16 19:56, Aaron Meurer wrote:
>     > Some potentially useful information about this
>     >
>     https://www.masteringemacs.org/article/running-shells-in-emacs-overview.
>     >
>     > Aaron Meurer
>     >
>     > On Wed, May 25, 2016 at 2:49 PM, Matthias Bussonnier
>     > <bussonniermatthias at gmail.com
>     <mailto:bussonniermatthias at gmail.com>> wrote:
>     >> Hello list,
>     >>
>     >> As you might know the current master of IPython is now using
>     >> Prompt-toolkit to provide crazy awesome multi line-editing, and
>     >> syntactic coloration.
>     >>
>     >> Though it might have some effect with emacs python.el
>     integration and
>     >> in particular the 'inferior shell' (whatever that is).
>     >>
>     >> We'll appreciate any help on testing potential issues, see here:
>     >>
>     >> https://github.com/ipython/ipython/pull/9399
>     >>
>     >> So if you are or know any emacs user that have slightly more
>     >> competence[1] than us  to investigate the emacs side of things, we
>     >> would really appreciate for you/them to pitch in, and propagate the
>     >> message.
>     >>
>     >> Thanks a lot for your help,
>     >> --
>     >> M
>     >>
>     >> [1]: That is to say more than typing `emacs` and then wondering how
>     >> the hell to quit.
>     >> _______________________________________________
>     >> IPython-dev mailing list
>     >> IPython-dev at scipy.org <mailto:IPython-dev at scipy.org>
>     >> https://mail.scipy.org/mailman/listinfo/ipython-dev
>     > _______________________________________________
>     > IPython-dev mailing list
>     > IPython-dev at scipy.org <mailto:IPython-dev at scipy.org>
>     > https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
>     _______________________________________________
>     IPython-dev mailing list
>     IPython-dev at scipy.org <mailto:IPython-dev at scipy.org>
>     https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160706/a161af2a/attachment.html>

From bussonniermatthias at gmail.com  Wed Jul  6 11:28:59 2016
From: bussonniermatthias at gmail.com (Matthias Bussonnier)
Date: Wed, 6 Jul 2016 08:28:59 -0700
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CAA-8Ld9K5tZMJO4q_8AYvA_5RU_j_+5k9-2erYmwY_sR+NtRFA@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAA-8Ld9K5tZMJO4q_8AYvA_5RU_j_+5k9-2erYmwY_sR+NtRFA@mail.gmail.com>
Message-ID: <CANJQusXgqs2H_XeuwCP5Dna6rLu4T1v1b8bovooWy41h3Am0nw@mail.gmail.com>

Yeah I saw that as well, they render locally but not on readthedocs.

On Wed, Jul 6, 2016 at 6:15 AM, klo uo <klonuo at gmail.com> wrote:
> On Wed, Jul 6, 2016 at 1:41 AM, Matthias Bussonnier
> <bussonniermatthias at gmail.com> wrote:
>>
>>
>> Since Beta 4 we had the following noticeable points.
>>  - Attempt to document most of prompt_toolkit shortcuts (vi and emacs
>> mode)
>
>
>
> Matthias, it seems shortcuts tables didn't get thorough:
> http://ipython.readthedocs.io/en/latest/config/shortcuts/index.html
>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>


From takowl at gmail.com  Wed Jul  6 11:37:43 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Wed, 6 Jul 2016 16:37:43 +0100
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CANJQusXgqs2H_XeuwCP5Dna6rLu4T1v1b8bovooWy41h3Am0nw@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAA-8Ld9K5tZMJO4q_8AYvA_5RU_j_+5k9-2erYmwY_sR+NtRFA@mail.gmail.com>
 <CANJQusXgqs2H_XeuwCP5Dna6rLu4T1v1b8bovooWy41h3Am0nw@mail.gmail.com>
Message-ID: <CAOvn4qgWa93nJ=tY8y_XDJAEXsfxcXkg3dRVRCCNSx=mczRBKg@mail.gmail.com>

On 6 July 2016 at 16:28, Matthias Bussonnier <bussonniermatthias at gmail.com>
wrote:

> Yeah I saw that as well, they render locally but not on readthedocs.
>

Remember RTD doesn't use the Makefile, so extra steps have to be hacked in
via the conf.py:

https://github.com/ipython/ipython/blob/6f44adf605ed3e55fcbab07d3c0a007a4b6e4a94/docs/source/conf.py#L22-L36
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160706/bebcc805/attachment.html>

From bussonniermatthias at gmail.com  Wed Jul  6 11:41:30 2016
From: bussonniermatthias at gmail.com (Matthias Bussonnier)
Date: Wed, 6 Jul 2016 08:41:30 -0700
Subject: [IPython-dev] IPython 5.0.0rc1
In-Reply-To: <CAOvn4qgWa93nJ=tY8y_XDJAEXsfxcXkg3dRVRCCNSx=mczRBKg@mail.gmail.com>
References: <CANJQusVjyO7khS0FDRy+5v-swiC74Dm3aeSwc-MzAt_353=dUA@mail.gmail.com>
 <CAA-8Ld9K5tZMJO4q_8AYvA_5RU_j_+5k9-2erYmwY_sR+NtRFA@mail.gmail.com>
 <CANJQusXgqs2H_XeuwCP5Dna6rLu4T1v1b8bovooWy41h3Am0nw@mail.gmail.com>
 <CAOvn4qgWa93nJ=tY8y_XDJAEXsfxcXkg3dRVRCCNSx=mczRBKg@mail.gmail.com>
Message-ID: <CANJQusWNJX_WQkmLQDzZ7mz7nAJciqLcmjM+YxdwM8ysukPUfw@mail.gmail.com>

> Remember RTD doesn't use the Makefile, so extra steps have to be hacked in
> via the conf.py:
>
> https://github.com/ipython/ipython/blob/6f44adf605ed3e55fcbab07d3c0a007a4b6e4a94/docs/source/conf.py#L22-L36

[Indistinguishable complaining sounds coming from Berkeley Institute
for Data Science offices in the back].
-- 
M


From fperez.net at gmail.com  Thu Jul  7 23:09:07 2016
From: fperez.net at gmail.com (Fernando Perez)
Date: Thu, 7 Jul 2016 20:09:07 -0700
Subject: [IPython-dev] [ANN] IPython 5.0 is out!
Message-ID: <CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ=F1Ga1zRFa_Q@mail.gmail.com>

Hi all,

On behalf of the team, I'm delighted to announce the release of IPython 5.0
today!

As we continue building the broader architecture and tools of Project
Jupyter, the IPython kernel and shell remain for many python users the
"beating heart" of Jupyter and the environment they actually use to
interact with their code every day.

So we continue making the system better, and especially for terminal users
this release brings some very nice enhancements.

As usual you can try this new release with:

pip install ipython --upgrade

or you can wait a bit for it to propagate to the repositories of your
favorite packaging system/distribution.

You can find more details at the blog:
http://blog.jupyter.org/2016/07/08/ipython-5-0-released/

Many thanks to everyone who made this release possible, and in particular
to Thomas and Matthias who carried the lion's share of the effort to bring
us a lot of very nice new features, as well as to Jonathan Slenders, the
author of prompt_toolkit that makes much of the new shiny possible.

Cheers,

f

-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160707/cd956413/attachment.html>

From ellisonbg at gmail.com  Thu Jul  7 23:11:29 2016
From: ellisonbg at gmail.com (Brian Granger)
Date: Thu, 7 Jul 2016 20:11:29 -0700
Subject: [IPython-dev] [jupyter] [ANN] IPython 5.0 is out!
In-Reply-To: <CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ=F1Ga1zRFa_Q@mail.gmail.com>
References: <CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ=F1Ga1zRFa_Q@mail.gmail.com>
Message-ID: <CAH4pYpTgvocZq=j9goeBoqsXMV-5qrazB4hw=dFVUxerVtZopA@mail.gmail.com>

Woohoo, long live classic IPython!!!

On Thu, Jul 7, 2016 at 8:09 PM, Fernando Perez <fperez.net at gmail.com> wrote:
> Hi all,
>
> On behalf of the team, I'm delighted to announce the release of IPython 5.0
> today!
>
> As we continue building the broader architecture and tools of Project
> Jupyter, the IPython kernel and shell remain for many python users the
> "beating heart" of Jupyter and the environment they actually use to interact
> with their code every day.
>
> So we continue making the system better, and especially for terminal users
> this release brings some very nice enhancements.
>
> As usual you can try this new release with:
>
> pip install ipython --upgrade
>
> or you can wait a bit for it to propagate to the repositories of your
> favorite packaging system/distribution.
>
> You can find more details at the blog:
> http://blog.jupyter.org/2016/07/08/ipython-5-0-released/
>
> Many thanks to everyone who made this release possible, and in particular to
> Thomas and Matthias who carried the lion's share of the effort to bring us a
> lot of very nice new features, as well as to Jonathan Slenders, the author
> of prompt_toolkit that makes much of the new shiny possible.
>
> Cheers,
>
> f
>
> --
> Fernando Perez (@fperez_org; http://fperez.org)
> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
> fernando.perez-at-berkeley: contact me here for any direct mail
>
> --
> You received this message because you are subscribed to the Google Groups
> "Project Jupyter" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jupyter+unsubscribe at googlegroups.com.
> To post to this group, send email to jupyter at googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jupyter/CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ%3DF1Ga1zRFa_Q%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.



-- 
Brian E. Granger
Associate Professor of Physics and Data Science
Cal Poly State University, San Luis Obispo
@ellisonbg on Twitter and GitHub
bgranger at calpoly.edu and ellisonbg at gmail.com


From bussonniermatthias at gmail.com  Thu Jul  7 23:20:20 2016
From: bussonniermatthias at gmail.com (Matthias Bussonnier)
Date: Thu, 7 Jul 2016 20:20:20 -0700
Subject: [IPython-dev] [jupyter] [ANN] IPython 5.0 is out!
In-Reply-To: <CAH4pYpTgvocZq=j9goeBoqsXMV-5qrazB4hw=dFVUxerVtZopA@mail.gmail.com>
References: <CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ=F1Ga1zRFa_Q@mail.gmail.com>
 <CAH4pYpTgvocZq=j9goeBoqsXMV-5qrazB4hw=dFVUxerVtZopA@mail.gmail.com>
Message-ID: <CANJQusXUtLhMg8VQNyN_JmTWf9aS1O9wSc6cwgVA-z5xAdqbeQ@mail.gmail.com>

Thanks all !

Feel free to report any bugs you have, and make pull requests ! In
hopefully a month-ish, we can release 5.1, and then start working on
6.0 !
-- 
M

On Thu, Jul 7, 2016 at 8:11 PM, Brian Granger <ellisonbg at gmail.com> wrote:
> Woohoo, long live classic IPython!!!
>
> On Thu, Jul 7, 2016 at 8:09 PM, Fernando Perez <fperez.net at gmail.com> wrote:
>> Hi all,
>>
>> On behalf of the team, I'm delighted to announce the release of IPython 5.0
>> today!
>>
>> As we continue building the broader architecture and tools of Project
>> Jupyter, the IPython kernel and shell remain for many python users the
>> "beating heart" of Jupyter and the environment they actually use to interact
>> with their code every day.
>>
>> So we continue making the system better, and especially for terminal users
>> this release brings some very nice enhancements.
>>
>> As usual you can try this new release with:
>>
>> pip install ipython --upgrade
>>
>> or you can wait a bit for it to propagate to the repositories of your
>> favorite packaging system/distribution.
>>
>> You can find more details at the blog:
>> http://blog.jupyter.org/2016/07/08/ipython-5-0-released/
>>
>> Many thanks to everyone who made this release possible, and in particular to
>> Thomas and Matthias who carried the lion's share of the effort to bring us a
>> lot of very nice new features, as well as to Jonathan Slenders, the author
>> of prompt_toolkit that makes much of the new shiny possible.
>>
>> Cheers,
>>
>> f
>>
>> --
>> Fernando Perez (@fperez_org; http://fperez.org)
>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
>> fernando.perez-at-berkeley: contact me here for any direct mail
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Project Jupyter" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to jupyter+unsubscribe at googlegroups.com.
>> To post to this group, send email to jupyter at googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/jupyter/CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ%3DF1Ga1zRFa_Q%40mail.gmail.com.
>> For more options, visit https://groups.google.com/d/optout.
>
>
>
> --
> Brian E. Granger
> Associate Professor of Physics and Data Science
> Cal Poly State University, San Luis Obispo
> @ellisonbg on Twitter and GitHub
> bgranger at calpoly.edu and ellisonbg at gmail.com
>
> --
> You received this message because you are subscribed to the Google Groups "Project Jupyter" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to jupyter+unsubscribe at googlegroups.com.
> To post to this group, send email to jupyter at googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/jupyter/CAH4pYpTgvocZq%3Dj9goeBoqsXMV-5qrazB4hw%3DdFVUxerVtZopA%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.


From wes.turner at gmail.com  Fri Jul  8 00:18:58 2016
From: wes.turner at gmail.com (Wes Turner)
Date: Thu, 7 Jul 2016 23:18:58 -0500
Subject: [IPython-dev] [ANN] IPython 5.0 is out!
In-Reply-To: <CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ=F1Ga1zRFa_Q@mail.gmail.com>
References: <CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ=F1Ga1zRFa_Q@mail.gmail.com>
Message-ID: <CACfEFw_8XOOhktsC7Um8UPSuVyUAZVWY18u76kpKEHzQVOtvBg@mail.gmail.com>

I'm pretty excited about the upgrade from readline to prompt_toolkit:

* https://pypi.python.org/pypi/prompt_toolkit

On Thu, Jul 7, 2016 at 10:09 PM, Fernando Perez <fperez.net at gmail.com>
wrote:

> Hi all,
>
> On behalf of the team, I'm delighted to announce the release of IPython
> 5.0 today!
>
> As we continue building the broader architecture and tools of Project
> Jupyter, the IPython kernel and shell remain for many python users the
> "beating heart" of Jupyter and the environment they actually use to
> interact with their code every day.
>
> So we continue making the system better, and especially for terminal users
> this release brings some very nice enhancements.
>
> As usual you can try this new release with:
>
> pip install ipython --upgrade
>
> or you can wait a bit for it to propagate to the repositories of your
> favorite packaging system/distribution.
>
> You can find more details at the blog:
> http://blog.jupyter.org/2016/07/08/ipython-5-0-released/
>
> Many thanks to everyone who made this release possible, and in particular
> to Thomas and Matthias who carried the lion's share of the effort to bring
> us a lot of very nice new features, as well as to Jonathan Slenders, the
> author of prompt_toolkit that makes much of the new shiny possible.
>
> Cheers,
>
> f
>
> --
> Fernando Perez (@fperez_org; http://fperez.org)
> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
> fernando.perez-at-berkeley: contact me here for any direct mail
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160707/deb39d53/attachment.html>

From francois.dion at gmail.com  Fri Jul  8 07:43:15 2016
From: francois.dion at gmail.com (Francois Dion)
Date: Fri, 08 Jul 2016 07:43:15 -0400
Subject: [IPython-dev] [ANN] IPython 5.0 is out!
In-Reply-To: <CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ=F1Ga1zRFa_Q@mail.gmail.com>
References: <CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ=F1Ga1zRFa_Q@mail.gmail.com>
Message-ID: <20160708114315.5623887.11192.99449@gmail.com>

An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160708/e91d01ea/attachment.html>

From carl.input at gmail.com  Fri Jul  8 08:02:53 2016
From: carl.input at gmail.com (Carl Smith)
Date: Fri, 8 Jul 2016 13:02:53 +0100
Subject: [IPython-dev] [jupyter] [ANN] IPython 5.0 is out!
In-Reply-To: <CANJQusXUtLhMg8VQNyN_JmTWf9aS1O9wSc6cwgVA-z5xAdqbeQ@mail.gmail.com>
References: <CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ=F1Ga1zRFa_Q@mail.gmail.com>
 <CAH4pYpTgvocZq=j9goeBoqsXMV-5qrazB4hw=dFVUxerVtZopA@mail.gmail.com>
 <CANJQusXUtLhMg8VQNyN_JmTWf9aS1O9wSc6cwgVA-z5xAdqbeQ@mail.gmail.com>
Message-ID: <CAP-uhDcgqSxizi4=eF58+7x58StJ5xdmDVbQenPxieo67BuY=w@mail.gmail.com>

IPython 5 is amazing! The switch to prompt_toolkit makes me happy even when
I'm not on my computer. It feels a bit like a war has ended!

Thanks for everything guys.

-- Carl Smith
carl.input at gmail.com

On 8 July 2016 at 04:20, Matthias Bussonnier <bussonniermatthias at gmail.com>
wrote:

> Thanks all !
>
> Feel free to report any bugs you have, and make pull requests ! In
> hopefully a month-ish, we can release 5.1, and then start working on
> 6.0 !
> --
> M
>
> On Thu, Jul 7, 2016 at 8:11 PM, Brian Granger <ellisonbg at gmail.com> wrote:
> > Woohoo, long live classic IPython!!!
> >
> > On Thu, Jul 7, 2016 at 8:09 PM, Fernando Perez <fperez.net at gmail.com>
> wrote:
> >> Hi all,
> >>
> >> On behalf of the team, I'm delighted to announce the release of IPython
> 5.0
> >> today!
> >>
> >> As we continue building the broader architecture and tools of Project
> >> Jupyter, the IPython kernel and shell remain for many python users the
> >> "beating heart" of Jupyter and the environment they actually use to
> interact
> >> with their code every day.
> >>
> >> So we continue making the system better, and especially for terminal
> users
> >> this release brings some very nice enhancements.
> >>
> >> As usual you can try this new release with:
> >>
> >> pip install ipython --upgrade
> >>
> >> or you can wait a bit for it to propagate to the repositories of your
> >> favorite packaging system/distribution.
> >>
> >> You can find more details at the blog:
> >> http://blog.jupyter.org/2016/07/08/ipython-5-0-released/
> >>
> >> Many thanks to everyone who made this release possible, and in
> particular to
> >> Thomas and Matthias who carried the lion's share of the effort to bring
> us a
> >> lot of very nice new features, as well as to Jonathan Slenders, the
> author
> >> of prompt_toolkit that makes much of the new shiny possible.
> >>
> >> Cheers,
> >>
> >> f
> >>
> >> --
> >> Fernando Perez (@fperez_org; http://fperez.org)
> >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
> >> fernando.perez-at-berkeley: contact me here for any direct mail
> >>
> >> --
> >> You received this message because you are subscribed to the Google
> Groups
> >> "Project Jupyter" group.
> >> To unsubscribe from this group and stop receiving emails from it, send
> an
> >> email to jupyter+unsubscribe at googlegroups.com.
> >> To post to this group, send email to jupyter at googlegroups.com.
> >> To view this discussion on the web visit
> >>
> https://groups.google.com/d/msgid/jupyter/CAHAreOpUSwWH7ZUJZ8p7iuHPKV8-7xXEkjXErJ%3DF1Ga1zRFa_Q%40mail.gmail.com
> .
> >> For more options, visit https://groups.google.com/d/optout.
> >
> >
> >
> > --
> > Brian E. Granger
> > Associate Professor of Physics and Data Science
> > Cal Poly State University, San Luis Obispo
> > @ellisonbg on Twitter and GitHub
> > bgranger at calpoly.edu and ellisonbg at gmail.com
> >
> > --
> > You received this message because you are subscribed to the Google
> Groups "Project Jupyter" group.
> > To unsubscribe from this group and stop receiving emails from it, send
> an email to jupyter+unsubscribe at googlegroups.com.
> > To post to this group, send email to jupyter at googlegroups.com.
> > To view this discussion on the web visit
> https://groups.google.com/d/msgid/jupyter/CAH4pYpTgvocZq%3Dj9goeBoqsXMV-5qrazB4hw%3DdFVUxerVtZopA%40mail.gmail.com
> .
> > For more options, visit https://groups.google.com/d/optout.
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160708/0047450f/attachment.html>

From carl.input at gmail.com  Sat Jul  9 10:59:08 2016
From: carl.input at gmail.com (Carl Smith)
Date: Sat, 9 Jul 2016 15:59:08 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
Message-ID: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>

Just been trying to set up a custom prompt with the new prompt_toolkit
features, and couldn't figure it out from the IPython docs. Perhaps adding
an example class would make things clear.

Thanks,
-- Carl Smith
carl.input at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160709/29a9c75c/attachment.html>

From takowl at gmail.com  Sat Jul  9 12:06:43 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Sat, 9 Jul 2016 17:06:43 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
Message-ID: <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>

On 9 July 2016 at 15:59, Carl Smith <carl.input at gmail.com> wrote:

> Just been trying to set up a custom prompt with the new prompt_toolkit
> features, and couldn't figure it out from the IPython docs. Perhaps adding
> an example class would make things clear.


In the absence of examples in the docs, the prompt classes in the code
might be worth a look:

https://github.com/ipython/ipython/blob/master/IPython/terminal/prompts.py
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160709/3f2da9a4/attachment.html>

From carl.input at gmail.com  Sat Jul  9 15:30:17 2016
From: carl.input at gmail.com (Carl Smith)
Date: Sat, 09 Jul 2016 19:30:17 +0000
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
Message-ID: <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>

Thanks Thomas. Appreciated.

On Sat, 9 Jul 2016 17:07 Thomas Kluyver, <takowl at gmail.com> wrote:

> On 9 July 2016 at 15:59, Carl Smith <carl.input at gmail.com> wrote:
>
>> Just been trying to set up a custom prompt with the new prompt_toolkit
>> features, and couldn't figure it out from the IPython docs. Perhaps adding
>> an example class would make things clear.
>
>
> In the absence of examples in the docs, the prompt classes in the code
> might be worth a look:
>
> https://github.com/ipython/ipython/blob/master/IPython/terminal/prompts.py
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160709/11c1bcf4/attachment.html>

From carl.input at gmail.com  Sat Jul  9 19:44:23 2016
From: carl.input at gmail.com (Carl Smith)
Date: Sun, 10 Jul 2016 00:44:23 +0100
Subject: [IPython-dev] Highlighting of paths in commands stopped working.
Message-ID: <CAP-uhDdtzEA2tRR8ktKy6B05sQm6jWMEA6+wPTfd6LwJGSimbg@mail.gmail.com>

When trying out the IPython 5 release candidate, when typing something like
`cd /foo/bar`, the slashes would be a different colour to the rest of the
text. Now using IPython 5 stable, it's all one colour. I can't figure out
why, so wondered if it was changed or if I broke something.

Thanks,
-- Carl Smith
carl.input at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160710/fdbcdb18/attachment.html>

From fperez.net at gmail.com  Sun Jul 10 19:01:08 2016
From: fperez.net at gmail.com (Fernando Perez)
Date: Sun, 10 Jul 2016 16:01:08 -0700
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
Message-ID: <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>

BTW, Carl, if you come up with a nice example that works for you, a small
PR contribution to the docs would be greatly appreciated, so it helps
others in the future!

Cheers

f

On Sat, Jul 9, 2016 at 12:30 PM, Carl Smith <carl.input at gmail.com> wrote:

> Thanks Thomas. Appreciated.
>
> On Sat, 9 Jul 2016 17:07 Thomas Kluyver, <takowl at gmail.com> wrote:
>
>> On 9 July 2016 at 15:59, Carl Smith <carl.input at gmail.com> wrote:
>>
>>> Just been trying to set up a custom prompt with the new prompt_toolkit
>>> features, and couldn't figure it out from the IPython docs. Perhaps adding
>>> an example class would make things clear.
>>
>>
>> In the absence of examples in the docs, the prompt classes in the code
>> might be worth a look:
>>
>> https://github.com/ipython/ipython/blob/master/IPython/terminal/prompts.py
>> _______________________________________________
>> IPython-dev mailing list
>> IPython-dev at scipy.org
>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>


-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160710/7d466e04/attachment.html>

From carl.input at gmail.com  Sun Jul 10 19:11:32 2016
From: carl.input at gmail.com (Carl Smith)
Date: Mon, 11 Jul 2016 00:11:32 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
Message-ID: <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>

No problem at all, Fernando.

I did have a go at it based on the code Thomas pointed to, but couldn't
figure out how to use the reference to `self.shell.execution_count`. When
it's used directly, as it is in the IPython source (passed through `str`),
you end up with something like this:

    In [<traitlets.traitlets.Int at 0x104800b70>]:

Using the `default_value` and `default_value_repr` methods, gives you the
number, but it was always `1`, no matter what the actual input number was.

I'll have another go at it soon, and am happy to add something to the docs
once I figure it out, but just switched to using tmux and the ne editor
this week too, so have a ton of little things to figure out and configure
at the moment.

Best,

-- Carl Smith
carl.input at gmail.com

On 11 July 2016 at 00:01, Fernando Perez <fperez.net at gmail.com> wrote:

> BTW, Carl, if you come up with a nice example that works for you, a small
> PR contribution to the docs would be greatly appreciated, so it helps
> others in the future!
>
> Cheers
>
> f
>
> On Sat, Jul 9, 2016 at 12:30 PM, Carl Smith <carl.input at gmail.com> wrote:
>
>> Thanks Thomas. Appreciated.
>>
>> On Sat, 9 Jul 2016 17:07 Thomas Kluyver, <takowl at gmail.com> wrote:
>>
>>> On 9 July 2016 at 15:59, Carl Smith <carl.input at gmail.com> wrote:
>>>
>>>> Just been trying to set up a custom prompt with the new prompt_toolkit
>>>> features, and couldn't figure it out from the IPython docs. Perhaps adding
>>>> an example class would make things clear.
>>>
>>>
>>> In the absence of examples in the docs, the prompt classes in the code
>>> might be worth a look:
>>>
>>>
>>> https://github.com/ipython/ipython/blob/master/IPython/terminal/prompts.py
>>> _______________________________________________
>>> IPython-dev mailing list
>>> IPython-dev at scipy.org
>>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>>
>>
>> _______________________________________________
>> IPython-dev mailing list
>> IPython-dev at scipy.org
>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>>
>
>
> --
> Fernando Perez (@fperez_org; http://fperez.org)
> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
> fernando.perez-at-berkeley: contact me here for any direct mail
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160711/50eeb42e/attachment.html>

From fperez.net at gmail.com  Sun Jul 10 19:15:38 2016
From: fperez.net at gmail.com (Fernando Perez)
Date: Sun, 10 Jul 2016 16:15:38 -0700
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
Message-ID: <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>

On Sun, Jul 10, 2016 at 4:11 PM, Carl Smith <carl.input at gmail.com> wrote:

> No problem at all, Fernando.
>

Great, thanks!


> I did have a go at it based on the code Thomas pointed to, but couldn't
> figure out how to use the reference to `self.shell.execution_count`. When
> it's used directly, as it is in the IPython source (passed through `str`),
> you end up with something like this:
>
>     In [<traitlets.traitlets.Int at 0x104800b70>]:
>
> Using the `default_value` and `default_value_repr` methods, gives you the
> number, but it was always `1`, no matter what the actual input number was.
>

Mmh, I'm afraid I haven't really done any significant prompt customizations
in years, way before we made the system traitlets-based... I don't have a
quick solution handy.  But let's see if someone else can pitch in and we
get a solution, otherwise I'll try to dig in later...

-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160710/30610629/attachment.html>

From carl.input at gmail.com  Sun Jul 10 19:20:03 2016
From: carl.input at gmail.com (Carl Smith)
Date: Mon, 11 Jul 2016 00:20:03 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
Message-ID: <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>

Thanks Fernando, but please don't put yourself out on my account.
Obviously, it's something that needs figuring out, but there's no urgency
here.

Best,

-- Carl Smith
carl.input at gmail.com

On 11 July 2016 at 00:15, Fernando Perez <fperez.net at gmail.com> wrote:

> On Sun, Jul 10, 2016 at 4:11 PM, Carl Smith <carl.input at gmail.com> wrote:
>
>> No problem at all, Fernando.
>>
>
> Great, thanks!
>
>
>> I did have a go at it based on the code Thomas pointed to, but couldn't
>> figure out how to use the reference to `self.shell.execution_count`. When
>> it's used directly, as it is in the IPython source (passed through `str`),
>> you end up with something like this:
>>
>>     In [<traitlets.traitlets.Int at 0x104800b70>]:
>>
>> Using the `default_value` and `default_value_repr` methods, gives you the
>> number, but it was always `1`, no matter what the actual input number was.
>>
>
> Mmh, I'm afraid I haven't really done any significant prompt
> customizations in years, way before we made the system traitlets-based... I
> don't have a quick solution handy.  But let's see if someone else can pitch
> in and we get a solution, otherwise I'll try to dig in later...
>
> --
> Fernando Perez (@fperez_org; http://fperez.org)
> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
> fernando.perez-at-berkeley: contact me here for any direct mail
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160711/b259b7df/attachment.html>

From carl.input at gmail.com  Sun Jul 10 21:27:52 2016
From: carl.input at gmail.com (Carl Smith)
Date: Mon, 11 Jul 2016 02:27:52 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
Message-ID: <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>

Just to help move things along, this is what I have. It works, except for
the input number always being `1`. I don't know much about some of the
parts, so have no idea why the count doesn't increment.

    import IPython
    from pygments.token import Token

    Prompts = IPython.terminal.prompts.Prompts
    Shell = IPython.terminal.interactiveshell.TerminalInteractiveShell

    class CustomPrompts(Prompts):

        def in_prompt_tokens(self, cli=None): return [
            (Token.Prompt, "CustomIn["),
            (Token.PromptNum, str(self.shell.execution_count)),
            (Token.Prompt, "]: ")
            ]

    get_ipython().prompts = CustomPrompts(Shell())

This code creates an input prompt like `CustomIn[1]: `, but the number is
always `1`. Interestingly, the output prompt, which is inherited
unmodified, is also stuck at `1` now. Everything works correctly; you can
input code and so on, but the execution count never updates.

If anyone has any ideas...

Best,

-- Carl Smith
carl.input at gmail.com

On 11 July 2016 at 00:20, Carl Smith <carl.input at gmail.com> wrote:

> Thanks Fernando, but please don't put yourself out on my account.
> Obviously, it's something that needs figuring out, but there's no urgency
> here.
>
> Best,
>
> -- Carl Smith
> carl.input at gmail.com
>
> On 11 July 2016 at 00:15, Fernando Perez <fperez.net at gmail.com> wrote:
>
>> On Sun, Jul 10, 2016 at 4:11 PM, Carl Smith <carl.input at gmail.com> wrote:
>>
>>> No problem at all, Fernando.
>>>
>>
>> Great, thanks!
>>
>>
>>> I did have a go at it based on the code Thomas pointed to, but couldn't
>>> figure out how to use the reference to `self.shell.execution_count`. When
>>> it's used directly, as it is in the IPython source (passed through `str`),
>>> you end up with something like this:
>>>
>>>     In [<traitlets.traitlets.Int at 0x104800b70>]:
>>>
>>> Using the `default_value` and `default_value_repr` methods, gives you
>>> the number, but it was always `1`, no matter what the actual input number
>>> was.
>>>
>>
>> Mmh, I'm afraid I haven't really done any significant prompt
>> customizations in years, way before we made the system traitlets-based... I
>> don't have a quick solution handy.  But let's see if someone else can pitch
>> in and we get a solution, otherwise I'll try to dig in later...
>>
>> --
>> Fernando Perez (@fperez_org; http://fperez.org)
>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
>> fernando.perez-at-berkeley: contact me here for any direct mail
>>
>> _______________________________________________
>> IPython-dev mailing list
>> IPython-dev at scipy.org
>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160711/b2280215/attachment.html>

From carl.input at gmail.com  Sun Jul 10 22:04:45 2016
From: carl.input at gmail.com (Carl Smith)
Date: Mon, 11 Jul 2016 03:04:45 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
Message-ID: <CAP-uhDdy3ZtKr1b66Ms3Q9pJW0eGD_FG5gNcpNrENa7XpjpNKA@mail.gmail.com>

It seems to be unrelated to the prompt customisation stuff. I removed the
code from my last email, so now have the standard prompt again, but the
execution count still fails to update, even though the prompt is working
properly:

?    ?
In [*1*]: *import* IPython

?    ?
In [*2*]: Shell = IPython.terminal.interactiveshell.TerminalInteractiveShell

?    ?
In [*3*]: shell = Shell()

?    ?
In [*4*]: shell.execution_count

?    ?
Out[*4*]: 1

?    ?
In [*5*]: shell.execution_count

    Out[*5*]: 1

Maybe the prompt class is supposed to increment the count whenever the `
in_prompt_tokens` method is called, but I need to get to bed. It's 3am here.

G'night,

-- Carl Smith
carl.input at gmail.com

On 11 July 2016 at 02:27, Carl Smith <carl.input at gmail.com> wrote:

> Just to help move things along, this is what I have. It works, except for
> the input number always being `1`. I don't know much about some of the
> parts, so have no idea why the count doesn't increment.
>
>     import IPython
>     from pygments.token import Token
>
>     Prompts = IPython.terminal.prompts.Prompts
>     Shell = IPython.terminal.interactiveshell.TerminalInteractiveShell
>
>     class CustomPrompts(Prompts):
>
>         def in_prompt_tokens(self, cli=None): return [
>             (Token.Prompt, "CustomIn["),
>             (Token.PromptNum, str(self.shell.execution_count)),
>             (Token.Prompt, "]: ")
>             ]
>
>     get_ipython().prompts = CustomPrompts(Shell())
>
> This code creates an input prompt like `CustomIn[1]: `, but the number is
> always `1`. Interestingly, the output prompt, which is inherited
> unmodified, is also stuck at `1` now. Everything works correctly; you can
> input code and so on, but the execution count never updates.
>
> If anyone has any ideas...
>
> Best,
>
> -- Carl Smith
> carl.input at gmail.com
>
> On 11 July 2016 at 00:20, Carl Smith <carl.input at gmail.com> wrote:
>
>> Thanks Fernando, but please don't put yourself out on my account.
>> Obviously, it's something that needs figuring out, but there's no urgency
>> here.
>>
>> Best,
>>
>> -- Carl Smith
>> carl.input at gmail.com
>>
>> On 11 July 2016 at 00:15, Fernando Perez <fperez.net at gmail.com> wrote:
>>
>>> On Sun, Jul 10, 2016 at 4:11 PM, Carl Smith <carl.input at gmail.com>
>>> wrote:
>>>
>>>> No problem at all, Fernando.
>>>>
>>>
>>> Great, thanks!
>>>
>>>
>>>> I did have a go at it based on the code Thomas pointed to, but couldn't
>>>> figure out how to use the reference to `self.shell.execution_count`. When
>>>> it's used directly, as it is in the IPython source (passed through `str`),
>>>> you end up with something like this:
>>>>
>>>>     In [<traitlets.traitlets.Int at 0x104800b70>]:
>>>>
>>>> Using the `default_value` and `default_value_repr` methods, gives you
>>>> the number, but it was always `1`, no matter what the actual input number
>>>> was.
>>>>
>>>
>>> Mmh, I'm afraid I haven't really done any significant prompt
>>> customizations in years, way before we made the system traitlets-based... I
>>> don't have a quick solution handy.  But let's see if someone else can pitch
>>> in and we get a solution, otherwise I'll try to dig in later...
>>>
>>> --
>>> Fernando Perez (@fperez_org; http://fperez.org)
>>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
>>> fernando.perez-at-berkeley: contact me here for any direct mail
>>>
>>> _______________________________________________
>>> IPython-dev mailing list
>>> IPython-dev at scipy.org
>>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160711/d0b996bd/attachment.html>

From bussonniermatthias at gmail.com  Mon Jul 11 00:25:06 2016
From: bussonniermatthias at gmail.com (Matthias Bussonnier)
Date: Sun, 10 Jul 2016 21:25:06 -0700
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDdy3ZtKr1b66Ms3Q9pJW0eGD_FG5gNcpNrENa7XpjpNKA@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAP-uhDdy3ZtKr1b66Ms3Q9pJW0eGD_FG5gNcpNrENa7XpjpNKA@mail.gmail.com>
Message-ID: <CANJQusUoVLt+KTuR_NtoEB3paJx+RsbRCeC4bC2cYDP_SOY2Rw@mail.gmail.com>

https://github.com/asmeurer/iterm2-tools. Might be a good resource if you
looks at (unfinished) PR.

This week is SciPy, so I'll be low bandwidth, but if you issue a draft
example PR, I can an try to review.
-- 
M
On Jul 10, 2016 19:04, "Carl Smith" <carl.input at gmail.com> wrote:

> It seems to be unrelated to the prompt customisation stuff. I removed the
> code from my last email, so now have the standard prompt again, but the
> execution count still fails to update, even though the prompt is working
> properly:
>
> ?    ?
> In [*1*]: *import* IPython
>
> ?    ?
> In [*2*]: Shell =
> IPython.terminal.interactiveshell.TerminalInteractiveShell
>
> ?    ?
> In [*3*]: shell = Shell()
>
> ?    ?
> In [*4*]: shell.execution_count
>
> ?    ?
> Out[*4*]: 1
>
> ?    ?
> In [*5*]: shell.execution_count
>
>     Out[*5*]: 1
>
> Maybe the prompt class is supposed to increment the count whenever the `
> in_prompt_tokens` method is called, but I need to get to bed. It's 3am
> here.
>
> G'night,
>
> -- Carl Smith
> carl.input at gmail.com
>
> On 11 July 2016 at 02:27, Carl Smith <carl.input at gmail.com> wrote:
>
>> Just to help move things along, this is what I have. It works, except for
>> the input number always being `1`. I don't know much about some of the
>> parts, so have no idea why the count doesn't increment.
>>
>>     import IPython
>>     from pygments.token import Token
>>
>>     Prompts = IPython.terminal.prompts.Prompts
>>     Shell = IPython.terminal.interactiveshell.TerminalInteractiveShell
>>
>>     class CustomPrompts(Prompts):
>>
>>         def in_prompt_tokens(self, cli=None): return [
>>             (Token.Prompt, "CustomIn["),
>>             (Token.PromptNum, str(self.shell.execution_count)),
>>             (Token.Prompt, "]: ")
>>             ]
>>
>>     get_ipython().prompts = CustomPrompts(Shell())
>>
>> This code creates an input prompt like `CustomIn[1]: `, but the number is
>> always `1`. Interestingly, the output prompt, which is inherited
>> unmodified, is also stuck at `1` now. Everything works correctly; you can
>> input code and so on, but the execution count never updates.
>>
>> If anyone has any ideas...
>>
>> Best,
>>
>> -- Carl Smith
>> carl.input at gmail.com
>>
>> On 11 July 2016 at 00:20, Carl Smith <carl.input at gmail.com> wrote:
>>
>>> Thanks Fernando, but please don't put yourself out on my account.
>>> Obviously, it's something that needs figuring out, but there's no urgency
>>> here.
>>>
>>> Best,
>>>
>>> -- Carl Smith
>>> carl.input at gmail.com
>>>
>>> On 11 July 2016 at 00:15, Fernando Perez <fperez.net at gmail.com> wrote:
>>>
>>>> On Sun, Jul 10, 2016 at 4:11 PM, Carl Smith <carl.input at gmail.com>
>>>> wrote:
>>>>
>>>>> No problem at all, Fernando.
>>>>>
>>>>
>>>> Great, thanks!
>>>>
>>>>
>>>>> I did have a go at it based on the code Thomas pointed to, but
>>>>> couldn't figure out how to use the reference to
>>>>> `self.shell.execution_count`. When it's used directly, as it is in the
>>>>> IPython source (passed through `str`), you end up with something like this:
>>>>>
>>>>>     In [<traitlets.traitlets.Int at 0x104800b70>]:
>>>>>
>>>>> Using the `default_value` and `default_value_repr` methods, gives you
>>>>> the number, but it was always `1`, no matter what the actual input number
>>>>> was.
>>>>>
>>>>
>>>> Mmh, I'm afraid I haven't really done any significant prompt
>>>> customizations in years, way before we made the system traitlets-based... I
>>>> don't have a quick solution handy.  But let's see if someone else can pitch
>>>> in and we get a solution, otherwise I'll try to dig in later...
>>>>
>>>> --
>>>> Fernando Perez (@fperez_org; http://fperez.org)
>>>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
>>>> fernando.perez-at-berkeley: contact me here for any direct mail
>>>>
>>>> _______________________________________________
>>>> IPython-dev mailing list
>>>> IPython-dev at scipy.org
>>>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>>>
>>>>
>>>
>>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160710/4b4b35e7/attachment.html>

From takowl at gmail.com  Mon Jul 11 08:00:43 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Mon, 11 Jul 2016 13:00:43 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
Message-ID: <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>

On 11 July 2016 at 02:27, Carl Smith <carl.input at gmail.com> wrote:

> get_ipython().prompts = CustomPrompts(Shell())
>

Don't instantiate a new shell - the value you get from get_ipython() is the
active shell. So do this:

ip = get_ipython()
ip.prompts = CustomPrompts(ip)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160711/394cfaf2/attachment.html>

From carl.input at gmail.com  Mon Jul 11 16:12:19 2016
From: carl.input at gmail.com (Carl Smith)
Date: Mon, 11 Jul 2016 20:12:19 +0000
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
Message-ID: <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>

I think the problem stems from what Thomas said: There's one shell
executing code, and another just sat around doing nothing. It's the later
one that the CustomPrompt class has a reference to.

On the PR, should I put the example code right there in the docs, where the
API is explained, or is there a wiki or something? Happy either way. Just
unsure what's correct these days.

Cheers,

On Mon, 11 Jul 2016 13:01 Thomas Kluyver, <takowl at gmail.com> wrote:

> On 11 July 2016 at 02:27, Carl Smith <carl.input at gmail.com> wrote:
>
>> get_ipython().prompts = CustomPrompts(Shell())
>>
>
> Don't instantiate a new shell - the value you get from get_ipython() is
> the active shell. So do this:
>
> ip = get_ipython()
> ip.prompts = CustomPrompts(ip)
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160711/cecffed1/attachment.html>

From fperez.net at gmail.com  Mon Jul 11 16:17:43 2016
From: fperez.net at gmail.com (Fernando Perez)
Date: Mon, 11 Jul 2016 13:17:43 -0700
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
 <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
Message-ID: <CAHAreOrYzeg5CPzSqkXaXbmpwJ+qFoB5xswQvBGhA_GxcMXLxA@mail.gmail.com>

On Mon, Jul 11, 2016 at 1:12 PM, Carl Smith <carl.input at gmail.com> wrote:

> On the PR, should I put the example code right there in the docs, where
> the API is explained, or is there a wiki or something? Happy either way.
> Just unsure what's correct these days.
>
>
Best to put it in the docs themselves... Wikis tend to go stale more easily
without active curation, and ours is no exception :)


-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160711/70d82392/attachment.html>

From takowl at gmail.com  Mon Jul 11 16:20:10 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Mon, 11 Jul 2016 21:20:10 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
 <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
Message-ID: <CAOvn4qie5ETpy_fk5cqdYo4J+tJ1tEH4yP6p6iAe8OuWLi+Uug@mail.gmail.com>

On 11 July 2016 at 21:12, Carl Smith <carl.input at gmail.com> wrote:

> On the PR, should I put the example code right there in the docs, where
> the API is explained, or is there a wiki or something? Happy either way.
> Just unsure what's correct these days.


In the docs themselves would be great - thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160711/ff24a513/attachment.html>

From carl.input at gmail.com  Tue Jul 12 20:34:39 2016
From: carl.input at gmail.com (Carl Smith)
Date: Wed, 13 Jul 2016 01:34:39 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAOvn4qie5ETpy_fk5cqdYo4J+tJ1tEH4yP6p6iAe8OuWLi+Uug@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
 <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
 <CAOvn4qie5ETpy_fk5cqdYo4J+tJ1tEH4yP6p6iAe8OuWLi+Uug@mail.gmail.com>
Message-ID: <CAP-uhDekcufC3OC1r5epM=UKMOHv+DxaMudtfKLkggFb1s=YDA@mail.gmail.com>

It's working now. Thanks for your help with that. It was what Thomas said.

Looking through the IPython repo, it turns out there's already a commit
that added a couple of examples of how to do this, so maybe just need to
move some existing stuff around. If I'd found those examples, and the link
Thomas suggested (to the default class definition), it would have been easy
to figure out from there.

The commit that adds the examples:
https://github.com/ipython/ipython/commit/95ed0855ae23e55c10b46903db911265aa1cdd58#diff-c5d5abe11d1c298906cb121c45eb12e2

I did put a simple example together before I saw those, and you're welcome
to use it too. It just creates more minimal versions of the standard
prompts to save some space:

[*1*]* $ def* *inc*(x):
    *$*     *return* x + 1
    *$*


[*2*] *$* inc 1
*---->* inc(1)
[*2] :* 2

The code is pretty compact too:

*from IPython.terminal.prompts import Prompts, Token*

*class CustomPrompts(Prompts):*

*    def in_prompt_tokens(self, cli=None): return [*
*        (Token.Prompt, "["),*
*        (Token.PromptNum, str(self.shell.execution_count)),*
*        (Token.Prompt, "] $ ")*
*        ]*

*    def out_prompt_tokens(self): return [*
*        (Token.OutPrompt, "["),*
*        (Token.OutPromptNum, str(self.shell.execution_count)),*
*        (Token.OutPrompt, "] : ")*
*        ]*

*    def continuation_prompt_tokens(self, cli=None, width=None):*
*        if width is None: width = self._width()*
*        return [(Token.Prompt, " " * (width - 5) + "   $ ")]*

*ip = get_ipython()*
*ip.prompts = CustomPrompts(ip)*

One thing I found buggy was the rewrite prompt. If you inherit from
`Prompt` and redefine some of the prompt methods in the derived class, as
you're meant to do, any prompts that you inherit from `Prompt` will pad
themselves out to keep everything aligned. This works well except when you
have a multiline prompt.

Prompts can get pretty lengthy, and you don't really want multiline inputs
starting at column 50, so two-line prompts with a really short second line
will be fairly common.

If you create a multiline Input prompt, the rewrite prompt will end up
being too long. The math in the token assumes the Input prompt is all on
one line.

def rewrite_prompt_tokens(self): width = self._width() return [
(Token.Prompt, ('-' * (width - 2)) + '> '), ]

I'm happy to do some work on the docs, but not sure what should be done
exactly. It's getting late here again (1:30am), so it'll have to be
tomorrow now anyway.

Best,


-- Carl Smith
carl.input at gmail.com

On 11 July 2016 at 21:20, Thomas Kluyver <takowl at gmail.com> wrote:

> On 11 July 2016 at 21:12, Carl Smith <carl.input at gmail.com> wrote:
>
>> On the PR, should I put the example code right there in the docs, where
>> the API is explained, or is there a wiki or something? Happy either way.
>> Just unsure what's correct these days.
>
>
> In the docs themselves would be great - thanks!
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160713/4c2fa9fd/attachment.html>

From achi at hush.ai  Wed Jul 13 01:33:14 2016
From: achi at hush.ai (Yuri Numerov)
Date: Wed, 13 Jul 2016 07:33:14 +0200
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDekcufC3OC1r5epM=UKMOHv+DxaMudtfKLkggFb1s=YDA@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
 <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
 <CAOvn4qie5ETpy_fk5cqdYo4J+tJ1tEH4yP6p6iAe8OuWLi+Uug@mail.gmail.com>
 <CAP-uhDekcufC3OC1r5epM=UKMOHv+DxaMudtfKLkggFb1s=YDA@mail.gmail.com> 
Message-ID: <20160713053314.EDE9BE0372@smtp.hushmail.com>

Thanks a ton for this Carl, I spent some time trying to figure this out myself when ipython 5 came out without luck :)

On 13/07/2016 at 2:34 AM, "Carl Smith" <carl.input at gmail.com> wrote:
>
>It's working now. Thanks for your help with that. It was what 
>Thomas said.
>
>Looking through the IPython repo, it turns out there's already a 
>commit
>that added a couple of examples of how to do this, so maybe just 
>need to
>move some existing stuff around. If I'd found those examples, and 
>the link
>Thomas suggested (to the default class definition), it would have 
>been easy
>to figure out from there.
>
>The commit that adds the examples:
>https://github.com/ipython/ipython/commit/95ed0855ae23e55c10b46903d
>b911265aa1cdd58#diff-c5d5abe11d1c298906cb121c45eb12e2
>
>I did put a simple example together before I saw those, and you're 
>welcome
>to use it too. It just creates more minimal versions of the 
>standard
>prompts to save some space:
>
>[*1*]* $ def* *inc*(x):
>    *$*     *return* x + 1
>    *$*
>
>
>[*2*] *$* inc 1
>*---->* inc(1)
>[*2] :* 2
>
>The code is pretty compact too:
>
>*from IPython.terminal.prompts import Prompts, Token*
>
>*class CustomPrompts(Prompts):*
>
>*    def in_prompt_tokens(self, cli=None): return [*
>*        (Token.Prompt, "["),*
>*        (Token.PromptNum, str(self.shell.execution_count)),*
>*        (Token.Prompt, "] $ ")*
>*        ]*
>
>*    def out_prompt_tokens(self): return [*
>*        (Token.OutPrompt, "["),*
>*        (Token.OutPromptNum, str(self.shell.execution_count)),*
>*        (Token.OutPrompt, "] : ")*
>*        ]*
>
>*    def continuation_prompt_tokens(self, cli=None, width=None):*
>*        if width is None: width = self._width()*
>*        return [(Token.Prompt, " " * (width - 5) + "   $ ")]*
>
>*ip = get_ipython()*
>*ip.prompts = CustomPrompts(ip)*
>
>One thing I found buggy was the rewrite prompt. If you inherit from
>`Prompt` and redefine some of the prompt methods in the derived 
>class, as
>you're meant to do, any prompts that you inherit from `Prompt` 
>will pad
>themselves out to keep everything aligned. This works well except 
>when you
>have a multiline prompt.
>
>Prompts can get pretty lengthy, and you don't really want 
>multiline inputs
>starting at column 50, so two-line prompts with a really short 
>second line
>will be fairly common.
>
>If you create a multiline Input prompt, the rewrite prompt will 
>end up
>being too long. The math in the token assumes the Input prompt is 
>all on
>one line.
>
>def rewrite_prompt_tokens(self): width = self._width() return [
>(Token.Prompt, ('-' * (width - 2)) + '> '), ]
>
>I'm happy to do some work on the docs, but not sure what should be 
>done
>exactly. It's getting late here again (1:30am), so it'll have to be
>tomorrow now anyway.
>
>Best,
>
>
>-- Carl Smith
>carl.input at gmail.com
>
>On 11 July 2016 at 21:20, Thomas Kluyver <takowl at gmail.com> wrote:
>
>> On 11 July 2016 at 21:12, Carl Smith <carl.input at gmail.com> 
>wrote:
>>
>>> On the PR, should I put the example code right there in the 
>docs, where
>>> the API is explained, or is there a wiki or something? Happy 
>either way.
>>> Just unsure what's correct these days.
>>
>>
>> In the docs themselves would be great - thanks!
>>
>> _______________________________________________
>> IPython-dev mailing list
>> IPython-dev at scipy.org
>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>>



From takowl at gmail.com  Wed Jul 13 06:38:10 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Wed, 13 Jul 2016 11:38:10 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDekcufC3OC1r5epM=UKMOHv+DxaMudtfKLkggFb1s=YDA@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
 <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
 <CAOvn4qie5ETpy_fk5cqdYo4J+tJ1tEH4yP6p6iAe8OuWLi+Uug@mail.gmail.com>
 <CAP-uhDekcufC3OC1r5epM=UKMOHv+DxaMudtfKLkggFb1s=YDA@mail.gmail.com>
Message-ID: <CAOvn4qi5mPWL1UgN5R=0OKnyjmft4xqtnmi1PT0axgysgV=pWg@mail.gmail.com>

Thanks Carl!

On 13 July 2016 at 01:34, Carl Smith <carl.input at gmail.com> wrote:

> The commit that adds the examples:
>
> https://github.com/ipython/ipython/commit/95ed0855ae23e55c10b46903db911265aa1cdd58#diff-c5d5abe11d1c298906cb121c45eb12e2
>

Sigh, of course we have docs on customising prompts in two places. I'll try
to unify them...


> One thing I found buggy was the rewrite prompt. If you inherit from
> `Prompt` and redefine some of the prompt methods in the derived class, as
> you're meant to do, any prompts that you inherit from `Prompt` will pad
> themselves out to keep everything aligned. This works well except when you
> have a multiline prompt.
>

Yes, I think the prompt is conceptually a single line. Does the information
in the lines above where you type need to change while you're typing? If
not, I'd recommend printing it before the prompt is displayed with the
post_run_cell event (
http://ipython.readthedocs.io/en/stable/config/callbacks.html).

Thomas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160713/645869a2/attachment.html>

From carl.input at gmail.com  Wed Jul 13 12:44:18 2016
From: carl.input at gmail.com (Carl Smith)
Date: Wed, 13 Jul 2016 17:44:18 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAOvn4qi5mPWL1UgN5R=0OKnyjmft4xqtnmi1PT0axgysgV=pWg@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
 <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
 <CAOvn4qie5ETpy_fk5cqdYo4J+tJ1tEH4yP6p6iAe8OuWLi+Uug@mail.gmail.com>
 <CAP-uhDekcufC3OC1r5epM=UKMOHv+DxaMudtfKLkggFb1s=YDA@mail.gmail.com>
 <CAOvn4qi5mPWL1UgN5R=0OKnyjmft4xqtnmi1PT0axgysgV=pWg@mail.gmail.com>
Message-ID: <CAP-uhDfKwxeUzaYHgG7469-uD67Ub5XxY3bk89K1maq4D+6NFA@mail.gmail.com>

No problem, Yuri - mostly just followed Thomas' pointers.

Thanks again, Thomas. Yep - printing the first line of the prompt from a
callback should work fine. I didn't think about the event API.

The current API for defining custom prompts is powerful, but pretty low
level, and it becomes more complicated if you need custom token classes to
use different colours. It'd be nice if there was also a wrapper API that
would take strings, like bash prompts, and parse them into prompt_toolkit
token arrays and plumb them in automatically.

The actual format used in bash prompts makes it awkward to define styles,
so I was thinking about reusing Python's string formatting mini-language,
and just defining a standard signature that will pass a bunch of helpful
stuff to `format` when the prompt is compiled.

No promises, but I'm going to play around with the new prompt API a bit
more and see if there's a light way to wrap the current API.

Cheers,


-- Carl Smith
carl.input at gmail.com

On 13 July 2016 at 11:38, Thomas Kluyver <takowl at gmail.com> wrote:

> Thanks Carl!
>
> On 13 July 2016 at 01:34, Carl Smith <carl.input at gmail.com> wrote:
>
>> The commit that adds the examples:
>>
>> https://github.com/ipython/ipython/commit/95ed0855ae23e55c10b46903db911265aa1cdd58#diff-c5d5abe11d1c298906cb121c45eb12e2
>>
>
> Sigh, of course we have docs on customising prompts in two places. I'll
> try to unify them...
>
>
>> One thing I found buggy was the rewrite prompt. If you inherit from
>> `Prompt` and redefine some of the prompt methods in the derived class, as
>> you're meant to do, any prompts that you inherit from `Prompt` will pad
>> themselves out to keep everything aligned. This works well except when you
>> have a multiline prompt.
>>
>
> Yes, I think the prompt is conceptually a single line. Does the
> information in the lines above where you type need to change while you're
> typing? If not, I'd recommend printing it before the prompt is displayed
> with the post_run_cell event (
> http://ipython.readthedocs.io/en/stable/config/callbacks.html).
>
> Thomas
>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160713/74549f15/attachment.html>

From fperez.net at gmail.com  Wed Jul 13 14:45:07 2016
From: fperez.net at gmail.com (Fernando Perez)
Date: Wed, 13 Jul 2016 11:45:07 -0700
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAOvn4qi5mPWL1UgN5R=0OKnyjmft4xqtnmi1PT0axgysgV=pWg@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
 <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
 <CAOvn4qie5ETpy_fk5cqdYo4J+tJ1tEH4yP6p6iAe8OuWLi+Uug@mail.gmail.com>
 <CAP-uhDekcufC3OC1r5epM=UKMOHv+DxaMudtfKLkggFb1s=YDA@mail.gmail.com>
 <CAOvn4qi5mPWL1UgN5R=0OKnyjmft4xqtnmi1PT0axgysgV=pWg@mail.gmail.com>
Message-ID: <CAHAreOpTr0GsPwa8OHERQOaGHiafcw_NBYKT3-jfKueYWAETSw@mail.gmail.com>

On Wed, Jul 13, 2016 at 3:38 AM, Thomas Kluyver <takowl at gmail.com> wrote:

> Yes, I think the prompt is conceptually a single line. Does the
> information in the lines above where you type need to change while you're
> typing? If not, I'd recommend printing it before the prompt is displayed
> with the post_run_cell event (
> http://ipython.readthedocs.io/en/stable/config/callbacks.html).
>

Mmh, should we update the rewrite logic to basically work only on the last
line of the prompt? It could compute the length to write on prompt_string.
split('\n')[-1] rather than the full prompt_string. It seems to me that
would give us the correct logic in all cases (including single line
prompts), no?

-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160713/c51ea215/attachment.html>

From carl.input at gmail.com  Wed Jul 13 16:04:39 2016
From: carl.input at gmail.com (Carl Smith)
Date: Wed, 13 Jul 2016 21:04:39 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAHAreOpTr0GsPwa8OHERQOaGHiafcw_NBYKT3-jfKueYWAETSw@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
 <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
 <CAOvn4qie5ETpy_fk5cqdYo4J+tJ1tEH4yP6p6iAe8OuWLi+Uug@mail.gmail.com>
 <CAP-uhDekcufC3OC1r5epM=UKMOHv+DxaMudtfKLkggFb1s=YDA@mail.gmail.com>
 <CAOvn4qi5mPWL1UgN5R=0OKnyjmft4xqtnmi1PT0axgysgV=pWg@mail.gmail.com>
 <CAHAreOpTr0GsPwa8OHERQOaGHiafcw_NBYKT3-jfKueYWAETSw@mail.gmail.com>
Message-ID: <CAP-uhDfBrSB7EZW2GBEjP86=7=gpEEi0K9pBBHuGJrS=wHPoew@mail.gmail.com>

On 13 July 2016 at 19:45, Fernando Perez <fperez.net at gmail.com> wrote:

>
> On Wed, Jul 13, 2016 at 3:38 AM, Thomas Kluyver <takowl at gmail.com> wrote:
>
>> Yes, I think the prompt is conceptually a single line. Does the
>> information in the lines above where you type need to change while you're
>> typing? If not, I'd recommend printing it before the prompt is displayed
>> with the post_run_cell event (
>> http://ipython.readthedocs.io/en/stable/config/callbacks.html).
>>
>
> Mmh, should we update the rewrite logic to basically work only on the last
> line of the prompt? It could compute the length to write on prompt_string.
> split('\n')[-1] rather than the full prompt_string. It seems to me that
> would give us the correct logic in all cases (including single line
> prompts), no?
>

?+1 Yep. Basically, it's always going to be last line you want to align to,
whether there's one or more.

Obviously, users should be able to just define their prompt using the API,
instead of defining half the prompt as a print call that happens once per
input on a callback, and the other half as an arrays of tokens that are
generated by a method every time you edit the input.

Not many people will need this functionality, but it should work correctly
if they ever do.

-- Carl Smith
carl.input at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160713/9189f11e/attachment.html>

From carl.input at gmail.com  Wed Jul 13 16:07:55 2016
From: carl.input at gmail.com (Carl Smith)
Date: Wed, 13 Jul 2016 21:07:55 +0100
Subject: [IPython-dev] [IPython 5] [Docs] Custom Terminal Prompts
In-Reply-To: <CAP-uhDfBrSB7EZW2GBEjP86=7=gpEEi0K9pBBHuGJrS=wHPoew@mail.gmail.com>
References: <CAP-uhDcyafLJCybO4H6Nttb9WEzVeROR7qZth9eS634RtFUAmw@mail.gmail.com>
 <CAOvn4qjM=WerCwacY3eN-FpOiPVVP30NwrtSEAsZ_eipVcMFXQ@mail.gmail.com>
 <CAP-uhDdx51GnQzn9c4R-50FUsD941c25NSjunnftYQkZN7pc9A@mail.gmail.com>
 <CAHAreOoKYeSOGsbYb750wd6g2i3xtYvtamh7wam4sxGDv1DMzw@mail.gmail.com>
 <CAP-uhDcKL1NDt_VGP0Bk1hH7w=a2FzS2ms0h-2ucpmA+xwaamg@mail.gmail.com>
 <CAHAreOrAk1LPu-7dAkqfaKMV8VBAPk3JchcfDD5pvwVfmg1G2A@mail.gmail.com>
 <CAP-uhDczbZFa-KhmT6gVH8TL7iVf+j99JgmEBh8OEvPE6ott7w@mail.gmail.com>
 <CAP-uhDdiPPeQ6Mbb=_ORFzOkAKhcO8EX8CjNXB90k914D5c3sg@mail.gmail.com>
 <CAOvn4qi8y1MaJAxyet6Bh0X1_hzmQ7ANWb-g-evuPu+6MjHYsA@mail.gmail.com>
 <CAP-uhDeCWF9uqzN8bzSHqwWhcv-JMnVysFH7NogwD3sdehhNJw@mail.gmail.com>
 <CAOvn4qie5ETpy_fk5cqdYo4J+tJ1tEH4yP6p6iAe8OuWLi+Uug@mail.gmail.com>
 <CAP-uhDekcufC3OC1r5epM=UKMOHv+DxaMudtfKLkggFb1s=YDA@mail.gmail.com>
 <CAOvn4qi5mPWL1UgN5R=0OKnyjmft4xqtnmi1PT0axgysgV=pWg@mail.gmail.com>
 <CAHAreOpTr0GsPwa8OHERQOaGHiafcw_NBYKT3-jfKueYWAETSw@mail.gmail.com>
 <CAP-uhDfBrSB7EZW2GBEjP86=7=gpEEi0K9pBBHuGJrS=wHPoew@mail.gmail.com>
Message-ID: <CAP-uhDd0ZySMY051JZ=Aj8a3TJtab1P++ALKyZrmPBxVQUQCuA@mail.gmail.com>

On 13 July 2016 at 21:04, Carl Smith <carl.input at gmail.com> wrote:

>
> Not many people will need this functionality, but it should work correctly
> if they ever do.
>

?I meant that not many people will need a multiline prompt that updates
while they edit their input. There will probably be significant minority of
users ?that will want a multiline prompt at some point.

-- Carl Smith
carl.input at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160713/df8bcea0/attachment.html>

From klonuo at gmail.com  Fri Jul 15 02:22:51 2016
From: klonuo at gmail.com (klo uo)
Date: Fri, 15 Jul 2016 08:22:51 +0200
Subject: [IPython-dev] Where does IPython look for info when trying to
	connect to kernel
Message-ID: <CAA-8Ld9Zwocu21H_U7TNNUPAq3OrZXDHjYHMKF1ABSw9_f_fEQ@mail.gmail.com>

I start kernel:

========================================
> ipython kernel
NOTE: When using the `ipython kernel` entry point, Ctrl-C will not work.

To exit, you will have to explicitly quit this process, by either sending
"quit" from a client, or using Ctrl-\ in UNIX-like environments.

To read more about this, see https://github.com/ipython/ipython/issues/2049


To connect another client to this kernel, use:
    --existing kernel-10128.json
========================================

Where is "kernel-10128.json" located?

I dont see it in ~/.ipython/profile_default/security nor anywhere in
~/ipython subfolders nor in temp location.

If I try with `ipython console --existing` I connect successfully, but not
from IPython instance that I point to custom path with IPYTHONDIR env (path
that kernel instance is using).

If last sentence is confusing, ignore it, I'm just interested where is this
file located?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160715/2afb406c/attachment.html>

From takowl at gmail.com  Fri Jul 15 07:38:39 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Fri, 15 Jul 2016 12:38:39 +0100
Subject: [IPython-dev] Where does IPython look for info when trying to
 connect to kernel
In-Reply-To: <CAA-8Ld9Zwocu21H_U7TNNUPAq3OrZXDHjYHMKF1ABSw9_f_fEQ@mail.gmail.com>
References: <CAA-8Ld9Zwocu21H_U7TNNUPAq3OrZXDHjYHMKF1ABSw9_f_fEQ@mail.gmail.com>
Message-ID: <CAOvn4qgOSkgsS5hvN3AErovuMiy-PWE5XO=Vb=4P6D0n16MgiQ@mail.gmail.com>

On 15 July 2016 at 07:22, klo uo <klonuo at gmail.com> wrote:

> Where is "kernel-10128.json" located?
>
> I dont see it in ~/.ipython/profile_default/security nor anywhere in
> ~/ipython subfolders nor in temp location.
>

Sorry for the confusion. When IPython and Jupyter split, the general idea
of kernels and connection files went to Jupyter. IPython provides a
specific Jupyter kernel for running Python code.

You can see where connection files live on your platform by running:

jupyter --runtime-dir
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160715/abf43c0a/attachment.html>

From klonuo at gmail.com  Fri Jul 15 08:07:33 2016
From: klonuo at gmail.com (klo uo)
Date: Fri, 15 Jul 2016 14:07:33 +0200
Subject: [IPython-dev] Where does IPython look for info when trying to
 connect to kernel
In-Reply-To: <CAOvn4qgOSkgsS5hvN3AErovuMiy-PWE5XO=Vb=4P6D0n16MgiQ@mail.gmail.com>
References: <CAA-8Ld9Zwocu21H_U7TNNUPAq3OrZXDHjYHMKF1ABSw9_f_fEQ@mail.gmail.com>
 <CAOvn4qgOSkgsS5hvN3AErovuMiy-PWE5XO=Vb=4P6D0n16MgiQ@mail.gmail.com>
Message-ID: <CAA-8Ld_Jc=dyM1YiMv9BMU1w5bAkUtuRGGhm92F2T0hC8yBpXg@mail.gmail.com>

Thanks Thomas

So on my Windows default location is "%appdata%\jupyter\runtime"

Do you perhaps know if jupyter accepts custom default location, as it was
with IPYTHONDIR for ipython, or should I ask on jupyter list?

On Fri, Jul 15, 2016 at 1:38 PM, Thomas Kluyver <takowl at gmail.com> wrote:

> On 15 July 2016 at 07:22, klo uo <klonuo at gmail.com> wrote:
>
>> Where is "kernel-10128.json" located?
>>
>> I dont see it in ~/.ipython/profile_default/security nor anywhere in
>> ~/ipython subfolders nor in temp location.
>>
>
> Sorry for the confusion. When IPython and Jupyter split, the general idea
> of kernels and connection files went to Jupyter. IPython provides a
> specific Jupyter kernel for running Python code.
>
> You can see where connection files live on your platform by running:
>
> jupyter --runtime-dir
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160715/07203af3/attachment.html>

From takowl at gmail.com  Fri Jul 15 08:10:34 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Fri, 15 Jul 2016 13:10:34 +0100
Subject: [IPython-dev] Where does IPython look for info when trying to
 connect to kernel
In-Reply-To: <CAA-8Ld_Jc=dyM1YiMv9BMU1w5bAkUtuRGGhm92F2T0hC8yBpXg@mail.gmail.com>
References: <CAA-8Ld9Zwocu21H_U7TNNUPAq3OrZXDHjYHMKF1ABSw9_f_fEQ@mail.gmail.com>
 <CAOvn4qgOSkgsS5hvN3AErovuMiy-PWE5XO=Vb=4P6D0n16MgiQ@mail.gmail.com>
 <CAA-8Ld_Jc=dyM1YiMv9BMU1w5bAkUtuRGGhm92F2T0hC8yBpXg@mail.gmail.com>
Message-ID: <CAOvn4qhU6t3iS_M4ao12gQPxxRe=__HmEbN2iv4meOaYyU71pw@mail.gmail.com>

On 15 July 2016 at 13:07, klo uo <klonuo at gmail.com> wrote:

> Do you perhaps know if jupyter accepts custom default location, as it was
> with IPYTHONDIR for ipython, or should I ask on jupyter list?


Yes, there's a JUPYTER_RUNTIME_DIR environment variable. Docs here:
http://jupyter.readthedocs.io/en/latest/projects/jupyter-directories.html#runtime-files
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160715/25541c97/attachment.html>

From thorin at broadinstitute.org  Fri Jul 15 12:48:01 2016
From: thorin at broadinstitute.org (Thorin Tabor)
Date: Fri, 15 Jul 2016 09:48:01 -0700
Subject: [IPython-dev] JupyterHub & TLS 1.2
Message-ID: <a5e2ee8b-8b18-52a5-b53e-8250b6a3fe13@broadinstitute.org>

I'm running JupyterHub through HTTPS and need to configure it to only 
use TLS 1.2. Is there a reasonable to do that?

I noticed that Jupyter has an ssl_options config setting that's passed 
to the underlying tornado server, but thus far I haven't seen an 
equivalent in JupyterHub. Ideally I'd like to just be able to run

    ssl_options.setdefault('ssl_version', ssl.PROTOCOL_TLSv1_2)


or something similar. Does a way to do this in JupyterHub exist?

Thorin Tabor
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160715/9814fe07/attachment.html>

From benjaminrk at gmail.com  Fri Jul 15 18:16:15 2016
From: benjaminrk at gmail.com (MinRK)
Date: Fri, 15 Jul 2016 17:16:15 -0500
Subject: [IPython-dev] JupyterHub & TLS 1.2
In-Reply-To: <a5e2ee8b-8b18-52a5-b53e-8250b6a3fe13@broadinstitute.org>
References: <a5e2ee8b-8b18-52a5-b53e-8250b6a3fe13@broadinstitute.org>
Message-ID: <CAHNn8BUGTPDPELAFzF_Ktdkzmm=VPPKX9ChbkdEc1ovMa9JayQ@mail.gmail.com>

With a default deployment, it's actually the configurable-http-proxy that's
out front, so Python SSL parameters don't help us. I don't think CHP
exposes that option yet, but we can add it easily enough.

-MinRK

On Fri, Jul 15, 2016 at 11:48 AM, Thorin Tabor <thorin at broadinstitute.org>
wrote:

> I'm running JupyterHub through HTTPS and need to configure it to only use
> TLS 1.2. Is there a reasonable to do that?
>
> I noticed that Jupyter has an ssl_options config setting that's passed to
> the underlying tornado server, but thus far I haven't seen an equivalent in
> JupyterHub. Ideally I'd like to just be able to run
>
> ssl_options.setdefault('ssl_version', ssl.PROTOCOL_TLSv1_2)
>
>
> or something similar. Does a way to do this in JupyterHub exist?
>
> Thorin Tabor
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160715/e622452f/attachment.html>

From klonuo at gmail.com  Sat Jul 16 01:14:01 2016
From: klonuo at gmail.com (klo uo)
Date: Sat, 16 Jul 2016 07:14:01 +0200
Subject: [IPython-dev] Where does IPython look for info when trying to
 connect to kernel
In-Reply-To: <CAOvn4qhU6t3iS_M4ao12gQPxxRe=__HmEbN2iv4meOaYyU71pw@mail.gmail.com>
References: <CAA-8Ld9Zwocu21H_U7TNNUPAq3OrZXDHjYHMKF1ABSw9_f_fEQ@mail.gmail.com>
 <CAOvn4qgOSkgsS5hvN3AErovuMiy-PWE5XO=Vb=4P6D0n16MgiQ@mail.gmail.com>
 <CAA-8Ld_Jc=dyM1YiMv9BMU1w5bAkUtuRGGhm92F2T0hC8yBpXg@mail.gmail.com>
 <CAOvn4qhU6t3iS_M4ao12gQPxxRe=__HmEbN2iv4meOaYyU71pw@mail.gmail.com>
Message-ID: <CAA-8Ld8eB_srFVBQXCj8O0TR9Pu3JpP93Xj99cL07Ca0K2pPNw@mail.gmail.com>

Nice :)

After setting IPYTHONDIR and JUPYTER_RUNTIME_DIR in .bashrc on Windows 10
WSL Bash shell (https://en.wikipedia.org/wiki/Windows_Subsystem_for_Linux)
to my system IPython/Jupyter, I can now share same settings for both and
easily share IPython sessions between the two.



On Fri, Jul 15, 2016 at 2:10 PM, Thomas Kluyver <takowl at gmail.com> wrote:

> On 15 July 2016 at 13:07, klo uo <klonuo at gmail.com> wrote:
>
>> Do you perhaps know if jupyter accepts custom default location, as it was
>> with IPYTHONDIR for ipython, or should I ask on jupyter list?
>
>
> Yes, there's a JUPYTER_RUNTIME_DIR environment variable. Docs here:
>
> http://jupyter.readthedocs.io/en/latest/projects/jupyter-directories.html#runtime-files
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160716/92b9a89f/attachment.html>

From cappy2112 at gmail.com  Sat Jul 16 15:40:05 2016
From: cappy2112 at gmail.com (Tony Cappellini)
Date: Sat, 16 Jul 2016 12:40:05 -0700
Subject: [IPython-dev] nbconvert not found
Message-ID: <CABRXM4kEC5jWKFm8ZbgcECZK7Tc5K2zmoPkKEt5bQtXgnNbp7w@mail.gmail.com>

OSX Mavericks, 10.9.5


I don't understand why condo shows nbconvert as being installed, yet
cannot be executed.

I've tried this in two virtual environments, both have the same problem.

nbconvert
-bash: *nbconvert: command not found*
[py27dev] tonys-mbp:~ tonycappellini$ conda list nbconvert
# packages in environment at /Users/tonycappellini/anaconda/envs/py27dev:
#
*nbconvert                 4.1.0                    py27_0*


Have any of you seen this issue before?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160716/bffc07f6/attachment.html>

From efiring at hawaii.edu  Sat Jul 16 15:41:59 2016
From: efiring at hawaii.edu (Eric Firing)
Date: Sat, 16 Jul 2016 09:41:59 -1000
Subject: [IPython-dev] nbconvert not found
In-Reply-To: <CABRXM4kEC5jWKFm8ZbgcECZK7Tc5K2zmoPkKEt5bQtXgnNbp7w@mail.gmail.com>
References: <CABRXM4kEC5jWKFm8ZbgcECZK7Tc5K2zmoPkKEt5bQtXgnNbp7w@mail.gmail.com>
Message-ID: <d3b5e28c-a042-f6d5-5a5b-f3bebc002e7e@hawaii.edu>

On 2016/07/16 9:40 AM, Tony Cappellini wrote:
>
> OSX Mavericks, 10.9.5
>
>
> I don't understand why condo shows nbconvert as being installed, yet
> cannot be executed.
>
> I've tried this in two virtual environments, both have the same problem.
>
> nbconvert

Try "jupyter nbconvert ...".

Eric


> -bash: *nbconvert: command not found*
> [py27dev] tonys-mbp:~ tonycappellini$ conda list nbconvert
> # packages in environment at /Users/tonycappellini/anaconda/envs/py27dev:
> #
> *nbconvert                 4.1.0                    py27_0*
> *
> *
>
> Have any of you seen this issue before?
>
>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>



From carl.input at gmail.com  Sun Jul 17 21:51:35 2016
From: carl.input at gmail.com (Carl Smith)
Date: Mon, 18 Jul 2016 02:51:35 +0100
Subject: [IPython-dev] Making the cursor wrap around on the ends of lines.
Message-ID: <CAP-uhDebw6SP9o9A8JkcRx=Tgrn276Xqd-XH61pP+hYBW7Vumg@mail.gmail.com>

While looking for more info on PT keybinding, I came across some xonsh code
which makes the cursor wrap around when you navigate off the start or end
of a line, like most GUI editors do. The original code is here:

http://xon.sh/_modules/xonsh/ptk/key_bindings.html

There's an IPython startup file (as a gist) here that does the same thing
for IPython 5:

https://gist.github.com/carlsmith/3cb2340bbfbdfcbdd579a948717af997

It seems like something that should just be enabled at all times, but maybe
someone else would prefer the current behaviour. Would anyone want this to
be configurable?

Cheers,

-- Carl Smith
carl.input at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160718/9bdf4f3d/attachment.html>

From cappy2112 at gmail.com  Sun Jul 17 23:57:11 2016
From: cappy2112 at gmail.com (Tony Cappellini)
Date: Sun, 17 Jul 2016 20:57:11 -0700
Subject: [IPython-dev] nbconvert not found
Message-ID: <CABRXM4ktdJhmB_8rE_w6gTGdvQaqBeD+QBr=U-cGC+i0dfqJ6w@mail.gmail.com>

Message: 2

> Date: Sat, 16 Jul 2016 09:41:59 -1000
> From: Eric Firing <efiring at hawaii.edu>
> To: ipython-dev at scipy.org
> Subject: Re: [IPython-dev] nbconvert not found
> Message-ID: <d3b5e28c-a042-f6d5-5a5b-f3bebc002e7e at hawaii.edu>
> Content-Type: text/plain; charset=windows-1252; format=flowed
>
>
> > nbconvert
>
> >>Try "jupyter nbconvert ...".
>
> >>Eric
>
> Uggh. Old habits die hard.

I'll make an alias so I don't forget again

Thanks Eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160717/6bdbbfb2/attachment.html>

From takowl at gmail.com  Mon Jul 18 06:01:31 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Mon, 18 Jul 2016 11:01:31 +0100
Subject: [IPython-dev] Making the cursor wrap around on the ends of
	lines.
In-Reply-To: <CAP-uhDebw6SP9o9A8JkcRx=Tgrn276Xqd-XH61pP+hYBW7Vumg@mail.gmail.com>
References: <CAP-uhDebw6SP9o9A8JkcRx=Tgrn276Xqd-XH61pP+hYBW7Vumg@mail.gmail.com>
Message-ID: <CAOvn4qi+GeWSDCGRD2ekGd6TYMWk9L5obKzSgB1tvkdZpWTnrg@mail.gmail.com>

Rather than duplicating this between xonsh and IPython, maybe we should try
to push it upstream to prompt_toolkit?

On 18 July 2016 at 02:51, Carl Smith <carl.input at gmail.com> wrote:

> While looking for more info on PT keybinding, I came across some xonsh
> code which makes the cursor wrap around when you navigate off the start or
> end of a line, like most GUI editors do. The original code is here:
>
> http://xon.sh/_modules/xonsh/ptk/key_bindings.html
>
> There's an IPython startup file (as a gist) here that does the same thing
> for IPython 5:
>
> https://gist.github.com/carlsmith/3cb2340bbfbdfcbdd579a948717af997
>
> It seems like something that should just be enabled at all times, but
> maybe someone else would prefer the current behaviour. Would anyone want
> this to be configurable?
>
> Cheers,
>
> -- Carl Smith
> carl.input at gmail.com
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160718/71e2f0cb/attachment.html>

From carl.input at gmail.com  Mon Jul 18 12:01:05 2016
From: carl.input at gmail.com (Carl Smith)
Date: Mon, 18 Jul 2016 17:01:05 +0100
Subject: [IPython-dev] Making the cursor wrap around on the ends of
	lines.
In-Reply-To: <CAOvn4qi+GeWSDCGRD2ekGd6TYMWk9L5obKzSgB1tvkdZpWTnrg@mail.gmail.com>
References: <CAP-uhDebw6SP9o9A8JkcRx=Tgrn276Xqd-XH61pP+hYBW7Vumg@mail.gmail.com>
 <CAOvn4qi+GeWSDCGRD2ekGd6TYMWk9L5obKzSgB1tvkdZpWTnrg@mail.gmail.com>
Message-ID: <CAP-uhDd=CxckEbPzGKpgsKoZEbE+KZvHP0jfDS9wPLLrpYjyGQ@mail.gmail.com>

On 18 July 2016 at 11:01, Thomas Kluyver <takowl at gmail.com> wrote:

> Rather than duplicating this between xonsh and IPython, maybe we should
> try to push it upstream to prompt_toolkit?
>

+1 Makes a lot of sense?.

-- Carl Smith
carl.input at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160718/18ed8e23/attachment.html>

From fperez.net at gmail.com  Mon Jul 18 14:03:48 2016
From: fperez.net at gmail.com (Fernando Perez)
Date: Mon, 18 Jul 2016 11:03:48 -0700
Subject: [IPython-dev] Making the cursor wrap around on the ends of
	lines.
In-Reply-To: <CAP-uhDd=CxckEbPzGKpgsKoZEbE+KZvHP0jfDS9wPLLrpYjyGQ@mail.gmail.com>
References: <CAP-uhDebw6SP9o9A8JkcRx=Tgrn276Xqd-XH61pP+hYBW7Vumg@mail.gmail.com>
 <CAOvn4qi+GeWSDCGRD2ekGd6TYMWk9L5obKzSgB1tvkdZpWTnrg@mail.gmail.com>
 <CAP-uhDd=CxckEbPzGKpgsKoZEbE+KZvHP0jfDS9wPLLrpYjyGQ@mail.gmail.com>
Message-ID: <CAHAreOrj_b_FhuiZXz8ccVN_H6i4M=+wiqzZ3L2maGjo=sz6GA@mail.gmail.com>

On Mon, Jul 18, 2016 at 9:01 AM, Carl Smith <carl.input at gmail.com> wrote:

> On 18 July 2016 at 11:01, Thomas Kluyver <takowl at gmail.com> wrote:
>
>> Rather than duplicating this between xonsh and IPython, maybe we should
>> try to push it upstream to prompt_toolkit?
>>
>
> +1 Makes a lot of sense?.
>

Agreed.

-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160718/23842586/attachment.html>

From carl.input at gmail.com  Mon Jul 18 17:15:21 2016
From: carl.input at gmail.com (Carl Smith)
Date: Mon, 18 Jul 2016 22:15:21 +0100
Subject: [IPython-dev] Using Prompt Toolkit to edit terminal inputs in a
	screen editor.
Message-ID: <CAP-uhDf8D0ZktJjqCS8foGCC04M4sU2rTtccONBYtHNyYMEk5Q@mail.gmail.com>

Prompt Toolkit allows you to open the current input in your favourite
editor, edit the code, and when you exit, you have the edited code in the
input buffer. This is different to %edit, and is really useful in practice.

If you chuck this code in a startup file, it will create a keybinding for
the feature. This code uses Ctrl-N (because ne is currently my favourite
tool for these kinds of edits), but you can easily change the keybinding.

    from prompt_toolkit.keys import Keys

    ip = get_ipython()

    def open_input_in_editor(event):

        event.cli.current_buffer.tempfile_suffix = ".py"
        event.cli.current_buffer.open_in_editor(event.cli)

    bind_key = ip.pt_cli.application.key_bindings_registry.add_binding
    bind_key(Keys.ControlN)(open_input_in_editor)

It'd be nice to have a better way of setting the tempfile suffix, so it
isn't redundantly reassigned every time you use the function, but doing it
this way is fine for now. Removing that causes the tempfile to have no
suffix, so you wouldn't get language specific features like syntax
highlighting.

Hope someone else finds this useful.

Best,
-- Carl Smith
carl.input at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160718/ac5653c2/attachment.html>

From takowl at gmail.com  Tue Jul 19 07:10:31 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Tue, 19 Jul 2016 12:10:31 +0100
Subject: [IPython-dev] Using Prompt Toolkit to edit terminal inputs in a
 screen editor.
In-Reply-To: <CAP-uhDf8D0ZktJjqCS8foGCC04M4sU2rTtccONBYtHNyYMEk5Q@mail.gmail.com>
References: <CAP-uhDf8D0ZktJjqCS8foGCC04M4sU2rTtccONBYtHNyYMEk5Q@mail.gmail.com>
Message-ID: <CAOvn4qinfdJUd_1kXDviP1RtXtD_Lz3ATQpnXCjQ4u_FXWR7zA@mail.gmail.com>

Ooh, nice find. If we can agree on a keyboard shortcut that people like for
this, I'd like to enable it by default in IPython.

On 18 July 2016 at 22:15, Carl Smith <carl.input at gmail.com> wrote:

> Prompt Toolkit allows you to open the current input in your favourite
> editor, edit the code, and when you exit, you have the edited code in the
> input buffer. This is different to %edit, and is really useful in practice.
>
> If you chuck this code in a startup file, it will create a keybinding for
> the feature. This code uses Ctrl-N (because ne is currently my favourite
> tool for these kinds of edits), but you can easily change the keybinding.
>
>     from prompt_toolkit.keys import Keys
>
>     ip = get_ipython()
>
>     def open_input_in_editor(event):
>
>         event.cli.current_buffer.tempfile_suffix = ".py"
>         event.cli.current_buffer.open_in_editor(event.cli)
>
>     bind_key = ip.pt_cli.application.key_bindings_registry.add_binding
>     bind_key(Keys.ControlN)(open_input_in_editor)
>
> It'd be nice to have a better way of setting the tempfile suffix, so it
> isn't redundantly reassigned every time you use the function, but doing it
> this way is fine for now. Removing that causes the tempfile to have no
> suffix, so you wouldn't get language specific features like syntax
> highlighting.
>
> Hope someone else finds this useful.
>
> Best,
> -- Carl Smith
> carl.input at gmail.com
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160719/60b97421/attachment.html>

From carl.input at gmail.com  Tue Jul 19 12:28:52 2016
From: carl.input at gmail.com (Carl Smith)
Date: Tue, 19 Jul 2016 17:28:52 +0100
Subject: [IPython-dev] Using Prompt Toolkit to edit terminal inputs in a
 screen editor.
In-Reply-To: <CAOvn4qinfdJUd_1kXDviP1RtXtD_Lz3ATQpnXCjQ4u_FXWR7zA@mail.gmail.com>
References: <CAP-uhDf8D0ZktJjqCS8foGCC04M4sU2rTtccONBYtHNyYMEk5Q@mail.gmail.com>
 <CAOvn4qinfdJUd_1kXDviP1RtXtD_Lz3ATQpnXCjQ4u_FXWR7zA@mail.gmail.com>
Message-ID: <CAP-uhDcO087Ff_jRSLeAchvUHTfwUwPr2sbYo0yh7tsaODBHnA@mail.gmail.com>

-- Carl Smith
carl.input at gmail.com

On 19 July 2016 at 12:10, Thomas Kluyver <takowl at gmail.com> wrote:

> Ooh, nice find. If we can agree on a keyboard shortcut that people like
> for this, I'd like to enable it by default in IPython.
>
> On 18 July 2016 at 22:15, Carl Smith <carl.input at gmail.com> wrote:
>
>> Prompt Toolkit allows you to open the current input in your favourite
>> editor, edit the code, and when you exit, you have the edited code in the
>> input buffer. This is different to %edit, and is really useful in practice.
>>
>> If you chuck this code in a startup file, it will create a keybinding for
>> the feature. This code uses Ctrl-N (because ne is currently my favourite
>> tool for these kinds of edits), but you can easily change the keybinding.
>>
>>     from prompt_toolkit.keys import Keys
>>
>>     ip = get_ipython()
>>
>>     def open_input_in_editor(event):
>>
>>         event.cli.current_buffer.tempfile_suffix = ".py"
>>         event.cli.current_buffer.open_in_editor(event.cli)
>>
>>     bind_key = ip.pt_cli.application.key_bindings_registry.add_binding
>>     bind_key(Keys.ControlN)(open_input_in_editor)
>>
>> It'd be nice to have a better way of setting the tempfile suffix, so it
>> isn't redundantly reassigned every time you use the function, but doing it
>> this way is fine for now. Removing that causes the tempfile to have no
>> suffix, so you wouldn't get language specific features like syntax
>> highlighting.
>>
>> Hope someone else finds this useful.
>>
>> Best,
>> -- Carl Smith
>> carl.input at gmail.com
>>
>> _______________________________________________
>> IPython-dev mailing list
>> IPython-dev at scipy.org
>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160719/48f46b61/attachment.html>

From carl.input at gmail.com  Tue Jul 19 12:58:54 2016
From: carl.input at gmail.com (Carl Smith)
Date: Tue, 19 Jul 2016 17:58:54 +0100
Subject: [IPython-dev] Using Prompt Toolkit to edit terminal inputs in a
 screen editor.
In-Reply-To: <CAP-uhDcO087Ff_jRSLeAchvUHTfwUwPr2sbYo0yh7tsaODBHnA@mail.gmail.com>
References: <CAP-uhDf8D0ZktJjqCS8foGCC04M4sU2rTtccONBYtHNyYMEk5Q@mail.gmail.com>
 <CAOvn4qinfdJUd_1kXDviP1RtXtD_Lz3ATQpnXCjQ4u_FXWR7zA@mail.gmail.com>
 <CAP-uhDcO087Ff_jRSLeAchvUHTfwUwPr2sbYo0yh7tsaODBHnA@mail.gmail.com>
Message-ID: <CAP-uhDc=w81c5rbeRcBgoQzfwRHJG-e-gC5B4Dx7Or3CJi2kGQ@mail.gmail.com>

?Sorry for sending a blank reply to the list earlier. GMail needs to move
[Send] to the right-hand side.

On 19 July 2016 at 12:10, Thomas Kluyver <takowl at gmail.com> wrote:

> Ooh, nice find. If we can agree on a keyboard shortcut that people like
>> for this, I'd like to enable it by default in IPython.
>>
>
?Sweet. That would cool. Cheers Thomas. I found it a couple of days ago,
and use it all the time. Prompt Toolkit is awesome.

Once you get a reference to their PT cli instance (as `ip.pt_cli`, or the
first arg to any prompt token method, or the `cli` attribute of any event)
you can access the input buffer, set up keybindings and any stuff like that
- basically, anywhere you're just playing with state and event handlers,
you're generally ok. But. There are still a lot of cool options that are in
the PT docs, that we can't access yet from IPython (as far as I tell).

?
The documented APIs for the inaccessible PT features involve passing stuff
to their `parse` method, using named args, but there's no obvious way to
attach the same stuff to a running instance. Any ideas would be
appreciated. As a concrete example, how would an IPython user add a bottom
toolbar:

http://python-prompt-toolkit.readthedocs.io/en/stable/pages/building_prompts.html#adding-a-bottom-toolbar

Thanks,
-- Carl Smith
carl.input at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160719/23f047e5/attachment.html>

From takowl at gmail.com  Tue Jul 19 13:01:17 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Tue, 19 Jul 2016 18:01:17 +0100
Subject: [IPython-dev] Using Prompt Toolkit to edit terminal inputs in a
 screen editor.
In-Reply-To: <CAP-uhDc=w81c5rbeRcBgoQzfwRHJG-e-gC5B4Dx7Or3CJi2kGQ@mail.gmail.com>
References: <CAP-uhDf8D0ZktJjqCS8foGCC04M4sU2rTtccONBYtHNyYMEk5Q@mail.gmail.com>
 <CAOvn4qinfdJUd_1kXDviP1RtXtD_Lz3ATQpnXCjQ4u_FXWR7zA@mail.gmail.com>
 <CAP-uhDcO087Ff_jRSLeAchvUHTfwUwPr2sbYo0yh7tsaODBHnA@mail.gmail.com>
 <CAP-uhDc=w81c5rbeRcBgoQzfwRHJG-e-gC5B4Dx7Or3CJi2kGQ@mail.gmail.com>
Message-ID: <CAOvn4qhrUVjMFpxQX9P_HzBKyBQ5HRzpDRHE4Pfdf=V0FOFZDw@mail.gmail.com>

On 19 July 2016 at 17:58, Carl Smith <carl.input at gmail.com> wrote:

> The documented APIs for the inaccessible PT features involve passing stuff
> to their `parse` method, using named args, but there's no obvious way to
> attach the same stuff to a running instance. Any ideas would be
> appreciated. As a concrete example, how would an IPython user add a bottom
> toolbar:
>

I think that's something we'd need to expose. I'm planning to investigate
adding a bottom toolbar for IPython 6.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160719/d49695dc/attachment.html>

From carl.input at gmail.com  Tue Jul 19 13:12:47 2016
From: carl.input at gmail.com (Carl Smith)
Date: Tue, 19 Jul 2016 18:12:47 +0100
Subject: [IPython-dev] Using Prompt Toolkit to edit terminal inputs in a
 screen editor.
In-Reply-To: <CAOvn4qhrUVjMFpxQX9P_HzBKyBQ5HRzpDRHE4Pfdf=V0FOFZDw@mail.gmail.com>
References: <CAP-uhDf8D0ZktJjqCS8foGCC04M4sU2rTtccONBYtHNyYMEk5Q@mail.gmail.com>
 <CAOvn4qinfdJUd_1kXDviP1RtXtD_Lz3ATQpnXCjQ4u_FXWR7zA@mail.gmail.com>
 <CAP-uhDcO087Ff_jRSLeAchvUHTfwUwPr2sbYo0yh7tsaODBHnA@mail.gmail.com>
 <CAP-uhDc=w81c5rbeRcBgoQzfwRHJG-e-gC5B4Dx7Or3CJi2kGQ@mail.gmail.com>
 <CAOvn4qhrUVjMFpxQX9P_HzBKyBQ5HRzpDRHE4Pfdf=V0FOFZDw@mail.gmail.com>
Message-ID: <CAP-uhDcL1mj3fYN7JmZR8u0HsA6nU7JBDK7V0j4t7V0G147gdQ@mail.gmail.com>

On 19 July 2016 at 18:01, Thomas Kluyver <takowl at gmail.com> wrote:

> On 19 July 2016 at 17:58, Carl Smith <carl.input at gmail.com> wrote:
>
>> The documented APIs for the inaccessible PT features involve passing
>> stuff to their `parse` method, using named args, but there's no obvious way
>> to attach the same stuff to a running instance. Any ideas would be
>> appreciated. As a concrete example, how would an IPython user add a bottom
>> toolbar:
>>
>
> I think that's something we'd need to expose. I'm planning to investigate
> adding a bottom toolbar for IPython 6.
>

?Cool. It'd be nice if there was a way to define some of this stuff on a
running instance, instead of you guys having to push each feature by hand,
but I'm just being impatient really. Each new feature will need properly
integrating into IPython anyway.

?On keys for the editor feature, users can do `from prompt_toolkit.keys
import Keys`?, then use stuff like `Keys.ControlV` easily. The PT API would
make it pretty simple to take a user's Key subclass and set up their
shortcut. I think only do it once per session though, like any event
handler.

?Best, and thanks again Thomas. You do an awesome job with the Python
community.?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160719/65d4ee30/attachment.html>

From carl.input at gmail.com  Tue Jul 19 13:29:14 2016
From: carl.input at gmail.com (Carl Smith)
Date: Tue, 19 Jul 2016 18:29:14 +0100
Subject: [IPython-dev] Using Prompt Toolkit to edit terminal inputs in a
 screen editor.
In-Reply-To: <CAP-uhDcL1mj3fYN7JmZR8u0HsA6nU7JBDK7V0j4t7V0G147gdQ@mail.gmail.com>
References: <CAP-uhDf8D0ZktJjqCS8foGCC04M4sU2rTtccONBYtHNyYMEk5Q@mail.gmail.com>
 <CAOvn4qinfdJUd_1kXDviP1RtXtD_Lz3ATQpnXCjQ4u_FXWR7zA@mail.gmail.com>
 <CAP-uhDcO087Ff_jRSLeAchvUHTfwUwPr2sbYo0yh7tsaODBHnA@mail.gmail.com>
 <CAP-uhDc=w81c5rbeRcBgoQzfwRHJG-e-gC5B4Dx7Or3CJi2kGQ@mail.gmail.com>
 <CAOvn4qhrUVjMFpxQX9P_HzBKyBQ5HRzpDRHE4Pfdf=V0FOFZDw@mail.gmail.com>
 <CAP-uhDcL1mj3fYN7JmZR8u0HsA6nU7JBDK7V0j4t7V0G147gdQ@mail.gmail.com>
Message-ID: <CAP-uhDdKA4MqB0CxbvW9pP8E=GTKzQYRQsWLdXLV5We2p2f_dg@mail.gmail.com>

On 19 July 2016 at 18:12, Carl Smith <carl.input at gmail.com> wrote:

> ?On keys for the editor feature, users can do `from prompt_toolkit.keys
> import Keys`?, then use stuff like `Keys.ControlV` easily. The PT API would
> make it pretty simple to take a user's Key subclass and set up their
> shortcut. I think only do it once per session though, like any event
> handler.
>

?This^ would go in the IPython config file.*?*

?When you're creating a fullscreen app with PT, do you still call `prompt`?
The point really: Do you call a method that accepts the same config args as
`prompt`? Could you add another option to the config file that requires a
dict, where the keys are `prompt` keyword args, and then just `**kargs` it
into the `prompt` call inside IPython?

You'd still maybe want IPython APIs for PT stuff people want to do more
often, but at least users would always have raw access the much more of the
library.

?Best,?
-- Carl Smith
carl.input at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160719/6de46f96/attachment.html>

From jgomezdans at gmail.com  Wed Jul 20 08:25:54 2016
From: jgomezdans at gmail.com (Jose Gomez-Dans)
Date: Wed, 20 Jul 2016 13:25:54 +0100
Subject: [IPython-dev] ipywidget GUI
Message-ID: <CAMWde5rMaJ3Zvmw17fMm=P7_3b_deg4RLNghkH7sVZYQqKCFcg@mail.gmail.com>

Hello,

I have a set of functions that I'd like to expose in a notebook as HTML
widgets, using ipywidgets (I think that's still the current name ;-D). In
the past, I have used interact to do this, but in this case, I'd very much
like to hide the pipework in a file, and maybe just have a simple function
call in the notebook (e.g. gui_expt1()) that sets up the GUI etc.

One option is to define e.g. a dictionary with the different GUI bits
(ranges for sliders and so on), and pass it to the interact call, but I was
wondering whether other approaches might be better.

Thanks!
Jose
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160720/a7678ca3/attachment.html>

From pmhobson at gmail.com  Wed Jul 20 10:01:54 2016
From: pmhobson at gmail.com (Paul Hobson)
Date: Wed, 20 Jul 2016 07:01:54 -0700
Subject: [IPython-dev] ipywidget GUI
In-Reply-To: <CAMWde5rMaJ3Zvmw17fMm=P7_3b_deg4RLNghkH7sVZYQqKCFcg@mail.gmail.com>
References: <CAMWde5rMaJ3Zvmw17fMm=P7_3b_deg4RLNghkH7sVZYQqKCFcg@mail.gmail.com>
Message-ID: <CADT3MECcM0CB=ozgTX1QPcDafaD=Y3+XRhU1STUqZjKH-_LkZQ@mail.gmail.com>

Michael Waskom's seaborn library does this in his widgets.py submodule.
Maybe you can take some inspiration from that:
https://github.com/mwaskom/seaborn/blob/master/seaborn/widgets.py



On Wed, Jul 20, 2016 at 5:25 AM, Jose Gomez-Dans <jgomezdans at gmail.com>
wrote:

> Hello,
>
> I have a set of functions that I'd like to expose in a notebook as HTML
> widgets, using ipywidgets (I think that's still the current name ;-D). In
> the past, I have used interact to do this, but in this case, I'd very much
> like to hide the pipework in a file, and maybe just have a simple function
> call in the notebook (e.g. gui_expt1()) that sets up the GUI etc.
>
> One option is to define e.g. a dictionary with the different GUI bits
> (ranges for sliders and so on), and pass it to the interact call, but I was
> wondering whether other approaches might be better.
>
> Thanks!
> Jose
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160720/c522df83/attachment.html>

From kikocorreoso at gmail.com  Fri Jul 22 06:01:59 2016
From: kikocorreoso at gmail.com (Kiko)
Date: Fri, 22 Jul 2016 12:01:59 +0200
Subject: [IPython-dev] [ANN] tutormagic v0.2.0
Message-ID: <CAB-sx631fCe9NzuyfFArhgNfa6KY+a=x4rtSAH0B4oF=dDV_1A@mail.gmail.com>

Hi all,

I released v 0.2.0 of tutormagic.

What is tutormagic
==============
It is a very simple and small package that allows you to embed
http://pythontutor.com within the notebook (or in a new tab if you prefer)
using a %%tutor cell magic.

The main idea is to be used as a learning/teaching tool.

Changelog
========
Version 0.2.0

   - Added new --tab option (thanks to Holger Karl (@hkarl
   <https://github.com/hkarl>)).
   - Added new --height option (thanks to Tom Simonart(@tomsimonart
   <https://github.com/tomsimonart>)).
   - Added new languages available on http://pythontutor.com (Typescript,
   Ruby, C and C++).

Version 0.1.0

   - Initial version

Installation
========

> pip install tutormagic

More info and docs
==============

https://github.com/kikocorreoso/tutormagic
Acknowledgment
=============Thanks to the contributors of tutormagic, Jupyter and
Pythontutor.

I hope it is useful for anyone here.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160722/01985cf3/attachment.html>

From takowl at gmail.com  Sat Jul 23 09:26:05 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Sat, 23 Jul 2016 14:26:05 +0100
Subject: [IPython-dev] [ANN] tutormagic v0.2.0
In-Reply-To: <CAB-sx631fCe9NzuyfFArhgNfa6KY+a=x4rtSAH0B4oF=dDV_1A@mail.gmail.com>
References: <CAB-sx631fCe9NzuyfFArhgNfa6KY+a=x4rtSAH0B4oF=dDV_1A@mail.gmail.com>
Message-ID: <CAOvn4qgJ=RB-rtwetxjph3d-MfYa9BBHiTnbvVJ6JXiB_urdiQ@mail.gmail.com>

Thanks Kiko! I've used tutormagic before, and I think it's a very useful
tool to teach people how Python variables and scopes work.

On 22 July 2016 at 11:01, Kiko <kikocorreoso at gmail.com> wrote:

> Hi all,
>
> I released v 0.2.0 of tutormagic.
>
> What is tutormagic
> ==============
> It is a very simple and small package that allows you to embed
> http://pythontutor.com within the notebook (or in a new tab if you
> prefer) using a %%tutor cell magic.
>
> The main idea is to be used as a learning/teaching tool.
>
> Changelog
> ========
> Version 0.2.0
>
>    - Added new --tab option (thanks to Holger Karl (@hkarl
>    <https://github.com/hkarl>)).
>    - Added new --height option (thanks to Tom Simonart(@tomsimonart
>    <https://github.com/tomsimonart>)).
>    - Added new languages available on http://pythontutor.com (Typescript,
>    Ruby, C and C++).
>
> Version 0.1.0
>
>    - Initial version
>
> Installation
> ========
>
> > pip install tutormagic
>
> More info and docs
> ==============
>
> https://github.com/kikocorreoso/tutormagic
> Acknowledgment
> =============Thanks to the contributors of tutormagic, Jupyter and
> Pythontutor.
>
> I hope it is useful for anyone here.
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160723/6536879f/attachment.html>

From kikocorreoso at gmail.com  Tue Jul 26 05:35:46 2016
From: kikocorreoso at gmail.com (Kiko)
Date: Tue, 26 Jul 2016 11:35:46 +0200
Subject: [IPython-dev] [ANN] tutormagic v0.2.0
In-Reply-To: <CAOvn4qgJ=RB-rtwetxjph3d-MfYa9BBHiTnbvVJ6JXiB_urdiQ@mail.gmail.com>
References: <CAB-sx631fCe9NzuyfFArhgNfa6KY+a=x4rtSAH0B4oF=dDV_1A@mail.gmail.com>
 <CAOvn4qgJ=RB-rtwetxjph3d-MfYa9BBHiTnbvVJ6JXiB_urdiQ@mail.gmail.com>
Message-ID: <CAB-sx60MX2aj+cGWZjGqs0EbyHWzE=oF64mUYqyRfhPMHV75rw@mail.gmail.com>

2016-07-23 15:26 GMT+02:00 Thomas Kluyver <takowl at gmail.com>:

> Thanks Kiko! I've used tutormagic before, and I think it's a very useful
> tool to teach people how Python variables and scopes work.
>

Great to know.

Thanks for the hard work to all the IPython/Jupyter team.



>
> On 22 July 2016 at 11:01, Kiko <kikocorreoso at gmail.com> wrote:
>
>> Hi all,
>>
>> I released v 0.2.0 of tutormagic.
>>
>> What is tutormagic
>> ==============
>> It is a very simple and small package that allows you to embed
>> http://pythontutor.com within the notebook (or in a new tab if you
>> prefer) using a %%tutor cell magic.
>>
>> The main idea is to be used as a learning/teaching tool.
>>
>> Changelog
>> ========
>> Version 0.2.0
>>
>>    - Added new --tab option (thanks to Holger Karl (@hkarl
>>    <https://github.com/hkarl>)).
>>    - Added new --height option (thanks to Tom Simonart(@tomsimonart
>>    <https://github.com/tomsimonart>)).
>>    - Added new languages available on http://pythontutor.com
>>    (Typescript, Ruby, C and C++).
>>
>> Version 0.1.0
>>
>>    - Initial version
>>
>> Installation
>> ========
>>
>> > pip install tutormagic
>>
>> More info and docs
>> ==============
>>
>> https://github.com/kikocorreoso/tutormagic
>> Acknowledgment
>> =============Thanks to the contributors of tutormagic, Jupyter and
>> Pythontutor.
>>
>> I hope it is useful for anyone here.
>>
>> _______________________________________________
>> IPython-dev mailing list
>> IPython-dev at scipy.org
>> https://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160726/e48ec403/attachment.html>

From ludwig.schwardt at gmail.com  Wed Jul 27 10:00:22 2016
From: ludwig.schwardt at gmail.com (Ludwig Schwardt)
Date: Wed, 27 Jul 2016 16:00:22 +0200
Subject: [IPython-dev] _ipython_key_completions_ has unexpected behaviour
Message-ID: <CAJ3RG11htDvrg9G-gBS-D6pcSG8d1YdNSEtovgz+fSGKwVj3CA@mail.gmail.com>

Hi,

I am very excited about the new custom dict key completer as it potentially
replaces many lines of brittle code in my libraries dating back to before
IPython 0.10.

My excitement was tempered when I used it. The following happens on the
latest master:

In [6]: class A(object):
   ...:     def _ipython_key_completions_(self):
   ...:         return ['x', 'y']
   ...:

In [7]:

In [7]: a = A()

In [8]: a['x
             x      %xmode
             %xdel  xrange


I expected the list of options to include only strings returned by
_ipython_key_completions_ but instead it gives the whole shebang of
filenames, Python keywords, magics, etc.

On inspection of the source it seems that all matchers are used unless a
custom completer is registered (which is my current setup). Alternatively,
the merge_completions=False config option will only return the results of
the first successful matcher but since dict_key_matches is the last matcher
this will also not help.

I would like dict_key_matches to be the only matcher if
_ipython_key_completions_ is defined, without resorting to config
overrides. Am I the only one? :-)

Thanks in advance,

Ludwig
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160727/3284d373/attachment.html>

From takowl at gmail.com  Wed Jul 27 16:44:06 2016
From: takowl at gmail.com (Thomas Kluyver)
Date: Wed, 27 Jul 2016 21:44:06 +0100
Subject: [IPython-dev] _ipython_key_completions_ has unexpected behaviour
In-Reply-To: <CAJ3RG11htDvrg9G-gBS-D6pcSG8d1YdNSEtovgz+fSGKwVj3CA@mail.gmail.com>
References: <CAJ3RG11htDvrg9G-gBS-D6pcSG8d1YdNSEtovgz+fSGKwVj3CA@mail.gmail.com>
Message-ID: <CAOvn4qgGk2pzGeT=XWa2YEasjYNO8GO5tV7u1URY0WYujtXPRQ@mail.gmail.com>

The whole completion system is in dire need of an overhaul to make it more
flexible. However, I don't think this is as problematic as it seems - tab
completion is only useful with names of more than a couple of characters,
and then the ambiguity will disppear rapidly.

On 27 July 2016 at 15:00, Ludwig Schwardt <ludwig.schwardt at gmail.com> wrote:

> Hi,
>
> I am very excited about the new custom dict key completer as it
> potentially replaces many lines of brittle code in my libraries dating back
> to before IPython 0.10.
>
> My excitement was tempered when I used it. The following happens on the
> latest master:
>
> In [6]: class A(object):
>    ...:     def _ipython_key_completions_(self):
>    ...:         return ['x', 'y']
>    ...:
>
> In [7]:
>
> In [7]: a = A()
>
> In [8]: a['x
>              x      %xmode
>              %xdel  xrange
>
>
> I expected the list of options to include only strings returned by
> _ipython_key_completions_ but instead it gives the whole shebang of
> filenames, Python keywords, magics, etc.
>
> On inspection of the source it seems that all matchers are used unless a
> custom completer is registered (which is my current setup). Alternatively,
> the merge_completions=False config option will only return the results of
> the first successful matcher but since dict_key_matches is the last matcher
> this will also not help.
>
> I would like dict_key_matches to be the only matcher if
> _ipython_key_completions_ is defined, without resorting to config
> overrides. Am I the only one? :-)
>
> Thanks in advance,
>
> Ludwig
>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> https://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160727/b75ad6f3/attachment.html>

From ludwig.schwardt at gmail.com  Thu Jul 28 05:22:03 2016
From: ludwig.schwardt at gmail.com (Ludwig Schwardt)
Date: Thu, 28 Jul 2016 11:22:03 +0200
Subject: [IPython-dev] _ipython_key_completions_ has unexpected behaviour
Message-ID: <CAJ3RG10wviWdh2NOLCMj6mHhUNY+zhBROgNFby-CRZiFAbMQMA@mail.gmail.com>

Hi,


> The whole completion system is in dire need of an overhaul to make it more
> flexible. However, I don't think this is as problematic as it seems - tab
> completion is only useful with names of more than a couple of characters,
> and then the ambiguity will disppear rapidly.


Thanks for clearing that up. I guess I'll stick with the custom completers
for now. You underestimate how lazy my typing has become with my finger on
the TAB buzzer :-)

Regards,

Ludwig
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20160728/fbf9f78e/attachment.html>