[Ipython-tickets] [IPython] #180: magic_cd prints exception traceback for a non-existing directory
IPython
ipython-tickets@scipy....
Mon Aug 27 07:02:43 CDT 2007
#180: magic_cd prints exception traceback for a non-existing directory
---------------------+------------------------------------------------------
Reporter: khinsen | Owner: fperez
Type: defect | Status: new
Priority: normal | Milestone:
Component: ipython | Version:
Severity: normal | Keywords:
---------------------+------------------------------------------------------
In IPython 0.8.1, typing
cd x
produced the very reasonable error message
{{{
[Errno 2] No such file or directory: 'x'
/private/Network/Servers/verger.local/Volumes/User
data/ClusterUsers/hinsen/projects/crystal_fluctuations
}}}
In 0.8.2.svn.r2665, it prints a full traceback that is more irritating
than useful:
{{{
[Errno 2] No such file or directory: 'x'
---------------------------------------------------------------------------
IndexError Traceback (most recent call
last)
/Users/hinsen/projects/test/<ipython console> in <module>()
/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-
packages/IPython/iplib.py in ipmagic(self, arg_s)
936 else:
937 magic_args = self.var_expand(magic_args,1)
--> 938 return fn(magic_args)
939
940 def ipalias(self,arg_s):
/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-
packages/IPython/Magic.py in magic_cd(self, parameter_s)
2519 self.db['dhist'] = compress_dhist(dhist)[-100:]
2520 if not 'q' in opts:
-> 2521 print self.shell.user_ns['_dh'][-1]
2522
2523
IndexError: list index out of range
}}}
--
Ticket URL: <http://projects.scipy.org/ipython/ipython/ticket/180>
IPython <http://ipython.scipy.org>
The IPython interactive Python system
More information about the Ipython-tickets
mailing list