Wezterm Palette throwing "nerdfont not found in NERD_FONTS" error on valid nerdfont
What Operating System(s) are you seeing this problem on?
Linux X11, Linux Wayland
Which Wayland compositor or X11 Window manager(s) are you using?
No response
WezTerm version
20241007-103714-ed430415
Did you try the latest nightly build to see if the issue is better (or worse!) than your current version?
Yes, and I updated the version box above to show the version of the nightly that I tried
Describe the bug
When populating the command palette, setting the icon to a valid nerd font (as listed in the documentation) will throw an error when the command palette is opened.
I have tried this when opening wezterm from another terminal emulator (alacritty) as well as opening wezterm from within wezterm to verify the font is indeed available within wezterm.
I was following the documentation found here for trying to add a colorscheme to the command palette for selection later. An aside, is there documentation on what a command-palette entry should contain?
To Reproduce
Open wezterm with the provided config, open the command palette (with CTRL+SHIFT+P ), observe error
Configuration
local wezterm = require("wezterm")
local config = wezterm.config_builder()
wezterm.on('augment-command-palette', function(window, pane)
return {
{
brief = "Set Theme ZenWritten Light",
icon = wezterm.nerdfonts.fae_palette_color,
action = wezterm.action_callback(function(window, pane, line)
if line then
window:set_config_overrides({
color_scheme = "zenwritten_light"
})
end
end)
}
}
end)
return config
Expected Behavior
If a font is provided by wezterm, wezterm should not complain about it not being found.
Logs
23:38:43.489 ERROR wezterm_gui::termwindow::palette > nerdfont not found in NERD_FONTS
Anything else?
Screenshot showing the error occurring both from opening wezterm in alacritty as well as wezterm itself
Is there anything else I can provide for this? Its not the world's biggest issue but I would like to know if I am doing something wrong or if its reproducible by anyone else
I recently updated the bundled nerd font symbols and regenerated the symbol map; perhaps that has resolved this now? Can you try the most recently nightly?
This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take action. Please reach out if you have or find the answers we need so that we can investigate further.
Running commit fd532a8c2fb3b56593597cf8be1775da1feda0a3, I am still seeing this issue (with the above provided configuration)
I apologize for the delay, this got lost in the sauce
Ah, this is a usage error; you want this:
- icon = wezterm.nerdfonts.fae_palette_color,
+ icon = 'fae_palette_color',
Yup that does it. I suppose it makes sense. To make sure its clear, icon expects not the actual icon but the name of the icon?
yeah, it wants the name of the icon; you can see that in the example in https://wezterm.org/config/lua/window-events/augment-command-palette.html
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.