Trac issueshttps://gitlab.torproject.org/legacy/trac/-/issues2019-01-10T08:07:58Zhttps://gitlab.torproject.org/legacy/trac/-/issues/28296Nyx shows wrong IP address for ControlPort connection2019-01-10T08:07:58ZTracNyx shows wrong IP address for ControlPort connectionNyx (2.0.4 installed using `python3-pip`) connects to Tor's `ControlPort` through `127.0.0.1:9051`, but in the window with circuit and other connections it shows
`127.0.0.1:PORT (??) --> REAL_IP_ADDRESS:9051 nyx (XXX) + 1.8m (CON...Nyx (2.0.4 installed using `python3-pip`) connects to Tor's `ControlPort` through `127.0.0.1:9051`, but in the window with circuit and other connections it shows
`127.0.0.1:PORT (??) --> REAL_IP_ADDRESS:9051 nyx (XXX) + 1.8m (CONTROL)`
where `REAL_IP_ADDRESS` is a real source IP for outgoing Tor packets to Internet. In this setup Tor is not listening at `REAL_IP_ADDRESS:9051`, i.e. `nyx`'s information is confusing. Instead of real IP `127.0.0.1` must be written:
`127.0.0.1:PORT (??) --> 127.0.0.1:9051 nyx (XXX) + 1.8m (CONTROL)`
**Trac**:
**Username**: wagonDamian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/28295Non-interactive way to supply ControlPort password for nyx and tor-prompt is ...2019-01-06T05:43:05ZTracNon-interactive way to supply ControlPort password for nyx and tor-prompt is neededWhen Tor's `ControlPort` requires password authentication, `nyx` and `tor-prompt` ask it interactively. However, it must be also a way to specify the password in a command line or in config file. Earlier it was possible with `arm`'s opti...When Tor's `ControlPort` requires password authentication, `nyx` and `tor-prompt` ask it interactively. However, it must be also a way to specify the password in a command line or in config file. Earlier it was possible with `arm`'s option `startup.controlPassword`, which no longer works with `nyx`.
**Trac**:
**Username**: wagonDamian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/28294Nyx crashes at graph resizing2018-11-05T17:10:28ZTracNyx crashes at graph resizingNyx (2.0.4 installed using `python3-pip`) has reproducible crash if the following is done:
1. Press `g` for graph resizing.
2. Press `down arrow` many times until `Events` sub-window will be completely hidden.
3. Nyx crashes with the fo...Nyx (2.0.4 installed using `python3-pip`) has reproducible crash if the following is done:
1. Press `g` for graph resizing.
2. Press `down arrow` many times until `Events` sub-window will be completely hidden.
3. Nyx crashes with the following log:
```
Traceback (most recent call last):
File "/usr/local/bin/nyx", line 9, in <module>
load_entry_point('nyx==2.0.4', 'console_scripts', 'nyx')()
File "/usr/local/lib/python3.4/dist-packages/nyx/__init__.py", line 176, in main
nyx.starter.main()
File "/usr/local/lib/python3.4/dist-packages/stem/util/conf.py", line 289, in wrapped
return func(*args, config = config, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/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 "/usr/local/lib/python3.4/dist-packages/nyx/curses.py", line 217, in start
curses.wrapper(_wrapper)
File "/usr/lib/python3.4/curses/__init__.py", line 94, in wrapper
return func(stdscr, *args, **kwds)
File "/usr/local/lib/python3.4/dist-packages/nyx/curses.py", line 215, in _wrapper
function()
File "/usr/local/lib/python3.4/dist-packages/nyx/__init__.py", line 243, in draw_loop
keybinding.handle(key)
File "/usr/local/lib/python3.4/dist-packages/nyx/panel/__init__.py", line 84, in handle
self._action()
File "/usr/local/lib/python3.4/dist-packages/nyx/panel/graph.py", line 504, in _resize_graph
nyx_interface().redraw()
File "/usr/local/lib/python3.4/dist-packages/nyx/__init__.py", line 716, in redraw
panel.redraw(force = force, top = occupied)
File "/usr/local/lib/python3.4/dist-packages/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 "/usr/local/lib/python3.4/dist-packages/nyx/curses.py", line 740, in draw
curses_subwindow = CURSES_SCREEN.subwin(subwindow_height, subwindow_width, top, left)
_curses.error: curses function returned NULL
```
**Trac**:
**Username**: wagonDamian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/28153Nyx memory leaks2019-01-04T22:40:03ZTracNyx memory leaksI had this problem twice. If `nyx` is running more than 1-2 days, it starts to consume more resources (I think, it is RAM). Finally, system becomes very slow and unresponsive until `nyx` (2.0.4 installed using `python3-pip`) is killed by...I had this problem twice. If `nyx` is running more than 1-2 days, it starts to consume more resources (I think, it is RAM). Finally, system becomes very slow and unresponsive until `nyx` (2.0.4 installed using `python3-pip`) is killed by system OOM-killer. This is what I see in `/var/log/messages` after that:
```
Purging GPU memory, 0 bytes freed, XXXXXXX bytes still pinned.
nyx invoked oom-killer: gfp_mask=0x201da, order=0, oom_score_adj=0
nyx cpuset=/ mems_allowed=0
CPU: 0 PID: XXXXX Comm: nyx Not tainted 3.16.0-7-amd64 #1 Debian [redacted]
Hardware name: [redacted]
0000000000000000 ffffffff81534df4 00000000000201da 0000000000000000
ffffffff81533956 0000000000000000 ffff880099938000 ffffffffa054d5ab
ffff880099950000 01ffffff8115e3d3 ffff880028f59550 ffffffff81730612
Call Trace:
[<ffffffff81534df4>] ? dump_stack+0x5d/0x78
[<ffffffff81533956>] ? dump_header+0x95/0x1fd
[<ffffffffa054d5ab>] ? i915_gem_shrinker_oom+0x15b/0x1c0 [i915]
[<ffffffff8114c20d>] ? oom_kill_process+0x21d/0x370
[<ffffffff8114bdad>] ? find_lock_task_mm+0x3d/0xa0
[<ffffffff8114c9ce>] ? out_of_memory+0x4be/0x4f0
[<ffffffff81153386>] ? __alloc_pages_nodemask+0xca6/0xcf0
[<ffffffff81193bd6>] ? alloc_pages_current+0xa6/0x160
[<ffffffff8114ae9c>] ? filemap_fault+0x1bc/0x440
[<ffffffff81172430>] ? __do_fault+0x40/0xc0
[<ffffffff811769eb>] ? handle_mm_fault+0xf2b/0x15b0
[<ffffffff8105b6cb>] ? __do_page_fault+0x1ab/0x470
[<ffffffff810dd5c3>] ? SyS_futex+0x73/0x170
[<ffffffff8153d058>] ? page_fault+0x28/0x30
```
Tor is configured as client only. It is neither a relay nor an onion service.
**Trac**:
**Username**: wagonDamian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/28078nyx hangs (sometimes) when tor process vanishes2018-12-29T20:14:28Ztraumschulenyx hangs (sometimes) when tor process vanishesFor the second time nyx became irresponsive after TB has been restarted (via update or after a crash).
What happened:
The process `/usr/bin/python3 /usr/bin/nyx -i 127.0.0.1:9151` is connected to TB's tor instance. Some days ago TB upgr...For the second time nyx became irresponsive after TB has been restarted (via update or after a crash).
What happened:
The process `/usr/bin/python3 /usr/bin/nyx -i 127.0.0.1:9151` is connected to TB's tor instance. Some days ago TB upgraded itself and restarted. (Probably) since then nyx is no longer responding. Attaching to it reveals python hangs at PyThread_acquire_lock_timed.
> # strace -p 27404
> strace: Process 27404 attached
> futex(0x9343b40, FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME, 1, NULL, 0xffffffff
I tried to attach to the process with [pdb-clone](https://bitbucket.org/xdegaye/pdb-clone/wiki/RemoteDebugging.md) after installing python-dbg:
```
# pdb-attach -p 27404
Starting gdb 8.1
+++ -interpreter-exec console "where"
+++ -gdb-exit
~"\n"
^done
(gdb)
~"#0 0xb7f1cd09 in __kernel_vsyscall ()\n"
~"#1 0xb7ed12d6 in futex_abstimed_wait_cancelable (private=0, abstime=0x0, expected=1, futex_word=0x9343b40) at ../sysdeps/unix/sysv/linux/futex-internal.h:205\n"
~"#2 do_futex_wait (sem=sem@entry=0x9343b40, abstime=0x0) at sem_waitcommon.c:115\n"
~"#3 0xb7ed13d7 in __new_sem_wait_slow (sem=0x9343b40, abstime=0x0) at sem_waitcommon.c:282\n"
~"#4 0x081e98cc in PyThread_acquire_lock_timed ()\n"
~"#5 0x0821a63d in ?? ()\n"
~"#6 0x081ab38b in _PyCFunction_FastCallDict ()\n"
~"#7 0x081dc4ed in PyObject_CallFunctionObjArgs ()\n"
~"#8 0x08152cf2 in _PyEval_EvalFrameDefault ()\n"
~"#9 0x0814f4c2 in ?? ()\n"
~"#10 0x081500a0 in ?? ()\n"
~"#11 0x0815186b in _PyEval_EvalFrameDefault ()\n"
~"#12 0x0814d785 in ?? ()\n"
~"#13 0x081ca5be in ?? ()\n"
~"#14 0x081e1054 in PyObject_Call ()\n"
~"#15 0x08152c05 in _PyEval_EvalFrameDefault ()\n"
~"#16 0x0814df2d in ?? ()\n"
~"#17 0x0814f76f in ?? ()\n"
~"#18 0x081500a0 in ?? ()\n"
~"#19 0x0815186b in _PyEval_EvalFrameDefault ()\n"
~"#20 0x0814f4c2 in ?? ()\n"
~"#21 0x081500a0 in ?? ()\n"
~"#22 0x0815186b in _PyEval_EvalFrameDefault ()\n"
~"#23 0x0814f4c2 in ?? ()\n"
~"#24 0x081500a0 in ?? ()\n"
~"#25 0x0815186b in _PyEval_EvalFrameDefault ()\n"
~"#26 0x0814f4c2 in ?? ()\n"
~"#27 0x081500a0 in ?? ()\n"
~"#28 0x0815186b in _PyEval_EvalFrameDefault ()\n"
~"#29 0x0814d785 in ?? ()\n"
~"#30 0x0814f76f in ?? ()\n"
~"#31 0x081500a0 in ?? ()\n"
~"#32 0x08152419 in _PyEval_EvalFrameDefault ()\n"
~"#33 0x0814d785 in ?? ()\n"
~"#34 0x0814f76f in ?? ()\n"
~"#35 0x081500a0 in ?? ()\n"
~"#36 0x08152419 in _PyEval_EvalFrameDefault ()\n"
~"#37 0x0814d785 in ?? ()\n"
~"#38 0x0814f76f in ?? ()\n"
~"#39 0x081500a0 in ?? ()\n"
~"#40 0x08152419 in _PyEval_EvalFrameDefault ()\n"
~"#41 0x0814f4c2 in ?? ()\n"
~"#42 0x081500a0 in ?? ()\n"
~"#43 0x0815186b in _PyEval_EvalFrameDefault ()\n"
~"#44 0x0814df2d in ?? ()\n"
~"#45 0x081ca5be in ?? ()\n"
~"#46 0x081e1054 in PyObject_Call ()\n"
~"#47 0x08152c05 in _PyEval_EvalFrameDefault ()\n"
~"#48 0x0814d785 in ?? ()\n"
~"#49 0x0814f76f in ?? ()\n"
~"#50 0x081500a0 in ?? ()\n"
~"#51 0x0815186b in _PyEval_EvalFrameDefault ()\n"
~"#52 0x0814df2d in ?? ()\n"
~"#53 0x0814f76f in ?? ()\n"
~"#54 0x081500a0 in ?? ()\n"
~"#55 0x08152419 in _PyEval_EvalFrameDefault ()\n"
~"#56 0x0814d785 in ?? ()\n"
~"#57 0x081ca69f in ?? ()\n"
~"#58 0x081e1054 in PyObject_Call ()\n"
~"#59 0x08152c05 in _PyEval_EvalFrameDefault ()\n"
~"#60 0x0814df2d in ?? ()\n"
~"#61 0x0814f76f in ?? ()\n"
~"#62 0x081500a0 in ?? ()\n"
~"#63 0x0815186b in _PyEval_EvalFrameDefault ()\n"
~"#64 0x0814f4c2 in ?? ()\n"
~"#65 0x081500a0 in ?? ()\n"
~"#66 0x0815186b in _PyEval_EvalFrameDefault ()\n"
~"#67 0x0814d785 in ?? ()\n"
~"#68 0x0815097c in PyEval_EvalCode ()\n"
~"#69 0x08267ea1 in ?? ()\n"
~"#70 0x08267f52 in PyRun_FileExFlags ()\n"
~"#71 0x0826b84f in PyRun_SimpleFileExFlags ()\n"
~"#72 0x0826c430 in Py_Main ()\n"
~"#73 0x080f5c50 in main ()\n"
^done
(gdb)
^exit
Unable to setup pdb for remote debugging.
Please use a Python program built with debugging symbols.
```
Seems i need to restart nyx. Will keep it running though in case you have any idea to inspect its variables.Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/27938SQLite permission error writing to cache2018-10-18T19:19:43ZDamian JohnsonSQLite permission error writing to cacheI've had a couple users report nyx permission errors. Most likely this comes up when changing the user they run nyx as.
**Users should be able to work around this with the following...**
```
% echo "data_directory disabled" >> my_nyxrc...I've had a couple users report nyx permission errors. Most likely this comes up when changing the user they run nyx as.
**Users should be able to work around this with the following...**
```
% echo "data_directory disabled" >> my_nyxrc
% nyx --config my_nyxrc
```
Stacktrace users report are the following...
```
Traceback (most recent call last):
File "/usr/bin/nyx", line 11, in <module>
load_entry_point('nyx==2.0.4', 'console_scripts', 'nyx')()
File "/usr/lib/python3/dist-packages/nyx/__init__.py", line 176, in main
nyx.starter.main()
File "/usr/lib/python3/dist-packages/stem/util/conf.py", line 289, in wrapped
return func(*args, config = config, **kwargs)
File "/usr/lib/python3/dist-packages/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 "/usr/lib/python3/dist-packages/nyx/curses.py", line 217, in start
curses.wrapper(_wrapper)
File "/usr/lib/python3.6/curses/__init__.py", line 94, in wrapper
return func(stdscr, *args, **kwds)
File "/usr/lib/python3/dist-packages/nyx/curses.py", line 215, in _wrapper
function()
File "/usr/lib/python3/dist-packages/nyx/__init__.py", line 194, in draw_loop
interface = nyx_interface()
File "/usr/lib/python3/dist-packages/nyx/__init__.py", line 256, in nyx_interface
Interface() # constructor sets NYX_INTERFACE
File "/usr/lib/python3/dist-packages/nyx/__init__.py", line 589, in __init__
self._header_panel = nyx.panel.header.HeaderPanel()
File "/usr/lib/python3/dist-packages/nyx/panel/header.py", line 47, in __init__
self._vals = Sampling.create()
File "/usr/lib/python3/dist-packages/nyx/panel/header.py", line 235, in create
my_router_status_entry = nyx.tracker.get_consensus_tracker().my_router_status_entry()
File "/usr/lib/python3/dist-packages/nyx/tracker.py", line 169, in get_consensus_tracker
CONSENSUS_TRACKER = ConsensusTracker()
File "/usr/lib/python3/dist-packages/nyx/tracker.py", line 831, in __init__
self._update(ns_response)
File "/usr/lib/python3/dist-packages/nyx/tracker.py", line 853, in _update
writer.record_relay(fingerprint, address, or_port, nickname)
File "/usr/lib/python3/dist-packages/nyx/__init__.py", line 569, in record_relay
self._cache._query('INSERT OR REPLACE INTO relays(fingerprint, address, or_port, nickname) VALUES (?,?,?,?)', fingerprint, address, or_port, nickname)
File "/usr/lib/python3/dist-packages/nyx/__init__.py", line 541, in _query
return self._conn.execute(query, param)
sqlite3.OperationalError: attempt to write a readonly database
```
The cache is only for a performance improvement so when we lack cache write access nyx should emit a warning and simply avoid these calls.Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/27556nyx crashes on launch with error "can't rename process to somethign longer th...2018-10-19T19:57:18ZTracnyx crashes on launch with error "can't rename process to somethign longer than our initial name"Please let me know if this belongs in the stem bugs or if any further information is required.
I installed nyx through pip on a armhf version of alpine linux (alpine doesn't seem to have nyx in its repos), but nyx immediately crashes on...Please let me know if this belongs in the stem bugs or if any further information is required.
I installed nyx through pip on a armhf version of alpine linux (alpine doesn't seem to have nyx in its repos), but nyx immediately crashes on launch with the following error.
```
Traceback (most recent call last):
File "/usr/bin/nyx", line 11, in <module>
load_entry_point('nyx==2.0.4', 'console_scripts', 'nyx')()
File "/usr/lib/python3.6/site-packages/nyx/__init__.py", line 176, in main
nyx.starter.main()
File "/usr/lib/python3.6/site-packages/stem/util/conf.py", line 289, in wrapped
return func(*args, config = config, **kwargs)
File "/usr/lib/python3.6/site-packages/nyx/starter.py", line 106, in main
_set_process_name()
File "/usr/lib/python3.6/site-packages/nyx/starter.py", line 222, in _set_process_name
stem.util.system.set_process_name('nyx\0%s' % '\0'.join(sys.argv[1:]))
File "/usr/lib/python3.6/site-packages/stem/util/system.py", line 1413, in set_process_name
_set_argv(process_name)
File "/usr/lib/python3.6/site-packages/stem/util/system.py", line 1440, in _set_argv
raise IOError("Can't rename process to something longer than our initial name (this would overwrite memory used for the env)")
OSError: Can't rename process to something longer than our initial name (this would overwrite memory used for the env)
```
Tor version: 0.3.3.7 (from alpine repo)
Python version: 3.6.6 (from alpine repo)
Nyx version: 2.0.4 (from pip)
Stem version: 1.6.0 (from pip)
**Trac**:
**Username**: 0b6e5cf835f5887b1129c710613ae45dDamian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/27517./run_nyx shows stem's debug output2019-12-21T22:20:23Ztraumschule./run_nyx shows stem's debug outputI did not find out why I see stem's debug output with ./run_nyx from a fresh clone:
```
nyx_fresh$ ./run_nyx -d nyx.log
TRACE:stem:Nyx 2.0.4-dev Debug Dump
Stem Version: 1.6.0
Python Version: 2.7.15
Platform: Linux (debian buster/sid )
...I did not find out why I see stem's debug output with ./run_nyx from a fresh clone:
```
nyx_fresh$ ./run_nyx -d nyx.log
TRACE:stem:Nyx 2.0.4-dev Debug Dump
Stem Version: 1.6.0
Python Version: 2.7.15
Platform: Linux (debian buster/sid )
--------------------------------------------------------------------------------
Nyx Configuration (/home/user/.nyx/config):
[file doesn't exist]
--------------------------------------------------------------------------------
Saving a debug log to nyx.log, please check it for sensitive information before sharing it.
NOTICE:stem:No nyxrc loaded, using defaults. You can customize nyx by placing a configuration file at /home/user/.nyx/config (see https://nyx.torproject.org/nyxrc.sample for its options).
TRACE:stem:config entry 'tor_chroot' not found, defaulting to ''
TRACE:stem:Sent to tor: PROTOCOLINFO 1
TRACE:stem:Received from tor:
250-PROTOCOLINFO 1
250-AUTH METHODS=COOKIE,SAFECOOKIE,HASHEDPASSWORD COOKIEFILE="/var/run/tor/control.authcookie"
250-VERSION Tor="0.3.5.0-alpha-dev"
250 OK
Tor controller password:
```
(follow-up of #27350)Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/27475Scrub connection info for any non-relay2019-01-03T22:08:12ZDamian JohnsonScrub connection info for any non-relayNyx attempts to be a bit too smart with its 'should I scrub connection info?' check. As teor points out there's quite a few scenarios where this can go wrong...
https://lists.torproject.org/pipermail/tor-relays/2018-September/016153.htm...Nyx attempts to be a bit too smart with its 'should I scrub connection info?' check. As teor points out there's quite a few scenarios where this can go wrong...
https://lists.torproject.org/pipermail/tor-relays/2018-September/016153.html
Presently the check is 'scrub the connection if it isn't in the consensus **and** I'm a bridge, guard, or exit'. We should drop this second clause (ie. scrub anything not in the consensus).Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/27350Nyx -d ignores supplied file name2020-06-13T08:11:26ZtraumschuleNyx -d ignores supplied file nameThanks for this nice tool!
Running nyx from git without arguments destroys the interface with stem debug messages. One needs to
```
$ ./run_nyx 2>nyx.log
```
The offered -d option seems to fail reliably:
```
$ ./run_nyx -d nyx.log
Trace...Thanks for this nice tool!
Running nyx from git without arguments destroys the interface with stem debug messages. One needs to
```
$ ./run_nyx 2>nyx.log
```
The offered -d option seems to fail reliably:
```
$ ./run_nyx -d nyx.log
Traceback (most recent call last):
File "./run_nyx", line 14, in <module>
nyx.main()
File "nyx/nyx/__init__.py", line 176, in main
nyx.starter.main()
File "/usr/lib/python2.7/dist-packages/stem/util/conf.py", line 289, in wrapped
return func(*args, config = config, **kwargs)
File "nyx/nyx/starter.py", line 67, in main
_setup_debug_logging(args)
File "nyx/nyx/starter.py", line 135, in _setup_debug_logging
os.makedirs(debug_dir)
File "/usr/lib/python2.7/os.py", line 157, in makedirs
mkdir(name, mode)
OSError: [Errno 2] No such file or directory: ''
```
The packaged version says
```
$ nyx -d nyx.log
Unable to write to our debug log file (nyx.log): No such file or directory
$ nyx --version
nyx version 2.0.4 (released November 5, 2017)
```Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/27321incorrect bw calculation during initial startup2018-12-29T20:17:44ZTracincorrect bw calculation during initial startupwhen I start nyx on a relay it takes about 5 seconds until the UI appears.
The very first value for download and upload bandwidth is always extremely and unreasonably high (3GB/s) and reaches the actual value one second after that.
Th...when I start nyx on a relay it takes about 5 seconds until the UI appears.
The very first value for download and upload bandwidth is always extremely and unreasonably high (3GB/s) and reaches the actual value one second after that.
The problem of this is the impact on the avg. bw value shown, which is distorted due to this incorrect first value.
connected to tor via a controlsocket (not controlport)
os: FreeBSD 11.2
nyx version: 2.0.4
Python 3.6.6
**Trac**:
**Username**: a_pDamian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/26584nyx crashes on startup with insufficient terminal size2018-06-30T18:52:30ZTracnyx crashes on startup with insufficient terminal sizeOn OpenBSD/sparc64 -current, nyx 2.0.4 dumps the following trace if the controlling terminal is too small.
I'd expect this exit gracefully or show a limited view that fits.
```
$ echo $TERM
screen
$ resize
COLUMNS=105;
LINES=13;
export...On OpenBSD/sparc64 -current, nyx 2.0.4 dumps the following trace if the controlling terminal is too small.
I'd expect this exit gracefully or show a limited view that fits.
```
$ echo $TERM
screen
$ resize
COLUMNS=105;
LINES=13;
export COLUMNS LINES;
$ nyx-relay
Exception in thread Thread-6:
Traceback (most recent call last):
File "/usr/local/lib/python3.6/threading.py", line 916, in _bootstrap_inner
self.run()
File "/usr/local/lib/python3.6/threading.py", line 864, in run
self._target(*self._args, **self._kwargs)
File "/usr/local/lib/python3.6/site-packages/nyx/__init__.py", line 740, in halt_panels
panel.join()
File "/usr/local/lib/python3.6/threading.py", line 1051, in join
raise RuntimeError("cannot join thread before it is started")
RuntimeError: cannot join thread before it is started
Traceback (most recent call last):
File "/usr/local/bin/nyx", line 11, in <module>
load_entry_point('nyx==2.0.4', 'console_scripts', 'nyx')()
File "/usr/local/lib/python3.6/site-packages/nyx/__init__.py", line 176, in main
nyx.starter.main()
File "/usr/local/lib/python3.6/site-packages/stem/util/conf.py", line 289, in wrapped
return func(*args, config = config, **kwargs)
File "/usr/local/lib/python3.6/site-packages/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 "/usr/local/lib/python3.6/site-packages/nyx/curses.py", line 217, in start
curses.wrapper(_wrapper)
File "/usr/local/lib/python3.6/curses/__init__.py", line 94, in wrapper
return func(stdscr, *args, **kwds)
File "/usr/local/lib/python3.6/site-packages/nyx/curses.py", line 215, in _wrapper
function()
File "/usr/local/lib/python3.6/site-packages/nyx/__init__.py", line 200, in draw_loop
interface.redraw()
File "/usr/local/lib/python3.6/site-packages/nyx/__init__.py", line 716, in redraw
panel.redraw(force = force, top = occupied)
File "/usr/local/lib/python3.6/site-packages/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 "/usr/local/lib/python3.6/site-packages/nyx/curses.py", line 740, in draw
curses_subwindow = CURSES_SCREEN.subwin(subwindow_height, subwindow_width, top, left)
_curses.error: curses function returned NULL
```
**Trac**:
**Username**: knDamian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/26244The ability to jump to the bottom or top of the connection list in Nyx2018-06-30T17:02:55ZTracThe ability to jump to the bottom or top of the connection list in NyxThe ability to jump to the bottom or top of the connection list in Nyx is needed because it can take minutes when I have thousands of connections and I have to use the arrow keys to go from the bottom to the top. Tested using Nyx 2.0.4
...The ability to jump to the bottom or top of the connection list in Nyx is needed because it can take minutes when I have thousands of connections and I have to use the arrow keys to go from the bottom to the top. Tested using Nyx 2.0.4
**Trac**:
**Username**: DbryrtfbcbhgfDamian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/26099Missing dependency 'python3-distutils' for 'nyx' package from deb.torproject....2019-01-11T19:27:48ZcypherpunksMissing dependency 'python3-distutils' for 'nyx' package from deb.torproject.org for bionicI've obtained Tor from the following source:
```
deb https://deb.torproject.org/torproject.org bionic main
deb-src https://deb.torproject.org/torproject.org xenial main
```
However I had to manually install python3-distuils and python3...I've obtained Tor from the following source:
```
deb https://deb.torproject.org/torproject.org bionic main
deb-src https://deb.torproject.org/torproject.org xenial main
```
However I had to manually install python3-distuils and python3-distutils-extra in order to start Nyx. It would otherwise fail to start saying that it's missing the module distutils.spawn
Ubuntu 18.04.0Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/26084Graph not updating on Tor 0.3.4.0-alpha-dev2018-05-13T02:14:46ZcypherpunksGraph not updating on Tor 0.3.4.0-alpha-devI decided to test out git version of Tor (Tor version 0.3.4.0-alpha-dev (git-382beb93cb4110b2)).
After the upgrade, the nyx graph no longer updates at all. It's all blank. Affects not only the bandwidth graph but it doesn't work on "res...I decided to test out git version of Tor (Tor version 0.3.4.0-alpha-dev (git-382beb93cb4110b2)).
After the upgrade, the nyx graph no longer updates at all. It's all blank. Affects not only the bandwidth graph but it doesn't work on "resources" or "connections" either.
It was working fine on Tor 0.3.3.5-rc.
I have nyx 2.0.4 and Python 2.7.15Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/26026ValueError: "blue" isn't a valid color - color_interface is not working2018-05-05T18:34:24ZcypherpunksValueError: "blue" isn't a valid color - color_interface is not workingHi,
I came across an error while editing my configuration file for nyx.
When I choose the color "blue" as shown on the NYX-configuration page as an exsample, the error ""blue" isn't a valid color" is recived.
In fact none of the colors...Hi,
I came across an error while editing my configuration file for nyx.
When I choose the color "blue" as shown on the NYX-configuration page as an exsample, the error ""blue" isn't a valid color" is recived.
In fact none of the colors for "color_interface" work.
Configuration file /home/<user>/.nyx/config/nyxrc
```
graph_stat bandwidth
graph_bound tight
max_graph_width 200
show_interpreter false
connection_rate 10
#acs_support true
color_override blue
#color_interface false
```
Error from python3
```
Traceback (most recent call last):
File "/usr/local/bin/nyx", line 11, in <module>
load_entry_point('nyx==2.0.4.dev0', 'console_scripts', 'nyx')()
File "/usr/local/lib/python3.5/dist-packages/nyx-2.0.4.dev0-py3.5.egg/nyx/__init__.py", line 176, in main
nyx.starter.main()
File "/usr/local/lib/python3.5/dist-packages/stem-1.6.0-py3.5.egg/stem/util/conf.py", line 289, in wrapped
return func(*args, config = config, **kwargs)
File "/usr/local/lib/python3.5/dist-packages/nyx-2.0.4.dev0-py3.5.egg/nyx/starter.py", line 75, in main
config.load(args.config)
File "/usr/local/lib/python3.5/dist-packages/stem-1.6.0-py3.5.egg/stem/util/conf.py", line 503, in load
self.load(os.path.join(root, filename))
File "/usr/local/lib/python3.5/dist-packages/stem-1.6.0-py3.5.egg/stem/util/conf.py", line 526, in load
self.set(key, value.strip(), False)
File "/usr/local/lib/python3.5/dist-packages/stem-1.6.0-py3.5.egg/stem/util/conf.py", line 654, in set
listener(self, key)
File "/usr/local/lib/python3.5/dist-packages/stem-1.6.0-py3.5.egg/stem/util/conf.py", line 190, in update
interceptor_value = self.interceptor(key, new_value)
File "/usr/local/lib/python3.5/dist-packages/nyx-2.0.4.dev0-py3.5.egg/nyx/curses.py", line 173, in conf_handler
raise ValueError('"%s" isn\'t a valid color' % value)
ValueError: "blue" isn't a valid color
```
Best regards and thanks for the good work.
StephanTor: 0.3.2.x-finalDamian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/25970Can not start nyx in a Raspberry pi 32019-01-09T19:00:33ZcypherpunksCan not start nyx in a Raspberry pi 3Dear friend I am a newbie and sorry to disturb you, but I really do not know why this is happening?
When I try to start nyx I receive an error about sqlite3 database.
Enclosed some pictures.
<a href="https://ibb.co/fjgOBx"><img src="...Dear friend I am a newbie and sorry to disturb you, but I really do not know why this is happening?
When I try to start nyx I receive an error about sqlite3 database.
Enclosed some pictures.
<a href="https://ibb.co/fjgOBx"><img src="https://preview.ibb.co/hYRZJc/Captura_de_tela_2018_04_29_23_56_29_nyx_erro_01.png" alt="Captura_de_tela_2018_04_29_23_56_29_nyx_erro_01" border="0"></a>
<a href="https://ibb.co/iKtQPH"><img src="https://preview.ibb.co/m1wejH/Captura_de_tela_2018_04_29_23_56_29_nyx_erro_02.png" alt="Captura_de_tela_2018_04_29_23_56_29_nyx_erro_02" border="0"></a>
<a href="https://ibb.co/mwNVrx"><img src="https://preview.ibb.co/buWOBx/Captura_de_tela_2018_04_29_23_56_29_nyx_erro_03.png" alt="Captura_de_tela_2018_04_29_23_56_29_nyx_erro_03" border="0"></a><br /><a target='_blank' href='https://deleteacc.com/g'>delete your account</a><br />Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/25890add instructions for running nyx safely to the FAQ2020-06-13T09:02:50ZRoger Dingledineadd instructions for running nyx safely to the FAQOn the tor-relay-debian page, we used to tell people how to configure arm/nyx safely: see item 13 on
https://web.archive.org/web/20171019233402/https://www.torproject.org/docs/tor-relay-debian
The trick is to add your user to the debian-...On the tor-relay-debian page, we used to tell people how to configure arm/nyx safely: see item 13 on
https://web.archive.org/web/20171019233402/https://www.torproject.org/docs/tor-relay-debian
The trick is to add your user to the debian-tor group, not to sudo your nyx to run as the debian-tor user.
We seem to have dropped those instructions when we migrated to the wiki page at https://trac.torproject.org/projects/tor/wiki/TorRelayGuide
I noticed just now because I was trying to help another arm/nyx user on #tor, who was doing it the wrong way (presumably because they were following old instructions from somewhere else, like the old arm documentation).Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/25801Unhandled exceptions in nyx2018-04-15T20:29:56ZcypherpunksUnhandled exceptions in nyxRunning nyx 2.0.4 from FreeBSD repository, after going to the 'Connections' page which can be empty (AFAIK it depends on tor configuration), pressing a button which would normally lead to some useful information (eg 'd' or 'e') results i...Running nyx 2.0.4 from FreeBSD repository, after going to the 'Connections' page which can be empty (AFAIK it depends on tor configuration), pressing a button which would normally lead to some useful information (eg 'd' or 'e') results in an unhandled exception and shuts nyx down.
Key 'd' fails with:
```
Traceback (most recent call last):
File "/usr/local/bin/nyx", line 11, in <module>
load_entry_point('nyx==2.0.4', 'console_scripts', 'nyx')()
File "/usr/local/lib/python2.7/site-packages/nyx/__init__.py", line 176, in main
nyx.starter.main()
File "/usr/local/lib/python2.7/site-packages/stem/util/conf.py", line 289, in wrapped
return func(*args, config = config, **kwargs)
File "/usr/local/lib/python2.7/site-packages/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 "/usr/local/lib/python2.7/site-packages/nyx/curses.py", line 217, in start
curses.wrapper(_wrapper)
File "/usr/local/lib/python2.7/curses/wrapper.py", line 43, in wrapper
return func(stdscr, *args, **kwds)
File "/usr/local/lib/python2.7/site-packages/nyx/curses.py", line 215, in _wrapper
function()
File "/usr/local/lib/python2.7/site-packages/nyx/__init__.py", line 243, in draw_loop
keybinding.handle(key)
File "/usr/local/lib/python2.7/site-packages/nyx/panel/__init__.py", line 84, in handle
self._action()
File "/usr/local/lib/python2.7/site-packages/nyx/panel/connection.py", line 367, in _show_descriptor
color = CONFIG['attr.connection.category_color'].get(selected.entry.get_type(), WHITE)
AttributeError: 'tuple' object has no attribute 'entry'
```
Key 'e' fails with:
```
Traceback (most recent call last):
File "/usr/local/bin/nyx", line 11, in <module>
load_entry_point('nyx==2.0.4', 'console_scripts', 'nyx')()
File "/usr/local/lib/python2.7/site-packages/nyx/__init__.py", line 176, in main
nyx.starter.main()
File "/usr/local/lib/python2.7/site-packages/stem/util/conf.py", line 289, in wrapped
return func(*args, config = config, **kwargs)
File "/usr/local/lib/python2.7/site-packages/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 "/usr/local/lib/python2.7/site-packages/nyx/curses.py", line 217, in start
curses.wrapper(_wrapper)
File "/usr/local/lib/python2.7/curses/wrapper.py", line 43, in wrapper
return func(stdscr, *args, **kwds)
File "/usr/local/lib/python2.7/site-packages/nyx/curses.py", line 215, in _wrapper
function()
File "/usr/local/lib/python2.7/site-packages/nyx/__init__.py", line 243, in draw_loop
keybinding.handle(key)
File "/usr/local/lib/python2.7/site-packages/nyx/panel/__init__.py", line 84, in handle
self._action()
File "/usr/local/lib/python2.7/site-packages/nyx/panel/connection.py", line 394, in _show_exiting_port_usage
key_width = max(map(len, self._exit_port_usage.keys()))
ValueError: max() arg is an empty sequence
```Damian JohnsonDamian Johnsonhttps://gitlab.torproject.org/legacy/trac/-/issues/25739Nyx: empty exit policy if ipv6 address is not surrounded by [..]2018-04-14T20:41:34ZtoralfNyx: empty exit policy if ipv6 address is not surrounded by [..]```
./run_nyx
```
gives an empty
```
exit policy:
```
line in that case.
Example for a wrong line:
```
ExitPolicy reject6 <snip>/32
```
Good is
```
ExitPolicy reject6 [<snip>]/32
```
Tested with latest stem and nyx Git trees.```
./run_nyx
```
gives an empty
```
exit policy:
```
line in that case.
Example for a wrong line:
```
ExitPolicy reject6 <snip>/32
```
Good is
```
ExitPolicy reject6 [<snip>]/32
```
Tested with latest stem and nyx Git trees.Damian JohnsonDamian Johnson