New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
qutebrowser: shorten launch time marginally if an instance is already running #42839
Conversation
I'm not pleased with how I measured, but I guess it's accurate enough: |
@jagajaga Any thoughts on having it enabled by default ? |
@GrahamcOfBorg build qutebrowser |
Success on x86_64-linux (full log) Attempted: qutebrowser Partial log (click to expand)
|
Failure on x86_64-darwin (full log) Attempted: qutebrowser Partial log (click to expand)
|
Failure on aarch64-linux (full log) Attempted: qutebrowser Partial log (click to expand)
|
Setting |
Would it be possible to just get qutebrowser to come with a flag to do this? This isn't really something I like having Nixpkgs deal with. |
Motivation for this change
qutebrowser
can be made considerably faster to launch if an instance is already running, this method is documented in one of the scripts provided by the package:https://github.com/qutebrowser/qutebrowser/blob/master/scripts/open_url_in_instance.sh
Basically, socat is used to make an IPC call.
I've left it disabled by default because the behavior changes if an instance is already running, the initial call would block until the program is stopped, whereas a call to the IPC would exit immediately after having transmitted. This is, however, common to major browsers such as
chromium
.The optimization is disabled if
qutebrowser
is called with flags.socat
adds ~700kb to the 6.7mb derivationThings done
sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)nix path-info -S
before and after)