Open prscoelho opened 2 years ago
I noticed this too (see #3083). Helix did start eventually, but it took ~2mins before xsel timed out.
Oh shoot, I searched in issues but not discussions :(
What do you think about running these clipboard commands with timeout, would it be a proper solution?
Giving up after a reasonable amount of time in helix_view::clipboard::provider::command::is_exit_success
would be a good solution to this. I don't think we should shell out to timeout
though. Handling this within that function in Rust would be better.
It looks like this isn't exactly trivial, how do you feel about adding a dependency on wait-timeout?
We shouldn't need any new crates for this: we already have tokio which is capable of spawning futures with timeouts.
Summary
Environment: Wsl running debian 11 (windows 10). Installed hx from source, 22.08 tag.
I have DISPLAY set so I can run frontend e2e tests, but the xorg server in windows (vcxsrv) isn't always running, I only turn it on to run the tests. I'm sure it's incorrect to have DISPLAY set while xorg server is not running, and I'll probably comment this from my settings from now on, but it still seems wrong that helix would fail to start, and I've had this env set for months without running into any other issues.
The cause of the problem seems to be xsel,
xsel -o -b
hangs with the exact same behavior as hx.Maybe the answer here is just don't have DISPLAY set if xserver isn't running, and if so feel free to close.
Reproduction Steps
Set DISPLAY to the IP in resolv.conf nameserver :0 , but have vcxsrv not running. I tried this: 1. `hx` I expected this to happen: Helix to start Instead, this happened: Nothing happens. `xsel -o -b` hangs just like hx. Unsetting display or turning vcxsrv on fixes the problem. ### Helix log~/.cache/helix/helix.log
``` please provide a copy of `~/.cache/helix/helix.log` here if possible, you may need to redact some of the lines ```