[IPython-dev] Open-file dialog in the notebook for data files

Adam Hughes hughesadam87 at gmail.com
Wed Dec 17 14:53:39 EST 2014


Would you be able to just use an IPython widget to get the file name?

On Wed, Dec 17, 2014 at 2:37 PM, Antonino Ingargiola <tritemio at gmail.com>
wrote:
>
> Dear ipython developers,
>
> I occasionally have the need to get a data file name via a GUI dialog when
> using the notebook.
>
> Opening a QT dialog from the notebook involves initializing the QT gui. At
> the same time I always use inline plots so I also need to enable the inline
> plot backed. This can be done with
>
>     %gui qt
>     %matplotlib inline
>
> These commands work when executed manually on different cells.
> However, the previous commands will freeze the ipython notebook if they
> are in the same cell or if executing the notebook with Run-All (open issue
> #5798 <https://github.com/ipython/ipython/issues/5798>). The problem is
> multi-platform and occurs both with PySide and PyQT.
>
> Is there any workaround for this? It really bothers me to lose the ability
> to Run-All when I enable the QT gui.
>
> Alternatively would be possible to use a javascript dialog to select a
> file on the filesystem? If yes an example would be nice.
>
> PS: I'm using ipython 2.x
>
> Thanks,
> Antonio
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20141217/e76099e8/attachment.html>


More information about the IPython-dev mailing list