There's a very rare race condition where a tagged thread doesn't seem to exist when the proxy tries syncing startup with them, and so the proxy thread hangs in startup.
This is an attempt to fix it by avoiding looking at the proxy_thread variable (which probably isn't thread safe) in the worker's startup.
(This is currently just a guess though).
Looks like it solved it: this passed 3000 consecutive test suite runs with no stall in lokinet, whereas without it we were getting a failure roughly every 100-200 or so runs.
There's a very rare race condition where a tagged thread doesn't seem to exist when the proxy tries syncing startup with them, and so the proxy thread hangs in startup.
This is an attempt to fix it by avoiding looking at the proxy_thread variable (which probably isn't thread safe) in the worker's startup.
(This is currently just a guess though).Looks like it solved it: this passed 3000 consecutive test suite runs with no stall in lokinet, whereas without it we were getting a failure roughly every 100-200 or so runs.