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
Start what's new for 1.0 #3704
Start what's new for 1.0 #3704
Conversation
with requests-cache
required for sphinx build to succeed
use authorized paged requests, etc.
Btw, just before taking my flight. I think that github support uploads Le samedi 20 juillet 2013, Min RK a écrit :
|
That's true, I will look at what's involved. |
|
||
Which is a *library* function for getting the current IPython instance, | ||
and will return ``None`` if no IPython instance is running. | ||
This is the official way to check whether your code is called from inside an IPython session. |
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.
I suspect that in many cases, people might not want to import IPython to test whether their code is running in an IPython session. Do we have a convenient and official way to do that?
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.
Well, the current de facto standard is
try:
ip = get_ipython()
except NameError:
ip = None
But this is only true for code called from within the builtins_trap, which we found can be not true in some cases, such as when loading extensions at startup, etc.
How else can we provide a function for checking IPython, other than a function imported from IPython or injected into builtins?
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.
Well, that raises a more complex issue of exactly what we mean by code 'running in IPython'. But if that's a common case, one obvious approach would be to set a builtin, or some other globally accessible variable, all the time that IPython is running.
Alternatively, we could provide a function to copy&paste that checks whether IPython is in sys.modules
, and only calls IPython.get_ipython()
if it is.
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.
I think that's appropriate. I guess the function would be:
def get_ipython():
import sys
if 'IPython' in sys.modules:
import IPython
return IPython.get_ipython()
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.
👍
@minrk Update Line 157:
Line 186:
Replace with:
|
Disagree, |
You are of course correct; my point is that how is somebody supposed to I guess alternatively we could just put a link to the config docs. On Mon, Aug 5, 2013 at 2:29 AM, Matthias Bussonnier <
Dr. David P. Sanders Profesor Titular "A" / Associate Professor dpsanders@gmail.com Cubículo / office: #414, 4o. piso del Depto. de Física Tel.: +52 55 5622 4965 |
There is always a delicate balance between saying too much and too little.Here we jus inform people with retina-display that they can enable it. They are probably a minority, and I don't think it is worth giving more info. If you give too much info or one-liner on how to do something then people don't learn. Using the word "set" implicitly state that you have to configure something, so you look for configuration. Once you know our configuration system then you know how to configure everything else. So it is small difficulty for the user, but he will gain a lot by surpassing it, it will also remove us the pain of describing on every configuration option in all the doc how to configure. As for Still it is true that the config docs might be a little too much for a new user and we should probably have a simple introduction doc just about config files and how to write them. |
Start what's new for 1.0
minor fixes along the way:
__import__
call will raise the ImportError if there should be one.