Opened 4 months ago

Closed 4 months ago

#28604 closed defect (duplicate)

nyx dies with python errors when sorting on the configuration page

Reported by: torix Owned by:
Priority: Medium Milestone:
Component: Applications Version: Tor: 0.3.3.9
Severity: Normal Keywords:
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

Created this by:
running nyx 2.04 by sudoing to root (only way that works for me)
2 right arrows to get to config page
S to sort, Enter,Enter, Enter (Name, Value, Value Type)


[[6~Traceback (most recent call last):

File "/usr/local/bin/nyx", line 14, in <module>

nyx.main()

File "/root/nyx/nyx/nyx/init.py", line 176, in main

nyx.starter.main()

File "/root/nyx/nyx/stem/util/conf.py", line 289, in wrapped

return func(*args, config = config, kwargs)

File "/root/nyx/nyx/nyx/starter.py", line 118, in main

nyx.curses.start(nyx.draw_loop, acs_support = config.get('acs_support', True), transparent_background = True, cursor = False)

File "/root/nyx/nyx/nyx/curses.py", line 217, in start

curses.wrapper(_wrapper)

File "/usr/lib/python2.7/curses/wrapper.py", line 43, in wrapper

return func(stdscr, *args, kwds)

File "/root/nyx/nyx/nyx/curses.py", line 215, in _wrapper

function()

File "/root/nyx/nyx/nyx/init.py", line 243, in draw_loop

keybinding.handle(key)

File "/root/nyx/nyx/nyx/panel/init.py", line 82, in handle

self._action(key)

File "/root/nyx/nyx/nyx/panel/config.py", line 232, in _scroll

self.redraw()

File "/root/nyx/nyx/nyx/panel/init.py", line 175, in redraw

self._last_draw_size = nyx.curses.draw(self._draw, top = self._top, height = self.get_height(), draw_if_resized = draw_dimension)

File "/root/nyx/nyx/nyx/curses.py", line 746, in draw

func(_Subwindow(subwindow_width, subwindow_height, curses_subwindow))

File "/root/nyx/nyx/nyx/panel/config.py", line 315, in _draw

_draw_line(subwindow, scroll_offset, DETAILS_HEIGHT + i, entry, entry == selected, value_width, description_width)

File "/root/nyx/nyx/nyx/panel/config.py", line 335, in _draw_line

attr = [CONFIGattr.config.category_color?.get(entry.category, WHITE)]

File "/root/nyx/nyx/nyx/panel/config.py", line 136, in category

return getattr(manual(self.name), 'category')

AttributeError: 'NoneType' object has no attribute 'category'
---

ANOTHER EXAMPLE:
a to get all configuration options shown
S to sort, Name, Summary, Description


Traceback (most recent call last):

File "/usr/local/bin/nyx", line 14, in <module>

nyx.main()

File "/root/nyx/nyx/nyx/init.py", line 176, in main

nyx.starter.main()

File "/root/nyx/nyx/stem/util/conf.py", line 289, in wrapped

return func(*args, config = config, kwargs)

File "/root/nyx/nyx/nyx/starter.py", line 118, in main

nyx.curses.start(nyx.draw_loop, acs_support = config.get('acs_support', True), transparent_background = True, cursor = False)

File "/root/nyx/nyx/nyx/curses.py", line 217, in start

curses.wrapper(_wrapper)

File "/usr/lib/python2.7/curses/wrapper.py", line 43, in wrapper

return func(stdscr, *args, kwds)

File "/root/nyx/nyx/nyx/curses.py", line 215, in _wrapper

function()

File "/root/nyx/nyx/nyx/init.py", line 243, in draw_loop

keybinding.handle(key)

File "/root/nyx/nyx/nyx/panel/init.py", line 84, in handle

self._action()

File "/root/nyx/nyx/nyx/panel/config.py", line 207, in _show_sort_dialog

self._sort_content()

File "/root/nyx/nyx/nyx/panel/config.py", line 325, in _sort_content

self._all_content = sorted(self._all_content, key = lambda entry: [entry.sort_value(field) for field in self._sort_order])

File "/root/nyx/nyx/nyx/panel/config.py", line 325, in <lambda>

self._all_content = sorted(self._all_content, key = lambda entry: [entry.sort_value(field) for field in self._sort_order])

File "/root/nyx/nyx/nyx/panel/config.py", line 126, in sort_value

return self.summary

File "/root/nyx/nyx/nyx/panel/config.py", line 144, in summary

return getattr(manual(self.name), 'summary')

AttributeError: 'NoneType' object has no attribute 'summary'

Child Tickets

Change History (1)

comment:1 Changed 4 months ago by atagar

Resolution: duplicate
Status: newclosed
Note: See TracTickets for help on using tickets.