EmilyDirsh / hotwire-shell

Automatically exported from code.google.com/p/hotwire-shell
Other
0 stars 0 forks source link

exceptions thrown sometimes crash system #146

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Running on Windows (SVN head on Python 2.4) produces a traceback. Entering
commands causes a Python segfault, with no further traceback - but the
following may be useful:

Traceback (most recent call last):
  File "C:\compile\hotwire\hotwire_ui\renderers\unicode.py", line 185, in
__on_e
vent_after
    linkvalue(bufslice)
  File "C:\compile\hotwire\hotwire_ui\renderers\help.py", line 41, in
handle_ins
pector
    inspect = InspectWindow(o, parent=locate_current_window(self.get_widget()))
  File "C:\compile\hotwire\hotwire_ui\oinspect.py", line 225, in __init__
    self.__set_object(obj)
  File "C:\compile\hotwire\hotwire_ui\oinspect.py", line 249, in __set_object
    self.__set_members()
  File "C:\compile\hotwire\hotwire_ui\oinspect.py", line 254, in __set_members
    for name,member in sorted(inspect.getmembers(self.__obj), lambda a,b:
locale
.strcoll(a[0],b[0])):
  File "c:\Python24\lib\inspect.py", line 171, in getmembers
    value = getattr(object, key)
  File "C:\compile\hotwire\hotwire\builtin.py", line 61, in <lambda>
    outputs = property(lambda self: self._outputs)
AttributeError: 'FSearchBuiltin' object has no attribute '_outputs'

Original issue reported on code.google.com by fuzzyman on 8 Feb 2008 at 1:52

GoogleCodeExporter commented 9 years ago
I've seen this before.  I think it's not actually Windows specific, but a crash 
that
sometimes occurs when any exception is thrown.  My guess is it has something to 
do
with GTK+ not correctly handling them.

As for the attribute error - one second...

Original comment by cgwalt...@gmail.com on 8 Feb 2008 at 2:08

GoogleCodeExporter commented 9 years ago
This should fix the attribute error:

Committed r1006
    M   hotwire/builtin.py
r1006 = ad1b9c22039a893017b7e6d6900ef87db3a9e9c5 (git-svn)

Original comment by cgwalt...@gmail.com on 8 Feb 2008 at 2:08

GoogleCodeExporter commented 9 years ago
Still getting a segfault. No traceback this time (other than GTK warnings 
because a
theme isn't available).

I did find that when I did 'locals()' in the Python shell I get a caught 
exception
"AttributeError: 'module' object has no attribute 'or_test'".

My homedrive is on a network drive 'H:/' which also seems to confuse Hotwire - 
it
says "Caught hotwire.sysdep.fs.FileStatError: [Errno 2] No such file or 
directory:
u'H:/-'".

No idea if these caught exceptions are related to the segfault though.

Original comment by fuzzyman on 8 Feb 2008 at 4:21

GoogleCodeExporter commented 9 years ago
Just updated.

Type:

  cd c:/
  ls - l

Dies with following traceback:

17:37:49 [3980] hotwire.Completion ERROR failed to get completions
Traceback (most recent call last):
  File "C:\compile\hotwire\hotwire\completion.py", line 211, in __do_async_compl
ete
    result = self.__get_completions(completer, text, cwd)
  File "C:\compile\hotwire\hotwire\completion.py", line 205, in __get_completion
s
    return CompletionResults(list(completer.completions(text, cwd)))
  File "C:\compile\hotwire\hotwire\builtins\cd.py", line 36, in completions
    for completion in super(CdCompleter, self).completions(text, cwd, **kwargs):

  File "C:\compile\hotwire\hotwire\completion.py", line 101, in completions
    yield _mkfile_completion(text, fpath)
  File "C:\compile\hotwire\hotwire\completion.py", line 80, in _mkfile_completio
n
    fobj = fileobj or fs.get_file_sync(fpath)
  File "C:\compile\hotwire\hotwire\sysdep\fs.py", line 67, in get_file_sync
    f.get_stat_sync()
  File "C:\compile\hotwire\hotwire\sysdep\fs.py", line 287, in get_stat_sync
    self._do_get_hidden()
  File "C:\compile\hotwire\hotwire\sysdep\fs_impl\fs_win32.py", line 85, in _do_
get_hidden
    self._hidden = win32api.GetFileAttributes(self.path) & win32con.FILE_ATTRIBU
TE_HIDDEN
error: (32, 'GetFileAttributes', 'The process cannot access the file because it
is being used by another process.')

Original comment by fuzzyman on 8 Feb 2008 at 5:43

GoogleCodeExporter commented 9 years ago
That looks like issue 131, which has apparently reappeared?

I'll reopen it.

Original comment by cgwalt...@gmail.com on 8 Feb 2008 at 6:29