hyprlock icon indicating copy to clipboard operation
hyprlock copied to clipboard

Screen briefly visible if waking up with different display.

Open Vladimir-csp opened this issue 7 months ago • 20 comments

Regression?

No

Hyprlock Info and Version

Hyprlock version v0.8.2

Hyprlock config

Hyprlock config:

general {
  immediate_render = true
}

animations {
  enabled = true
  bezier = linear, 1, 1, 0, 0
  animation = fade, 1, 2, linear
  animation = inputField, 1, 1, linear
}

input-field {
  monitor =
  size = 400, 50
  font_family = Sans
  placeholder_text = $PAMPROMPT
  fail_text = $FAIL <b>($ATTEMPTS)</b>
  fade_on_empty = false
  rounding = 5
  outline_thickness = 2
  inner_color = rgba(181818e0)
  outer_color = rgba(33ccffee) rgba(00ff99ee) 45deg
  font_color = rgba(c0c0c0ee)
  check_color = rgba(ffff33ee) rgba(ffcc33ee) 45deg
  shadow_size = 1
  shadow_passes = 2
}

background {
  # transparent if no screenshot
  color = rgba(60606000)
  noise = 0.05
  contrast = 0.7
  brightness = 0.7
  vibrancy = 0
  vibrancy_darkness = 0
  path = screenshot
  blur_size = 16
  blur_passes = 3
}

# backup background if no screenshot
background {
  color = rgba(606060ff)
  noise = 0.05
  contrast = 0.7
  brightness = 0.7
  vibrancy = 0
  vibrancy_darkness = 0
  path = ~/.wallpapers/2024/AuroraGlacier_woodend_5760.png
  blur_size = 16
  blur_passes = 3
  zindex = -2
}

label {
  text = cmd[update:1000000] echo "$(whoami)@$(hostname -f)"
  font_size = 18
  color = rgba(f0f0f0e0)
  shadow_size = 1
  shadow_passes = 2
  halign = center
  valign = center
  position = 0, 15%
}

label {
  text = <b>$TIME</b>
  font_size = 32
  color = rgba(f0f0f0e0)
  shadow_size = 1
  shadow_passes = 2
  halign = center
  valign = center
  position = 0, 10%
}

label {
  text = cmd[update:30000] upower -i /org/freedesktop/UPower/devices/DisplayDevice | while IFS=':' read -r key value; do case "$key" in *' percentage') printf '🔋%s' ${value};; esac; done
  font_size = 14
  color = rgba(f0f0f0e0)
  shadow_size = 1
  shadow_passes = 2
  halign = center
  valign = center
  position = 0, 5%
}

label {
  text = <b>⌨ $LAYOUT</b>
  font_size = 14
  color = rgba(f0f0f0a0)
  shadow_size = 1
  shadow_passes = 2
  halign = center
  valign = center
  position = 0, -5%
}
Hypridle config Hypridle config:
general {
    lock_cmd = hyprlock -q
    unlock_cmd = pkill -u "$USER" -USR1 hyprlock
    before_sleep_cmd = loginctl lock-session
    #after_sleep_cmd = not
    ignore_dbus_inhibit = false             # whether to ignore dbus-sent idle-inhibit requests (used by e.g. firefox or steam)
    ignore_systemd_inhibit = false          # whether to ignore systemd-inhibit --what=idle inhibitors
}

Compositor Info and Version

System/Version info Debian sid
Hyprland 0.49.0 built from branch  at commit 9958d297641b5c84dcff93f9039d80a5ad37ab00  (version: bump to 0.49.0).
Date: Thu May 8 23:15:18 2025
Tag: v0.49.0, commits: 6098
built against:
 aquamarine 0.8.0
 hyprlang 0.6.3
 hyprutils 0.7.1
 hyprcursor 0.1.12
 hyprgraphics 0.1.3


no flags were set

Description

Screen content is briefly visible before hyprlock appears after waking up with different display. This does not happen when waking up with the same display.

How to reproduce

  • Have kanshi manage ouptups.
  • Have profiles for only external display, only internal display.
  • Suspend (screen is locked automatically via hypridle before suspend is finished).
  • Disconnect or connect external display.
  • Wake up

Crash reports, logs, images, videos

No response

Vladimir-csp avatar May 19 '25 18:05 Vladimir-csp

Please try to use hyprlock -q --no-fade-in.

I have a feeling that it's just that the first frame submitted by hyprlock is leaky.

PointerDilemma avatar May 21 '25 08:05 PointerDilemma

Adding -q seems to have fixed it, thanks. Was logging slowing it down?

Just a minor cosmetic issue:

It flashes with my background colour before showing the image. I'm guessing that's the time taken to load the image.

Is there any way to get rid of this? It is already being used by hyprland as it's the same as my wallpaper.

James46113 avatar May 21 '25 10:05 James46113

Adding -q seems to have fixed it, thanks.

Are you sure about that? I don't think that logging can be the problem.

It flashes with my background color before showing the image. I'm guessing that's the time taken to load the image.

That's what the immediate_render option is for.

PointerDilemma avatar May 21 '25 17:05 PointerDilemma

--no-fade-in does not help. This might be a hyprland's issue, since compositor should not draw anything except lockscreen when the screen is locked.

Vladimir-csp avatar May 22 '25 07:05 Vladimir-csp

This might be a hyprland's issue, since compositor should not draw anything except lockscreen when the screen is locked.

There are two things to it:

  1. Hyprland still draws the workspace below the lockscreen clients, if the client has at least one lock surface. This is planned to be removed once I manage to get #726 in.
  2. Hyprland in combination with hypridle supports a protocol named hyprland-lock-notify, which is supposed to ensure that hyprlock actually locked the screen before we allow systemd to suspend.

So if you are running hypridle and now use --no-fade-in, I guess that the problem is actually that we are running into a situation where your monitor is recognized immediately after wake up, Hyprland does it's thing, but hyprlock is not fast enought to submit a frame for the new monitor. This will be fixed once we manage to implement (1).

So keep an eye out for #726. I will keep you posted here.

PointerDilemma avatar May 22 '25 07:05 PointerDilemma

Also still seeing a flash of the desktop after waking from suspend. I'm using immediate-render, no-fade-in, inhibit-sleep=3 etc.

(This is just with the builtin laptop panel, not another monitor, but this seems to be the current issue for this problem.)

EDIT: after inspection of the logs, turns out i was specifying no_fade_in as a config option rather than a command line switch. With that corrected, I now no longer have the desktop flash on unsuspend. Surely the relevant event should not be emitted, and thus suspend should be inhibited, until after hyprlock has finished rendering though? Regardless of loading the background and fading in etc.

At the moment there still seems to be a race, albeit one that is winnable with the right settings.

JonnieCache avatar May 30 '25 14:05 JonnieCache

At the moment there still seems to be a race, albeit one that is winnable with the right settings.

That has been the situation without the protocol.

At least in theory, there shouldn't be a race assuming static monitors. It should go through the following sequence of events.

  1. Sleep triggers, but is inhibited by hypridle.
  2. Hypridle launches hyprlock via lock_cmd.
  3. Hyprlock locks the compositor.
  4. Hyprlock creates lock surfaces.
  5. Only when all monitors render a lock surface, Hyprland sends locked to hyprlock and notifies hypridle that it can release the sleep inhibitor.

The thing that should prevent any race is the "Only when all monitors render a lock surface" part. However there are some edge cases that we need to fix. Part of that is https://github.com/hyprwm/hyprlock/pull/726, which will improve the situation a bit. And it will further be improved once Hyprland doesn't draw it's workspace below lock surfaces anymore.

What will remain though is that fade-in may cause leakage. That's why my suggestion is to make your hypridle config be like this (different hyprlock command for before_sleep_cmd and lock_cmd):

general {
    before_sleep_cmd = hyprlock --no-fade-in --immediate
    lock_cmd = hyprlock
}

PointerDilemma avatar Jun 18 '25 06:06 PointerDilemma

See this: https://github.com/hyprwm/hypridle/issues/146

IiroUllin avatar Jul 01 '25 21:07 IiroUllin

Thanks @IiroUllin, let's move this to the hypridle issue. Hyprlock is only involved in terms of how it's first submitted frame looks.

PointerDilemma avatar Jul 03 '25 07:07 PointerDilemma

Tested with Hyprland 0.50.0 and hyprlock 0.9.0. Now I briefly see lockscreen crash screen when waking up with different monitor, but hyprlock did not crash. ...and I made a mistake in the initial assumption that sleep is involved, it does not: Lock screen, switch monitor, observe the same thing. It seems that hyprlock plays fade in animation every time it appears on screen, instead of just at the start.

I think the proper fix would be to disable fade in animation after it was played, or disable it when handling any new screen that was not present on startup, or better yet hardcode it to start from black in those cases.

Vladimir-csp avatar Jul 18 '25 06:07 Vladimir-csp

@Vladimir-csp

I think the proper fix would be to disable fade in animation after it was played, or disable it when handling any new screen that was not present on startup, or better yet hardcode it to start from black in those cases.

It alread does that. Or at least it is supposed to.

Hyprlock only does fade in at the start (In the code this is data.opacity, which is only modified during startup and during fade out. The first frames on new monitors also should always be solid.

I tried to reproduce what you described without luck.

I messed with my monitors a bunch, but it always worked fine. What exactly do you mean with

Lock screen, switch monitor

With "switch monitor", do you mean like unplugging your laptop and then re-plugging it into another monitor. If so are you plugging into one with different screen dimensions, or same?

Is the lid switch of your laptop involved at all?

Can you post some logs from hyprlock?

PointerDilemma avatar Jul 20 '25 09:07 PointerDilemma

I use kanshi, single monitor profiles (either external or laptop). So while external is connected, I lock screen, disconnect monitor, kanshi switches on laptop monitor where I see crash screen fading into hyprlock.

Vladimir-csp avatar Jul 20 '25 10:07 Vladimir-csp

Lock, disconnect, unlock. Hyprlock is tagged via hyprlidle in the journal.

Jul 20 13:24:13 hostname hypridle[3650530]: [LOG] Got dbus .Session
Jul 20 13:24:13 hostname hypridle[3650530]: [LOG] Got Lock from dbus
Jul 20 13:24:13 hostname hypridle[3650530]: [LOG] Locking with hyprlock
Jul 20 13:24:13 hostname hypridle[3650530]: [LOG] Executing hyprlock
Jul 20 13:24:13 hostname hypridle[3650530]: [LOG] Process Created with pid 3653404
Jul 20 13:24:14 hostname hypridle[3650530]: [LOG] Wayland session got locked
Jul 20 13:24:14 hostname hypridle[3650530]: [LOG] Executing
Jul 20 13:24:14 hostname hypridle[3650530]: [LOG] Process Created with pid 3653485
Jul 20 13:24:14 hostname hypridle[3650530]: [LOG] Releasing the sleep inhibitor!
Jul 20 13:24:16 hostname hyprpaper[4155750]: [LOG] Destroying output DP-3
Jul 20 13:24:16 hostname kanshi[3652845]: applying profile 'nomad'
Jul 20 13:24:16 hostname kanshi[3652845]: applying profile output 'eDP-1' on connected head 'eDP-1'
Jul 20 13:24:16 hostname qterminal[256751]: qt.qpa.wayland: There are no outputs - creating placeholder screen
Jul 20 13:24:16 hostname thunderbird[4159854]: [Parent 4159854, Main Thread] WARNING: Couldn't map window 0x7f2522b62da0 as subsurface because its parent is not mapped.: 'glib warning', file toolkit/xre/nsSigHandlers.cpp:187
Jul 20 13:24:16 hostname thunderbird[4159854]: [Parent 4159854, Main Thread] WARNING: Couldn't map window 0x7f2522b635c0 as subsurface because its parent is not mapped.: 'glib warning', file toolkit/xre/nsSigHandlers.cpp:187
Jul 20 13:24:16 hostname hypridle[3650530]: [LOG]   | removed iface 62
Jul 20 13:24:16 hostname thunderbird[4159854]: Couldn't map window 0x7f2522b635c0 as subsurface because its parent is not mapped.
Jul 20 13:24:16 hostname thunderbird[4159854]: [Parent 4159854, Main Thread] WARNING: Couldn't map window 0x7f2525484280 as subsurface because its parent is not mapped.: 'glib warning', file toolkit/xre/nsSigHandlers.cpp:187
Jul 20 13:24:16 hostname hypridle[3653405]: Hyprlock version v0.9.0
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wl_seat v9
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to wl_seat v9
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wl_data_device_manager v3
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wl_compositor v6
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to wl_compositor v6
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wl_subcompositor v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wl_shm v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to wl_shm v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_viewporter v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to wp_viewporter v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_tearing_control_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_fractional_scale_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to wp_fractional_scale_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zxdg_output_manager_v1 v3
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_cursor_shape_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to wp_cursor_shape_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_idle_inhibit_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_relative_pointer_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zxdg_decoration_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_alpha_modifier_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwlr_gamma_control_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: ext_foreign_toplevel_list_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_pointer_gestures_v1 v3
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwlr_foreign_toplevel_manager_v1 v3
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_keyboard_shortcuts_inhibit_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_text_input_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_text_input_manager_v3 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_pointer_constraints_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwlr_output_power_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: xdg_activation_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: ext_idle_notifier_v1 v2
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: hyprland_lock_notifier_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: ext_session_lock_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to ext_session_lock_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_input_method_manager_v2 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_virtual_keyboard_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwlr_virtual_pointer_manager_v1 v2
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwlr_output_manager_v1 v4
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: org_kde_kwin_server_decoration_manager v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: hyprland_focus_grab_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_tablet_manager_v2 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwlr_layer_shell_v1 v5
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_presentation v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: xdg_wm_base v7
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwlr_data_control_manager_v1 v2
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_primary_selection_device_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: xwayland_shell_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwlr_screencopy_manager_v1 v3
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to zwlr_screencopy_manager_v1 v3
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: hyprland_toplevel_export_manager_v1 v2
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: hyprland_toplevel_mapping_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: hyprland_global_shortcuts_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: xdg_wm_dialog_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_single_pixel_buffer_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_security_context_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: hyprland_ctm_control_manager_v1 v2
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: hyprland_surface_manager_v1 v2
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_content_type_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: xdg_toplevel_tag_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: xdg_system_bell_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: ext_workspace_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_color_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_drm_lease_device_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wp_linux_drm_syncobj_manager_v1 v1
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wl_drm v2
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: zwp_linux_dmabuf_v1 v5
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to zwp_linux_dmabuf_v1 v5
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]   | got iface: wl_output v4
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG]    > Bound to wl_output v4
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] Exposed seat name: Hyprland
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] [core] dmabufFeedbackMainDevice
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] output DP-3 name DP-3
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] output 62 description Dell Inc. DELL S2722DC 38PQGD3 (DP-3)
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] output 62 make Dell Inc. model DELL S2722DC
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] output 62 done
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] Running on Hyprland
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] eglQueryDmaBufModifiersEXT found 6 mods
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] [bo] has 3 plane(s)
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] [bo] chose modifier 10000000000000f
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] Got dma frame with size [Vector2D: x: 2560, y: 1440]
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] Resources gathered after 79 milliseconds
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] Locking session
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] Starting fade in
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] Got fractional scale: 100.0%
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] configure with serial 48188
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] Configuring surface for logical [Vector2D: x: 2560, y: 1440] and pixel [Vector2D: x: 2560, y: 1440]
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] onLockLocked called
Jul 20 13:24:16 hostname kanshi[3652845]: running command 'case "$XDG_CURRENT_DESKTOP" in *Hyprland*) hyprctl keyword '$HGAP' 200;; esac'
Jul 20 13:24:16 hostname kanshi[3652845]: running command 'sleep 1; systemctl --user reload waybar.service'
Jul 20 13:24:16 hostname kanshi[3652845]: configuration for profile 'nomad' applied
Jul 20 13:24:16 hostname hypridle[3653405]: [LOG] [core] dmabu
Jul 20 13:24:16 hostname hypridle[3650530]: [LOG]   | got iface: wl_output v4
Jul 20 13:24:16 hostname kanshi[3653928]: ok
Jul 20 13:24:16 hostname waybar[4156359]: [2025-07-20 13:24:16.779] [warning] module sway/workspaces: Disabling module "sway/workspaces", Socket path is empty
Jul 20 13:24:16 hostname hyprpaper[4155750]: [LOG] configure for eDP-1
Jul 20 13:24:16 hostname hyprpaper[4155750]: [LOG] configure for eDP-1
Jul 20 13:24:16 hostname hyprpaper[4155750]: [LOG] Image data for eDP-1: /home/username/.wallpapers/2024/AuroraPerseids_Anders_4855.jpg at [0.00, -101.31], scale: 0.40 (original image size: [4855, 3237])
Jul 20 13:24:16 hostname hyprpaper[4155750]: [LOG] Submitting viewport dest size 1920x1200 for 7fd7380046d0
Jul 20 13:24:16 hostname hyprpaper[4155750]: [LOG] handlePreferredScale: 1.00 for 7fd7380046d0
Jul 20 13:24:22 hostname hyprlock[3653405]: pam_ecryptfs: seteuid error
Jul 20 13:24:22 hostname hypridle[3650530]: [LOG] Wayland session got unlocked
Jul 20 13:24:22 hostname hypridle[3650530]: [LOG] Inhibited sleep with fd 10
Jul 20 13:24:22 hostname hypridle[3650530]: [LOG] Executing
Jul 20 13:24:22 hostname hypridle[3650530]: [LOG] Process Created with pid 3654849
Jul 20 13:24:22 hostname hypridle[3653405]: fFeedbackMainDevice
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG]   | removed iface 62
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] [core] dmabufFeedbackMainDevice
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG]   | got iface: wl_output v4
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG]    > Bound to wl_output v4
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] [core] dmabufFeedbackMainDevice
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] [core] dmabufFeedbackMainDevice
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] output eDP-1 name eDP-1
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] output 63 description California Institute of Technology 0x1423  (eDP-1)
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] output 63 make California Institute of Technology model 0x1423
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] output 63 done
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] output 63 creating a new lock surface
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] output 63 done
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] Got fractional scale: 100.0%
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] configure with serial 48200
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] Configuring surface for logical [Vector2D: x: 1920, y: 1200] and pixel [Vector2D: x: 1920, y: 1200]
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] Authenticating
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] PAM_PROMPT: Password:
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] auth: authenticated for hyprlock
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] Unlocking session
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] Unlocked, exiting!
Jul 20 13:24:22 hostname hypridle[3653405]: [LOG] Reached the end, exiting

Vladimir-csp avatar Jul 20 '25 10:07 Vladimir-csp

I managed to reproduce it.

https://github.com/user-attachments/assets/f7ba7b48-632b-4cee-b36c-8a1a84ccc975

I confirmed that hyprlock's background widget renders the solid color as soon as it can (frame 0). If one downloads the video and steps through it frame by frame, it seems like it cross fades to the lockdead screen, which is not implemented, so very weird. Then the clock rendered by hyprlock appears before hyprlocks background, although hyprlock renders both of them at frame 0.

Something is wrong for sure. Idk what though.

Just to confirm @Vladimir-csp, do you also get a frame of your previous workspace on eDP-1 like in my video, or is it just 1-2 frames of the lockdead screen?

PointerDilemma avatar Jul 20 '25 13:07 PointerDilemma

Recorded a video and yes, I see a frame(s) of workspace before crash screen.

Vladimir-csp avatar Jul 20 '25 13:07 Vladimir-csp

I also use two backgrounds: screenshot with transparent color fallback (so it is transparent on new monitors) and a backup image under screenshot background.

hyprlock.conf
general {
  #immediate_render = true
}

animations {
  enabled = true
  bezier = linear, 1, 1, 0, 0
  animation = fade, 1, 4, linear
  animation = inputField, 1, 1, linear
}

input-field {
  monitor =
  size = 400, 50
  font_family = Sans
  placeholder_text = $PAMPROMPT
  fail_text = $FAIL <b>($ATTEMPTS)</b>
  fade_on_empty = false
  rounding = 5
  outline_thickness = 2
  inner_color = rgba(181818e0)
  outer_color = rgba(33ccffee) rgba(00ff99ee) 45deg
  font_color = rgba(c0c0c0ee)
  check_color = rgba(ffff33ee) rgba(ffcc33ee) 45deg
  shadow_size = 1
  shadow_passes = 2
}

background {
  # transparent if no screenshot
  color = rgba(60606000)
  noise = 0.05
  contrast = 0.7
  brightness = 0.7
  vibrancy = 0
  vibrancy_darkness = 0
  path = screenshot
  blur_size = 16
  blur_passes = 3
}

# backup background if no screenshot
background {
  color = rgba(606060ff)
  noise = 0.05
  contrast = 0.7
  brightness = 0.7
  vibrancy = 0
  vibrancy_darkness = 0
  path = ~/.wallpapers/2024/AuroraGlacier_woodend_5760.png
  blur_size = 16
  blur_passes = 3
  zindex = -2
}

label {
  text = cmd[update:1000000] echo "$(whoami)@$(hostname -f)"
  font_size = 18
  color = rgba(f0f0f0e0)
  shadow_size = 1
  shadow_passes = 2
  halign = center
  valign = center
  position = 0, 15%
}

label {
  text = <b>$TIME</b>
  font_size = 32
  color = rgba(f0f0f0e0)
  shadow_size = 1
  shadow_passes = 2
  halign = center
  valign = center
  position = 0, 10%
}

label {
  text = cmd[update:30000] upower -i /org/freedesktop/UPower/devices/DisplayDevice | while IFS=':' read -r key value; do case "$key" in *' percentage') printf '🔋%s' ${value};; esac; done
  font_size = 14
  color = rgba(f0f0f0e0)
  shadow_size = 1
  shadow_passes = 2
  halign = center
  valign = center
  position = 0, 5%
}

label {
  text = <b>⌨ $LAYOUT</b>
  font_size = 14
  color = rgba(f0f0f0a0)
  shadow_size = 1
  shadow_passes = 2
  halign = center
  valign = center
  position = 0, -5%
}

Vladimir-csp avatar Jul 20 '25 15:07 Vladimir-csp

Update: External monitor doesn't matter. It's when disabling a monitor, but not disconnecting it. I can reproduce it with monitor disable && hyprlock& sleep 4 && monitor enable on hyprland and sway. But not river or niri. But the client is irrelevant. Happens with swaylock too. I think the swapchain still has a buffer that is rendered when enabling it again or something like that. Although I don't really know. I will ask vaxry about that.

Lockdead showing for a few frames is a separate easily fixable problem though. It should be a black screen (primer we already use). It seams like river manages to do that and it looks natural, because the screen is just turning on. On Niri it flashes red, but no frame of workspaces showing.

PointerDilemma avatar Jul 20 '25 17:07 PointerDilemma

Reopening for tracking, as most people will be looking for a hyprlock issue. It is a compositor bug though.

PointerDilemma avatar Jul 21 '25 11:07 PointerDilemma

I just saw that too, but it's not on a different display. It happened on my main display. It might be related to having more than one displays, I have an external display as well.

logrusx avatar Jul 24 '25 18:07 logrusx

Is there a Hyprland issue/discussion for this?

Vladimir-csp avatar Aug 27 '25 13:08 Vladimir-csp