You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found that %reset -f command not working. I see in docs and in namespace.py file instruction how to use reset command and expected result, its looks like:
In [9]: %reset -f
In [1]:
So I expect that after %reset -f command, number in [9] must be reset and will be [1].
In my case its looks like:
In [35]: %reset -f
In [36]:
So, this number is not reset after magic command. Arguments like --aggressive and -s is not help.
Also in docs I found that must be created new session:
By default (without this option), we do a ‘hard’ reset, giving you a new session and removing all references to objects from the current session.
But I go through the code and found that by default we send new_session = False:
I'm not sure what's the context of the b24bd65 change. In any case, I think that given the docstring and the fact that, intuitively, a reset should get the console back to its initial state, I can safely mark this as a bug.
Currently new_session=True would also have a small quirk, where it resets to [2] instead of [1]. Something to look into if we ever get the True back. In Jupyter Notebook, the cell with %reset gets [1], which leads me to believe that simply, the new session starts before the counter is incremented, and the magic should prevent that somehow.
I found that
%reset -f
command not working. I see in docs and in namespace.py file instruction how to use reset command and expected result, its looks like:So I expect that after
%reset -f
command, number in [9] must be reset and will be [1].In my case its looks like:
So, this number is not reset after magic command. Arguments like
--aggressive
and-s
is not help.Also in docs I found that must be created new session:
But I go through the code and found that by default we send
new_session = False
:ipython/IPython/core/magics/namespace.py
Lines 554 to 559 in 770024a
How can I restart session, reset
[n]
value or fully clear caches/modules without restart main application?The text was updated successfully, but these errors were encountered: