[IPython-dev] How to identify the execution_reply message

Andrea Zonca zonca at sdsc.edu
Thu Feb 27 19:25:14 EST 2014


hi,
I am trying to develop a py.test plugin to execute notebook cells as
unit tests [1].

I send a cell content via `execute` to the kernel, and instead of
getting back a single message,
I get several, so I resorted to just loop through all of them and get
the last, and it works:
https://github.com/zonca/pytest-ipynb/blob/master/conftest.py#L96

Now, what is the correct way of identifying what is the reply to the
last command
executed?

Thanks,
Andrea

[1] example test notebook
http://nbviewer.ipython.org/github/zonca/pytest-ipynb/blob/master/test_series_plots.ipynb



More information about the IPython-dev mailing list