Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use IPython #400

Merged
merged 1 commit into from
Feb 16, 2021
Merged

Use IPython #400

merged 1 commit into from
Feb 16, 2021

Conversation

martinRenou
Copy link
Member

@martinRenou martinRenou commented Feb 1, 2021

Fix #62, fix #63, partially fix #224, fix #28, fix #359, fix #399, fix #402

@martinRenou
Copy link
Member Author

It could be interesting to benchmark the starting time with and without this change, see if loading IPython affects start time.

@martinRenou
Copy link
Member Author

This is just a simple test for now. Only code execution works with the display hook.

@martinRenou
Copy link
Member Author

This could allow getting rid of a lot of code in xeus-python: error traceback, inspection, completion, etc. It would also bring magics support for free, even though some work would still be required to support matplotlib.

@martinRenou
Copy link
Member Author

martinRenou commented Feb 4, 2021

What remains to have a mergeable PR:

  • Keep user_ns as a C++ interpreter attribute
  • Find a suitable approach for executing Python code without using shell.run_cell (for the debugger and xeus-robot) while getting back the traceback correctly formatted and updating the linecache. We can get rid of xtraceback.cpp if we find a proper solution with IPython.
  • Custom display hook. (Check that SlicerJupyter's display hook can still work with the new approach)
  • Hook clear_output

@martinRenou martinRenou force-pushed the use_ipython branch 13 times, most recently from 2411974 to 3848528 Compare February 5, 2021 17:23
@martinRenou martinRenou changed the title Draft: Use IPython Use IPython Feb 5, 2021
@martinRenou martinRenou force-pushed the use_ipython branch 7 times, most recently from 4003dea to b7e7c98 Compare February 15, 2021 14:25
@martinRenou martinRenou force-pushed the use_ipython branch 17 times, most recently from 29b91de to a43a7f0 Compare February 16, 2021 10:48
@martinRenou martinRenou marked this pull request as ready for review February 16, 2021 10:53
@JohanMabille JohanMabille merged commit e994eeb into jupyter-xeus:master Feb 16, 2021
@martinRenou martinRenou deleted the use_ipython branch February 16, 2021 11:18
@agoose77
Copy link
Contributor

Wow, this is a really big step for usability. Awesome work!

@jtpio
Copy link
Member

jtpio commented Feb 17, 2021

Epic!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants