[GH-ISSUE #986] Does not launch on Croissant compositor #8735

Closed
opened 2026-05-23 03:54:03 +01:00 by JakeStanger · 4 comments
Owner

Originally created by @kode54 on GitHub (May 17, 2025).
Original GitHub issue: https://github.com/JakeStanger/ironbar/issues/986

Describe the bug
The bar does not launch and fails due to a compositor disconnect on croissant. The developer has already debugged a similar issue with waybar months ago, but apparently still affects both sfwbar and ironbar. Developer says the waybar issue was that the client app was expecting the compositor to instantly roundtrip straight from surface creation to sending the configure event, which the client app will then expect to instantly roundtrip directly to creating and assigning a buffer to the surface.

To reproduce
Steps to reproduce the behavior:

  1. Build and install latest ironbar-git
  2. Build and install croissant from Git
  3. Attempt to start ironbar from a croissant session
  4. ironbar will die due to compositor closing its socket due to protocol error

Expected behavior
ironbar should wait until it receives a configure request before configuring surfaces, and should wait until this is accepted before allocating and assigning a buffer. If it already does this, then I am being BSed by the compositor author.

System information:

  • Distro: Arch Linux
  • Compositor: croissant (for the sake of this test; no other compositor appears to have this requirement)
  • Ironbar version: 0.16.1.r283.gf3ae57b-1

Configuration
The default config.corn from the listed version, with no changes.

Config
let {
    $workspaces = {
        type = "workspaces"
        all_monitors = false
        name_map = {
            1 = "󰙯"
            2 = "icon:firefox"
            3 = ""
            Games = "icon:steam"
            Code = ""
        }
    }

    $focused = { type = "focused" }

    $launcher = {
        type = "launcher"
        favorites = ["firefox" "discord" "steam"]
        show_names = false
        show_icons = true
    }

    $mpris = {
        type = "music"
        player_type = "mpris"

        on_click_middle = "playerctl play-pause"
        on_scroll_up = "playerctl volume +5"
        on_scroll_down = "playerctl volume -5"

    }

    $mpd_local = { type = "music" player_type = "mpd" music_dir = "/home/jake/Music" truncate.mode = "end" truncate.max_length = 100 }
    $mpd_server = { type = "music" player_type = "mpd" host = "chloe:6600" truncate = "end" }

    $notifications = {
        type = "notifications"
        show_count = true

        icons.closed_none = "󰍥"
        icons.closed_some = "󱥂"
        icons.closed_dnd = "󱅯"
        icons.open_none = "󰍡"
        icons.open_some = "󱥁"
        icons.open_dnd = "󱅮"
    }

    $sys_info = {
        type = "sys_info"

        interval.memory = 30
        interval.cpu = 1
        interval.temps = 5
        interval.disks = 300
        interval.networks = 3

        format = [
        " {cpu_percent}% | {cpu_frequency} GHz | {temp_c@CPUTIN}°C"
        " {memory_used} / {memory_total} GB ({memory_available} | {memory_percent2}%) | {swap_used} / {swap_total} GB ({swap_free} | {swap_percent}%)"
        "󰋊 {disk_used#T@/:.1} / {disk_total#T@/:.1} TB ({disk_percent@/}%) | {disk_read} / {disk_write} MB/s"
        "󰓢 {net_down@enp39s0} / {net_up@enp39s0} Mbps"
        "󰖡 {load_average1} | {load_average5} | {load_average15}"
        "󰥔 {uptime}"
        ]
    }

    $tray = { type = "tray" }

    $clock = { type = "clock" }

    $phone_battery = {
        type = "script"
        cmd = "/home/jake/bin/phone-battery"

        show_if.cmd = "/home/jake/bin/phone-connected"
        show_if.interval = 500
    }

    $clipboard = { type = "clipboard" max_items = 3 truncate.mode = "end" truncate.length = 50 }

    $volume = {
        type = "volume"
        format = "{icon} {percentage}%"
        max_volume = 100
        icons.volume_high = "󰕾"
        icons.volume_medium = "󰖀"
        icons.volume_low = "󰕿"
        icons.muted = "󰝟"
    }

    $label = { type = "label" label = "random num: {{500:echo FIXME}}" }

    // -- begin custom --
    $button = { type = "button" name="power-btn" label = "" on_click = "popup:toggle" }

    $popup = {
        type = "box"
        orientation = "vertical"
        widgets = [
            { type = "label" name = "header" label = "Power menu" }
            {
                type = "box"
                widgets = [
                    { type = "button" class="power-btn" label = "<span font-size='40pt'></span>" on_click = "!shutdown now" }
                    { type = "button" class="power-btn" label = "<span font-size='40pt'></span>" on_click = "!reboot" }
                ]
            }
            { type = "label" name = "uptime" label = "Uptime: {{30000:uptime -p | cut -d ' ' -f2-}}" }
        ]
    }

    $power_menu = {
        type = "custom"
        class = "power-menu"

        bar = [ $button ]
        popup = [ $popup ]

        tooltip = "Up: {{30000:uptime -p | cut -d ' ' -f2-}}"
    }
    // -- end custom --

    $left = [ $workspaces $launcher $label ]
    $right = [ $mpd_local $mpd_server $phone_battery $sys_info $volume $clipboard $power_menu $clock $notifications ]
}
in {
    anchor_to_edges = true
    position = "bottom"
    icon_theme = "Paper"

    start = $left
    end = $right
}
Styles

Additional context

Screenshots

Originally created by @kode54 on GitHub (May 17, 2025). Original GitHub issue: https://github.com/JakeStanger/ironbar/issues/986 **Describe the bug** The bar does not launch and fails due to a compositor disconnect on [croissant](https://codeberg.org/vyivel/croissant). The developer has already debugged a similar issue with waybar months ago, but apparently still affects both sfwbar and ironbar. Developer says the waybar issue was that the client app was expecting the compositor to instantly roundtrip straight from surface creation to sending the configure event, which the client app will then expect to instantly roundtrip directly to creating and assigning a buffer to the surface. **To reproduce** Steps to reproduce the behavior: 1. Build and install latest ironbar-git 2. Build and install croissant from Git 3. Attempt to start ironbar from a croissant session 4. ironbar will die due to compositor closing its socket due to protocol error **Expected behavior** ironbar should wait until it receives a configure request before configuring surfaces, and should wait until this is accepted before allocating and assigning a buffer. If it already does this, then I am being BSed by the compositor author. **System information:** - Distro: Arch Linux - Compositor: croissant (for the sake of this test; no other compositor appears to have this requirement) - Ironbar version: 0.16.1.r283.gf3ae57b-1 **Configuration** The default config.corn from the listed version, with no changes. <details><summary>Config</summary> ``` let { $workspaces = { type = "workspaces" all_monitors = false name_map = { 1 = "󰙯" 2 = "icon:firefox" 3 = "" Games = "icon:steam" Code = "" } } $focused = { type = "focused" } $launcher = { type = "launcher" favorites = ["firefox" "discord" "steam"] show_names = false show_icons = true } $mpris = { type = "music" player_type = "mpris" on_click_middle = "playerctl play-pause" on_scroll_up = "playerctl volume +5" on_scroll_down = "playerctl volume -5" } $mpd_local = { type = "music" player_type = "mpd" music_dir = "/home/jake/Music" truncate.mode = "end" truncate.max_length = 100 } $mpd_server = { type = "music" player_type = "mpd" host = "chloe:6600" truncate = "end" } $notifications = { type = "notifications" show_count = true icons.closed_none = "󰍥" icons.closed_some = "󱥂" icons.closed_dnd = "󱅯" icons.open_none = "󰍡" icons.open_some = "󱥁" icons.open_dnd = "󱅮" } $sys_info = { type = "sys_info" interval.memory = 30 interval.cpu = 1 interval.temps = 5 interval.disks = 300 interval.networks = 3 format = [ " {cpu_percent}% | {cpu_frequency} GHz | {temp_c@CPUTIN}°C" " {memory_used} / {memory_total} GB ({memory_available} | {memory_percent2}%) | {swap_used} / {swap_total} GB ({swap_free} | {swap_percent}%)" "󰋊 {disk_used#T@/:.1} / {disk_total#T@/:.1} TB ({disk_percent@/}%) | {disk_read} / {disk_write} MB/s" "󰓢 {net_down@enp39s0} / {net_up@enp39s0} Mbps" "󰖡 {load_average1} | {load_average5} | {load_average15}" "󰥔 {uptime}" ] } $tray = { type = "tray" } $clock = { type = "clock" } $phone_battery = { type = "script" cmd = "/home/jake/bin/phone-battery" show_if.cmd = "/home/jake/bin/phone-connected" show_if.interval = 500 } $clipboard = { type = "clipboard" max_items = 3 truncate.mode = "end" truncate.length = 50 } $volume = { type = "volume" format = "{icon} {percentage}%" max_volume = 100 icons.volume_high = "󰕾" icons.volume_medium = "󰖀" icons.volume_low = "󰕿" icons.muted = "󰝟" } $label = { type = "label" label = "random num: {{500:echo FIXME}}" } // -- begin custom -- $button = { type = "button" name="power-btn" label = "" on_click = "popup:toggle" } $popup = { type = "box" orientation = "vertical" widgets = [ { type = "label" name = "header" label = "Power menu" } { type = "box" widgets = [ { type = "button" class="power-btn" label = "<span font-size='40pt'></span>" on_click = "!shutdown now" } { type = "button" class="power-btn" label = "<span font-size='40pt'></span>" on_click = "!reboot" } ] } { type = "label" name = "uptime" label = "Uptime: {{30000:uptime -p | cut -d ' ' -f2-}}" } ] } $power_menu = { type = "custom" class = "power-menu" bar = [ $button ] popup = [ $popup ] tooltip = "Up: {{30000:uptime -p | cut -d ' ' -f2-}}" } // -- end custom -- $left = [ $workspaces $launcher $label ] $right = [ $mpd_local $mpd_server $phone_battery $sys_info $volume $clipboard $power_menu $clock $notifications ] } in { anchor_to_edges = true position = "bottom" icon_theme = "Paper" start = $left end = $right } ``` </details> <details><summary>Styles</summary> ```css ``` </details> **Additional context** <!-- Add any other context about the problem here. --> **Screenshots** <!-- If applicable, add screenshots to help explain your problem. -->
JakeStanger 2026-05-23 03:54:03 +01:00
  • closed this issue
  • added the
    T:Bug
    label
Author
Owner

@kode54 commented on GitHub (May 18, 2025):

I must apologize, since the dev of croissant only thought it may be the same issue. And they just said it works for them. So something is clearly wrong in my desktop setup to make it not work, and it's PEBKAC or something. Sorry again. :/

<!-- gh-comment-id:2888804774 --> @kode54 commented on GitHub (May 18, 2025): I must apologize, since the dev of croissant only thought it *may* be the same issue. And they just said it works for them. So something is clearly wrong in my desktop setup to make it not work, and it's PEBKAC or something. Sorry again. :/
Author
Owner

@kode54 commented on GitHub (May 19, 2025):

Okay, it seems it may be an issue with gtk-layer-shell, and it only affects systems with two or more displays. Awaiting further information from anyone looking into it.

The sfwbar developer attempted a workaround using _roundtrip, which livelocks when opening the popup menus created by the bar. Changing it to a _dispatch() call fixes the CPU usage, but it still hangs on popup creation.

I need to test how ironbar reacts to that.

<!-- gh-comment-id:2892491502 --> @kode54 commented on GitHub (May 19, 2025): Okay, it seems it may be an issue with gtk-layer-shell, and it only affects systems with two or more displays. Awaiting further information from anyone looking into it. The sfwbar developer attempted a workaround using _roundtrip, which livelocks when opening the popup menus created by the bar. Changing it to a _dispatch() call fixes the CPU usage, but it still hangs on popup creation. I need to test how ironbar reacts to that.
Author
Owner

@JakeStanger commented on GitHub (May 20, 2025):

This is almost certainly an issue with spec compliancy within the compositor.

The Wayland code is abstracted behind the wayland_client and calloop crates, and does not deal with any of the bar rendering (gtk3 and gtk-layer-shell crates do all of that) so there's very litle I can do here. I'm also unwilling to make changes that core to the bar for the sake of one compositor when it works without issue on others.

github.com/JakeStanger/ironbar@60b42c4d94/src/clients/wayland/mod.rs (L254-L256)

<!-- gh-comment-id:2893444466 --> @JakeStanger commented on GitHub (May 20, 2025): This is almost certainly an issue with spec compliancy within the compositor. The Wayland code is abstracted behind the `wayland_client` and `calloop` crates, and does not deal with any of the bar rendering (gtk3 and gtk-layer-shell crates do all of that) so there's very litle I can do here. I'm also unwilling to make changes that core to the bar for the sake of one compositor when it works without issue on others. https://github.com/JakeStanger/ironbar/blob/60b42c4d94139cacfbf219ad212dad952926d560/src/clients/wayland/mod.rs#L254-L256
Author
Owner

@kode54 commented on GitHub (May 22, 2025):

The bug affected other bar apps using gtk-layer-shell as well. A fix has been tagged in the 0.9.2 release of gtk-layer-shell, including the popup lock up issue that I found in the initial fix.

<!-- gh-comment-id:2900220846 --> @kode54 commented on GitHub (May 22, 2025): The bug affected other bar apps using gtk-layer-shell as well. A fix has been tagged in the 0.9.2 release of gtk-layer-shell, including the popup lock up issue that I found in the initial fix.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
JakeStanger/ironbar#8735
No description provided.