#1404·eww

[BUG] The defvar don't work in defwindow.

Author: DoubleBobCatCreated Nov 9, 2025Updated Aug 4, 2026
Labelsbug

Checklist before submitting an issue

  • I have searched through the existing closed and open issues for eww and made sure this is not a duplicate
  • I have specifically verified that this bug is not a common user error
  • I am providing as much relevant information as I am able to in this bug report (Minimal config to reproduce the issue for example, if applicable)

Description of the bug

Here are part of my eww.yuck configure

; ----- var -----
;; common
(defvar BAR_HEIGHT "30px")

; ----- windows -----
(defwindow win0 :monitor 0
               :geometry (geometry :x 0 :y 0 :height BAR_HEIGHT :width "100%" :anchor "center top")
               :stacking "fg" 
               :exclusive true
               :focusable false
  (bar0 :monitor "eDP-1")
)

After run eww --restart daemon and eww open win0 It shown this error:

failed to open window `win0`

Caused by:
    Unknown variable BAR_HEIGHT

Reproducing the issue

No response

Expected behaviour

The "BAR_HEIGHT" effective.

Additional context

No response

Platform and environment

eww Version: eww 0.6.0-1 OS: Arch Linux x86_64 Kernel: Linux 6.17.7-arch1-1 Display (BOE0990): 2560x1600 @ 1.33x in 16", 165 Hz [Built-in] WM: Hyprland 0.52.0-1 (Wayland)