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
#3005 - Removed 'ipython -pylab' references #3007
Conversation
Congratulations on your first contribution to a "large, serious project" 😄 - this looks good to me. @jenshnielsen & @NelleV - care to comment? |
To my understanding ipython --pylab isn't deprecated for python 2.0. The ipython notebook --pylab is deprecated. @Carreau, can you confirm ? |
Yes indeed, but pylab is so much used that we might never totally drop support for it. We recommend not to use On 3.0, The internal reason is that starting wit 3.0 the notebook server will be able to start kernels in many languages (python, julia, R...) and passing the You can see Fernando's thinking on this matter which is to use explicit import. From a teaching perspective, it is true that |
So this confirms that the option is only deprecated for the ipython notebook. We don't mention the notebook in the matplotlib documentation, thus we are not affected by this deprecation. |
@@ -1,3 +1,11 @@ | |||
2014-04-23 Updated references to "ipython -pylab" | |||
As of ipython 3.0, pylab mode can no longer be invoked at shell |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment should be fixed. The pylab mode can still be invoked in the shell, but isn't the preferred way to do this. Also, I'd remove the mention of the notebook in this section, as we never refer to the notebook in the matplotlib documentation, and there are already to much confusion between the console and the notebook.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apologies, the console/notebook distinction for this deprecation confused
me as well. Since the docs don't mention the notebook at all, I think it
would be best to close this pull request and discard the changes.
On Thu, Apr 24, 2014 at 8:02 AM, Varoquaux notifications@github.com wrote:
In CHANGELOG:
@@ -1,3 +1,11 @@
+2014-04-23 Updated references to "ipython -pylab"
As of ipython 3.0, pylab mode can no longer be invoked at shell
This comment should be fixed. The pylab mode can still be invoked in the
shell, but isn't the preferred way to do this. Also, I'd remove the mention
of the notebook in this section, as we never refer to the notebook in the
matplotlib documentation, and there are already to much confusion between
the console and the notebook.—
Reply to this email directly or view it on GitHubhttps://github.com//pull/3007/files#r11945383
.
I disagree. The ipython devs are discouraging the use of --pylab, even if they are but deprecating it ask we should not be encouraging its use. I am also of the view that we should also look in to getting rid of pylab (but that is another discussion). |
👍 with @tacaswell. |
I Agree with @tacaswell since %pylab and %matplotlib magics works in all IPython instances (QT, terminal and notebook) while the --pylab flag doesn't work in the notebook the best way to make it non confusing for the end user is to not mention the flag but only the %magic. I also agree with @pelson that matplotlib should not recommend the use of %matplotlib magic and explicit imports over %pylab. |
I use the --pylab ipython option daily (in contrast, I've opened a notebook once in three years) for my research, and I find it extremely useful for interactive purposes. I think it would be a great loss if the concept of pylab completely disappeared (and there is no mention of such idea). I think the problem of this option with the notebook is that notebooks are meant to be reran (in contrast with an interactive session). Thus, people ended up with notebooks with code that didn't run if you didn't launch the ipython notebook with the correct option (which doesn't happen in the case of a normal ipython session: if you didn't import matplotlib in your script, the script failed consistently whether or not you launched ipython with --pylab). I'm for the change of this PR, but I do think that it should not be mentionned that the --pylab option is deprecated, as this is not the case, and we shouldn't mention the notebook here. You can replace this part with the fact that %pylab is now the preferred way to open a pylab ipython environment. |
The main problem with pylab apart from the reproducibility are weird issues where scripts don't work because the buildin python functions are overwritten (i.e.pythons sum is replace with numpy's sum function) This has resulted in more than one IPython bug report along the line of "this works in regular python but fails in IPython" Agreed that there is no need to mention the notebook in the changelog and instead mention that %pylab magic is preferred. |
Alright, I've updated the changelog to simply state that the %pylab magic is preferred, and removed one reference to the notebook. The documentation now only gives examples using the %pylab magic, and does not mention the notebook (except for one reference in the "what's new in 1.3.1 section") or the "--pylab" flag. |
@NelleV Are you happy with this version of the text? 👍 from me to merge. |
#3005 - Removed 'ipython -pylab' references
This is a documentation fix for #3005. As referenced in the changelog, "ipython --pylab" is deprecated as of ipython v2.0, and will be removed completely in v3.0. The preferred method to enter the pylab environment is to call "%pylab" from the ipython shell directly.