Skip to content
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

Neovide closes immediately after starting in arch linux #1307

Closed
skyveil opened this issue May 9, 2022 · 7 comments · Fixed by #1458
Closed

Neovide closes immediately after starting in arch linux #1307

skyveil opened this issue May 9, 2022 · 7 comments · Fixed by #1458
Labels
bug Something isn't working

Comments

@skyveil
Copy link

skyveil commented May 9, 2022

Describe the bug
I installed neovide-git from AUR and on opening, it appears for a second and then closes without any warnings or errors

To Reproduce
Steps to reproduce the behavior:

  1. Install neovide-git from AUR
  2. launch neovide

Expected behavior
Neovide opens without any issue

Screenshots
output

Desktop (please complete the following information):

  • OS: Arch Linux 5.17.5
  • Neovide Version 0.9.0
  • Neovim Version 0.7.0

Please run neovide --log and paste the contents of the .log file created in the current directory here:
neovide_rCURRENT.log

Additional context
neovide package from AUR runs as expected

@skyveil skyveil added the bug Something isn't working label May 9, 2022
@brmejia
Copy link

brmejia commented May 9, 2022

Same behaviour for me with the following error:

thread 'main' panicked at 'attempt to divide by zero', src/window/mod.rs:207:20

Desktop:
OS: Fedora Desktop 35
Neovide Version 0.9.0 (Compiled from source using cargo)
Neovim Version 0.7.0

image

@MultisampledNight
Copy link
Contributor

Could you both please post your desktop environment, display protocol and display drivers?

@skyveil
Copy link
Author

skyveil commented May 9, 2022

window manager: i3
display server: X

$ lspci -k
...
00:02.0 VGA compatible controller [0300]: Intel Corporation GeminiLake [UHD Graphics 605] [8086:3184] (rev 03)
        Subsystem: Lenovo Device [17aa:398a]
        Kernel driver in use: i915
        Kernel modules: i915
...

@brmejia
Copy link

brmejia commented May 11, 2022

Window manager: gnome 41
Display protocol: X
Drivers (Failing with both graphic cards):

$ lspci -k | rg -A 3 NVIDIA
01:00.0 3D controller: NVIDIA Corporation TU117M [GeForce GTX 1650 Mobile / Max-Q] (rev a1)
        Subsystem: Hewlett-Packard Company Device 8601
        Kernel driver in use: nvidia
        Kernel modules: nouveau, nvidia_drm, nvidia
$ lspci -k | rg -A 4 VGA
00:02.0 VGA compatible controller: Intel Corporation CoffeeLake-H GT2 [UHD Graphics 630]
        DeviceName:  Onboard IGD
        Subsystem: Dell Device 0905
        Kernel driver in use: i915
        Kernel modules: i915

@skyveil
Copy link
Author

skyveil commented Jun 23, 2022

Any updates on this? It still seems to be broken.

@MultisampledNight
Copy link
Contributor

(to be honest, I plainly forgot about this issue)

...the fix may be trivially easy, looking at

neovide/src/window/mod.rs

Lines 205 to 209 in 7a3bf52

let scale_factor = window.scale_factor() as u32;
let new_size_scaled = PhysicalSize {
width: new_size.width / scale_factor,
height: new_size.height / scale_factor,
};

And indeed I can reproduce this by setting my scale to something below 1.0, but strangely only when running X11.

Anyways, a fix for this might be by just changing those lines to

        let scale_factor = window.scale_factor();
        let new_size_scaled = PhysicalSize {
            width: (f64::from(new_size.width) / scale_factor) as u32,
            height: (f64::from(new_size.height) / scale_factor) as u32,
        };

But that may bring back what was fixed in #1216. @rikiwarren sorry to mention you again, but could you test the fix-scale-below-zero on my fork and see whether it breaks certain command line args again?

@TheMagzuz
Copy link

A temporary fix to this would be to prefix the neovide command WINIT_X11_SCALE_FACTOR=1, forcing the scaling factor to be 1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants