hyprwm / Hyprland

Hyprland is an independent, highly customizable, dynamic tiling Wayland compositor that doesn't sacrifice on its looks.
https://hyprland.org
BSD 3-Clause "New" or "Revised" License
21.91k stars 913 forks source link

Hyprland fails to initiate: Assertion '_M_has_value' failed. #8552

Open Matgoeth opened 6 days ago

Matgoeth commented 6 days ago

Already reported ? *

Regression?

Yes

System Info and Version

System/Version info ```sh Hyprland 0.45.0 built from branch main at commit b1003445953474b967464d4d0878955d37498647 (). Date: Thu Nov 21 14:31:42 2024 Tag: , commits: 5486 built against aquamarine 0.5.0 flags set: debug System Information: System name: Linux Node name: griever Release: 6.11.8-200.fsync.fc40.x86_64 Version: #1 SMP PREEMPT_DYNAMIC TKG Thu Nov 14 21:06:14 UTC 2024 GPU information: 01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GA102 [GeForce RTX 3080] [10de:2206] (rev a1) (prog-if 00 [VGA controller]) NVRM version: NVIDIA UNIX x86_64 Kernel Module 565.57.01 Thu Oct 10 12:29:05 UTC 2024 os-release: NAME="Nobara Linux" VERSION="40 (GNOME Edition)" ID=nobara ID_LIKE="rhel centos fedora" VERSION_ID=40 VERSION_CODENAME="" PLATFORM_ID="platform:f40" PRETTY_NAME="Nobara Linux 40 (GNOME Edition)" ANSI_COLOR="0;38;2;60;110;180" LOGO=nobara-logo-icon CPE_NAME="cpe:/o:nobaraproject:nobara:40" DEFAULT_HOSTNAME="nobara" HOME_URL="https://nobaraproject.org/" DOCUMENTATION_URL="https://www.nobaraproject.org/" SUPPORT_URL="https://www.nobaraproject.org/" BUG_REPORT_URL="https://gitlab.com/gloriouseggroll/nobara-images" REDHAT_BUGZILLA_PRODUCT="Nobara" REDHAT_BUGZILLA_PRODUCT_VERSION=40 REDHAT_SUPPORT_PRODUCT="Nobara" REDHAT_SUPPORT_PRODUCT_VERSION=40 SUPPORT_END=2025-05-13 VARIANT="GNOME Edition" VARIANT_ID=gnome plugins: unknown: not runtime ```

Description

First off: thanks a lot for all the works you're doing on Hyprland, I love it!

About two weeks ago I upgraded Hyprland via standard dnf upgrade (I use _copr:copr.fedorainfracloud.org:solopasha:hyprland.repo repository which constantly builds Hyprland from latest git) but after upgrading to v0.45.0 my Hyprland doesn't seem to start correctly anymore. I went through Breaking Changes to check if anything can be the issue, but this time I didn't use features that were moved. So I decided it may be a broken build and I can wait it out. However, even now after upgrading to 0.45.2 my Hyprland doesn't seem to get any better plus checking crash logs seem to suggest a problem with something inside, mainly:

[LOG] Using config: /home/mati/.config/hypr/hyprland.conf
[...]
[LOG] Created a bezier curve, baked 255 points, mem usage: 4.08kB, time to bake: 1.96µs. Estimated average calc time: 0.02µs.
/usr/include/c++/14/expected:716: constexpr _Tp&& std::expected<_Tp, _Er>::operator*() && [with _Tp = long int; _Er = std::__cxx11::basic_string<char>]: Assertion '_M_has_value' failed.
Hyprland has crashed :( Consult the crash report at /home/mati/.cache/hyprland/hyprlandCrashReport12556.txt for more information.
[1]    12556 IOT instruction (core dumped)  Hyprland

I also tried to add

debug {
  disable_logs = false
  enable_stdout_logs = true
}

to my hyprland.config, but unfortunately this doesn't seem to produce anymore logs (does it mean Hyprland crashes before loading the config? Using config[...] line seems to suggest it's not the case). However if you need me to do anything specific in order to help with debug, I'll try to do that (I'm no C developer, but I am happy to learn a few things if needed).

Thanks in advance for any help that you guys can provide!

How to reproduce

As mentioned: I use hyprland-git package from _copr:copr.fedorainfracloud.org:solopasha:hyprland.repo and https://github.com/JaKooLit/Hyprland-Dots config with small modifications (additional keybinds, using dark GTK themes, nothing more really). Either starting Hyprland from tty or trying to go from logon screen ends up failing unfortunately.

Crash reports, logs, images, videos

Hyprlans Crash Log: hyprlandCrashReport10828.txt

vaxerski commented 6 days ago

Can you try on git? 0.45.0 is also not the latest release either. nvm, odd formatting, I hate packagers.

Anyways, get a debug stacktrace pls: https://wiki.hyprland.org/Crashes-and-Bugs/#obtaining-a-debug-stacktrace

Matgoeth commented 6 days ago

Thanks for taking your time on that, @vaxerski ! Please find my gdb.txt, super happy to help more if I can!

It seems that there may be the issue in my config though, because it has those lines:

  28   │ #11 0x00005644359f652f in configHandleGradientSet(char const*, void**) [clone .lto_priv.0] ()
  29   │ #12 0x00007f7a297249f8 in Hyprlang::CConfig::configSetValueSafe(std::__cxx11::basic_string<char, std:
       │ :char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<
       │ char>, std::allocator<char> > const&) () at /lib64/libhyprlang.so.2

...although without any further pointer on what particular line can be wrong I don't think I will be able to check further.

vaxerski commented 6 days ago

try now

Matgoeth commented 5 days ago

Thanks a lot, @vaxerski , this moved the issue further and allowed me to start Hyprland! Now the issue is: Config error in file /home/mati/.config/hypr/hyprland.conf at line 21:Config error in file /home/mati/.config/hypr/UserConfig/UserSettings.conf at line 33: Error parsing gradient rgb(1C1E1F)Col: No colors?

Relevant config is:

general {
[...]
  col.active_border = rgb(0A0000)
  col.inactive_border = rgb(1C1E1F)
}

And col.inactive_border = rgb(1C1E1F) causes trouble even though col.active_border = rgb(0A0000) seems okay. Theoretically it's sourced from wallust but up till now having this one as rgb(...) didn't produce issues (it doesn't seem this have changed according to the docs too). Of course fixing (hardcoding it to e.g. rgb(0A0000)) just this one is not really an issue, but I wonder why did it start to complain in the first place?

Also, mouse cursor seems ultra-choppy (window movement kinda too), but when I run some app it doesn't seem to be affected as much. I checked hyprctl monitors and my monitor's config just in case (in my experience this has caused some issues in the past) but for now it seems okay, so I guess this may be due to more config keys that use rgb(...) as their values (col.inactive_border is not the only one).

And chance I could ask you to have another look?

vaxerski commented 5 days ago

image

doesn't seem to cause any problems on my end?

Matgoeth commented 5 days ago

That's actually quite interesting! I started checking and it also doesn't appear on my end on bare 0.45.2 but it appears again every time when running 55ec8bd. Super strange!

My cursor is fine after applying cursor.no_hardware_cursors = true and everything seems to be in order (even though I didn't change anything really in terms of configuration beside cursor prop).

So it works for now but I just wonder if it won't get messed up again after next minor version. Guess I'll have to find out and I probably took way too much of your time from more important matters, man.

Super thankful for all of your work on this issue and Hyprland overall, feel free to close the issue for now, unless you see a point to dig further (then of course I am happy to help with whatever I can)

Have a great weekend!