onagre-launcher / onagre

A general purpose application launcher for X and wayland inspired by rofi/wofi and alfred
MIT License
536 stars 26 forks source link

Can't start onagre on arch linux, with a fresh install. #72

Open neevparikh opened 9 months ago

neevparikh commented 9 months ago

Describe the bug A clear and concise description of what the bug is.

Just running onagre won't do anything. It shows a blank window with no options and won't accept text or respond to keyboard signals. image

Running it with either the vulkan or gl backend, it briefly allows for some text and then hangs up again. Both backends do the same thing.

image

Running it with backtrace does nothing. Running with debug doesn't seem to reveal anything important. but I've included them here for posteritiy.

image

onagre_debug.log

Config If relevant, provide a copy of your onagre config/theme.

Just using default nord theme. same thing happens with no theme.

To Reproduce Steps to reproduce the behavior:

Run onagre.

Expected behavior A clear and concise description of what you expected to happen.

Accepts input

Screenshots If applicable, add screenshots to help explain your problem. see above

Window manager (please complete the following information):

Additional context Add any other context about the problem here.

Jaakkonen commented 9 months ago

Also happens on my machine. Did a fresh debug build from latest git and ran with rust-gdb. The issue didn't manifestate when using Intel GPU but reliably happened on Nvidia GPU.

>> WORKS
$ VK_ICD_FILENAMES=/usr/share/vulkan/icd.d/intel_icd.x86_64.json \
  target/debug/onagre
>> Fails, see stacktrace below
$ WGPU_BACKEND=vulkan \
  VK_ICD_FILENAMES=/usr/share/vulkan/icd.d/nvidia_icd.json \
  rust-gdb target/debug/onagre
Nvidia Stacktrace on hang ```rust #0 0x00007ffff7c0cf6f in __GI___poll (fds=0x55555bb9ae20, nfds=1, timeout=10) at ../sysdeps/unix/sysv/linux/poll.c:29 #1 0x00007fff85336d83 in ?? () from /usr/lib/libnvidia-glcore.so.545.29.06 #2 0x00007fff857194c9 in ?? () from /usr/lib/libnvidia-glcore.so.545.29.06 #3 0x00007fff85732cc0 in ?? () from /usr/lib/libnvidia-glcore.so.545.29.06 #4 0x00007fff8564b96e in ?? () from /usr/lib/libnvidia-glcore.so.545.29.06 #5 0x00007fff7c5c8694 in DispatchWaitForFences (device=0x55555b3656f0, fenceCount=1, pFences=0x7ffffffecc20, waitAll=1, timeout=18446744073709551615) at /usr/src/debug/vulkan-validation-layers/Vulkan-ValidationLayers-vulkan-sdk-1.3.268.0/layers/vulkan/generated/layer_chassis_dispatch.cpp:809 #6 0x00007fff7c4ab9c3 in vulkan_layer_chassis::WaitForFences (device=0x55555b3656f0, fenceCount=1, pFences=0x7ffffffecc20, waitAll=1, timeout=18446744073709551615) at /usr/src/debug/vulkan-validation-layers/Vulkan-ValidationLayers-vulkan-sdk-1.3.268.0/layers/vulkan/generated/chassis.cpp:1728 #7 0x00005555564eefa4 in ash::device::Device::wait_for_fences (self=0x55555b345540, fences=&[ash::vk::definitions::Fence](size=1) = {...}, wait_all=true, timeout=18446744073709551615) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/ash-0.37.3+1.3.251/src/device.rs:2399 #8 0x000055555656d06d in wgpu_hal::vulkan::instance::{impl#5}::acquire_texture (self=0x55555b31bad8, timeout=...) at src/vulkan/instance.rs:783 #9 0x00005555562d4d23 in wgpu_core::hub::Global::surface_get_current_texture ( self=0x55555b319ea0, surface_id=..., texture_id_in=()) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/wgpu-core-0.15.1/src/present.rs:141 #10 0x0000555556388f36 in wgpu::backend::direct::{impl#7}::surface_get_current_texture (self=0x55555b319ea0, surface=0x7ffffffee5f8, surface_data=0x55555b935e20) at src/backend/direct.rs:763 #11 0x00005555563a2168 in wgpu::context::{impl#5}::surface_get_current_texture (self=0x55555b319ea0, surface=0x55555b99a9f0, surface_data=...) at src/context.rs:2069 #12 0x00005555560e958d in wgpu::Surface::get_current_texture (self=0x55555b99a9d0) at src/lib.rs:4136 #13 0x0000555555a2c48b in iced_wgpu::window::compositor::{impl#1}::present (self=0x55555b999450, renderer=0x55555b999578, surface=0x55555b99a9d0, viewport=0x55555b997d80, background_color=, overlay=&[alloc::string::String](size=0)) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/iced_wgpu-0.10.0/src/window/compositor.rs:205 #14 0x000055555586e77f in iced_winit::application::run_instance::{async_fn#0}, tokio::runtime::runtime::Runtime, iced_wgpu::window::compositor::Compositor> () at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/iced_winit-0.9.1/src/application.rs:525 #15 0x0000555555870977 in iced_winit::application::run::{closure#1}, tokio::runtime::runtime::Runtime, iced_wgpu::window::compositor::Compositor> (event=..., control_flow=0x7fffffff07e8) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/iced_winit-0.9.1/src/application.rs:251 #16 0x000055555584d1f7 in winit::platform_impl::platform::sticky_exit_callback, tokio::runtime::runtime::Runtime, iced_wgpu::window::compositor::Compositor>> (evt=..., target=0x555557f93bd8, control_flow=0x7fffffff07e8, callback=0x7fffffffd080) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.27.5/src/platform_impl/linux/mod.rs:849 #17 0x00005555557e97c7 in winit::platform_impl::platform::wayland::event_loop::EventLoop::run_return, tokio::runtime::runtime::Runtime, iced_wgpu::window::compositor::Compositor>> (self=0x555557f93bc0, callback=...) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.27.5/src/platform_impl/linux/wayland/event_loop/mod.rs:529 #18 0x000055555584c637 in winit::platform_impl::platform::EventLoop::run_return, tokio::runtime::runtime::Runtime, iced_wgpu::window::compositor::Compositor>> (self=0x7fffffffcdf8, callback=...) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.27.5/src/platform_impl/linux/mod.rs:748 #19 0x00005555557d3cca in winit::platform::run_return::{impl#0}::run_return, tokio::runtime::runtime::Runtime, iced_wgpu::window::compositor::Compositor>> (self=0x7fffffffcdf8, event_handler=) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.27.5/src/platform/run_return.rs:62 #20 0x00005555559e2c6d in iced_winit::application::platform::run, tokio::runtime::runtime::Runtime, iced_wgpu::window::compositor::Compositor>> (event_loop=..., event_handler=...) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/iced_winit-0.9.1/src/application.rs:870 #21 0x0000555555870225 in iced_winit::application::run, tokio::runtime::runtime::Runtime, iced_wgpu::window::compositor::Compositor> (settings=..., compositor_settings=...) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/iced_winit-0.9.1/src/application.rs:226 #22 0x00005555559d87c8 in iced::application::Application::run (settings=...) at /home/jaakko/.local/share/cargo/registry/src/index.crates.io-6f17d22bba15001f/iced-0.9.0/src/application.rs:209 #23 0x0000555555860f7d in onagre::app::run () at src/app/mod.rs:48 #24 0x00005555557fa8af in onagre::main () at src/main.rs:54 ``` And with a release build `VK_ICD_FILENAMES=/usr/share/vulkan/icd.d/nvidia_icd.json rust-gdb target/release/onagre` ```rust #0 0x00007ffff7c69f6f in __GI___poll (fds=0x555558551430, nfds=1, timeout=10) at ../sysdeps/unix/sysv/linux/poll.c:29 #1 0x00007fff853ffd83 in ?? () from /usr/lib/libnvidia-glcore.so.545.29.06 #2 0x00007fff857e24c9 in ?? () from /usr/lib/libnvidia-glcore.so.545.29.06 #3 0x00007fff857fbcc0 in ?? () from /usr/lib/libnvidia-glcore.so.545.29.06 #4 0x00007fff8571496e in ?? () from /usr/lib/libnvidia-glcore.so.545.29.06 #5 0x0000555555e07824 in ::surface_get_current_texture::hb96e01549eaaa379 () #6 0x000055555565cdcb in iced_winit::application::run_instance::{{closure}}::h2002aab6e0aa094a () #7 0x00005555556751ce in iced_winit::application::run::{{closure}}::h78b5fcea3b07a440 () #8 0x000055555566f19c in iced_winit::application::run::h84847475da4a65c1 () #9 0x000055555576c0c8 in onagre::main::h4639f644572ad6de () #10 0x00005555556a7613 in std::sys_common::backtrace::__rust_begin_short_backtrace::h45f78273e70934af () #11 0x00005555556a80ea in std::rt::lang_start::h7b2de4ecb1532c87 () #12 0x00007ffff7b8ecd0 in __libc_start_call_main ( main=main@entry=0x555555771ba0
, argc=argc@entry=1, argv=argv@entry=0x7fffffffdb88) at ../sysdeps/nptl/libc_start_call_main.h:58 #13 0x00007ffff7b8ed8a in __libc_start_main_impl ( main=0x555555771ba0
, argc=1, argv=0x7fffffffdb88, init=, fini=, rtld_fini=, stack_end=0x7fffffffdb78) at ../csu/libc-start.c:360 #14 0x00005555556524c5 in _start () ```

A similar hang in DispatchWaitForFences on Nvidia GPUs in other code is mentioned on an Ogre3d forum thread to which a buffer clear fix is suggested. Presumably the fix needs to be done in WGPU or Iced afaik.

Jaakkonen commented 9 months ago

In my case WGPU defaults to using Nvidia and Vulkan by default. Have you tried running it with WGPU_BACKEND=gl onagre? Or if you have an integrated graphics chip forcing Vulkan to use it instead of Nvidia graphics card?

neevparikh commented 9 months ago

It hangs with both gl and vulkan unfortunately :/

Best, Neev Parikh

On Sun, Dec 24, 2023 at 4:46 AM Jaakko Sirén @.***> wrote:

In my case WGPU defaults to using Nvidia and Vulkan by default. Have you tried running it with WGPU_BACKEND=gl onagre? Or if you have an integrated graphics chip forcing Vulkan to use it instead of Nvidia graphics card?

— Reply to this email directly, view it on GitHub https://github.com/oknozor/onagre/issues/72#issuecomment-1868509009, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJ2GJYD7O3I75G4YBY4UFILYLAP4DAVCNFSM6AAAAABA7JL2F2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNRYGUYDSMBQHE . You are receiving this because you authored the thread.Message ID: @.***>

oknozor commented 8 months ago

Hey can you try with the latest version (cargo install --git https://github.com/onagre-launcher/onagre). I think we are close to a stable release and I'd like to confirm this is fixed.

markstos commented 7 months ago

I just tried launching it with Arch Linux and Sway and it opened.