[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [nyx/master] Stacktrace when referring to data_directory()



commit 542bf2f91562167a4eed79271bed0d1d4bbf40e1
Author: Damian Johnson <atagar@xxxxxxxxxxxxxx>
Date:   Sat Aug 26 16:06:39 2017 -0700

    Stacktrace when referring to data_directory()
    
    Huh. Kinda unsure how this didn't come up earlier. Initializing the config
    panel is failing with...
    
      Traceback (most recent call last):
        File "/home/ubuntu/nyx/run_nyx", line 14, in <module>
          nyx.main()
        File "/home/ubuntu/nyx/nyx/__init__.py", line 105, in main
          nyx.starter.main()
        File "/home/ubuntu/nyx/stem/util/conf.py", line 289, in wrapped
          return func(*args, config = config, **kwargs)
        File "/home/ubuntu/nyx/nyx/starter.py", line 104, in main
          nyx.curses.start(nyx.draw_loop, acs_support = config.get('acs_support', True), transparent_background = True, cursor = False)
        File "/home/ubuntu/nyx/nyx/curses.py", line 216, in start
          curses.wrapper(_wrapper)
        File "/usr/lib/python2.7/curses/wrapper.py", line 43, in wrapper
          return func(stdscr, *args, **kwds)
        File "/home/ubuntu/nyx/nyx/curses.py", line 214, in _wrapper
          function()
        File "/home/ubuntu/nyx/nyx/__init__.py", line 123, in draw_loop
          interface = nyx_interface()
        File "/home/ubuntu/nyx/nyx/__init__.py", line 176, in nyx_interface
          Interface()  # constructor sets NYX_INTERFACE
        File "/home/ubuntu/nyx/nyx/__init__.py", line 345, in __init__
          self._page_panels.append([nyx.panel.config.ConfigPanel()])
        File "/home/ubuntu/nyx/nyx/panel/config.py", line 133, in __init__
          cached_manual_path = data_directory('manual')
        File "/home/ubuntu/nyx/stem/util/conf.py", line 289, in wrapped
          return func(*args, config = config, **kwargs)
      TypeError: data_directory() got multiple values for keyword argument 'config'
---
 nyx/__init__.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/nyx/__init__.py b/nyx/__init__.py
index 5cd0898..3cf3c85 100644
--- a/nyx/__init__.py
+++ b/nyx/__init__.py
@@ -232,7 +232,7 @@ def init_controller(*args, **kwargs):
 
 
 @uses_settings
-def data_directory(config, filename):
+def data_directory(filename, config):
   path = config.get('data_directory', '~/.nyx')
 
   if path == 'disabled':



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits