bug: Html tags visible using hover with ansible-language-server
dadav opened this issue · comments
Daniel commented
Did you check docs and existing issues?
- I have read all the noice.nvim docs
- I have searched the existing issues of noice.nvim
- I have searched the existing issues of plugins related to this issue
Neovim version (nvim -v)
NVIM v0.9.5
Operating system/version
Archlinux
Describe the bug
The html tags are not interpreted but literally printed in the hover popup.
Steps To Reproduce
- Add the following config:
{
-- Install additional tools
{
"williamboman/mason.nvim",
opts = function(_, opts)
vim.list_extend(opts.ensure_installed, {
"ansible-language-server",
"ansible-lint",
})
end,
},
{
"neovim/nvim-lspconfig",
opts = {
servers = {
ansiblels = {},
},
},
},
}
- Open this file:
---
# vim: set ft=yaml.ansible :
- name: Test
tasks:
- ansible.builtin.get_url:
- Open hover on
get_url
Expected Behavior
Not seeing any html tags in the hover popup.
Repro
local root = vim.fn.fnamemodify("./.repro", ":p")
-- set stdpaths to use .repro
for _, name in ipairs({ "config", "data", "state", "cache" }) do
vim.env[("XDG_%s_HOME"):format(name:upper())] = root .. "/" .. name
end
-- bootstrap lazy
local lazypath = root .. "/plugins/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
vim.fn.system({
"git",
"clone",
"--filter=blob:none",
"--single-branch",
"https://github.com/folke/lazy.nvim.git",
lazypath,
})
end
vim.opt.runtimepath:prepend(lazypath)
-- install plugins
local plugins = {
"folke/tokyonight.nvim",
{
"folke/noice.nvim",
dependencies = {
"MunifTanjim/nui.nvim",
"rcarriga/nvim-notify",
},
},
"williamboman/mason.nvim",
"williamboman/mason-lspconfig.nvim",
"neovim/nvim-lspconfig",
}
require("lazy").setup(plugins, {
root = root .. "/plugins",
})
-- add anything else here
vim.opt.termguicolors = true
vim.cmd([[colorscheme tokyonight]])
require("noice").setup()
require("mason").setup()
require("mason-lspconfig").setup({
ensure_installed = { "ansiblels" },
})
require("lspconfig").ansiblels.setup({})
vim.keymap.set("n", "<space>", vim.lsp.buf.hover)
Daniel commented
LspLog:
[DEBUG][2024-02-06 20:00:47] .../vim/lsp/rpc.lua:387 "rpc.receive" { id = 4, jsonrpc = "2.0", result = { contents = { kind = "markdown", value = "*Manages apt\\-packages*\n\n**Description**\n\n- Manages <em>apt</em> packages \\(such as for Debian/Ubuntu\\)\\.\n\n**Requirements**\n\n- python\\-apt \\(python 2\\)\n- python3\\-apt \\(python 3\\)\n- aptitude \\(before 2\\.4\\)\n\n**Notes**\n\n- Three of the upgrade modes \\(<code>full</code>\\, <code>safe</code> and its alias <code>true</code>\\) required <code>aptitude</code> up to 2\\.3\\, since 2\\.4 <code>apt\\-get</code> is used as a fall\\-back\\.\n- In most cases\\, packages installed with apt will start newly installed services by default\\. Most distributions have mechanisms to avoid this\\. For example when installing Postgresql\\-9\\.5 in Debian 9\\, creating an excutable shell script \\(/usr/sbin/policy\\-rc\\.d\\) that throws a return code of 101 will stop Postgresql 9\\.5 starting up after install\\. Remove the file or remove its execute permission afterwards\\.\n- The apt\\-get commandline supports implicit regex matches here but we do not because it can let typos through easier \\(If you typo <code>foo</code> as <code>fo</code> apt\\-get would install packages that have \\\"fo\\\" in their name with a warning and a prompt for the user\\. Since we don\\'t have warnings and prompts before installing we disallow this\\.Use an explicit fnmatch pattern if you want wildcarding\\)\n- When used with a <code>loop\\:</code> each package will be processed individually\\, it is much more efficient to pass the list directly to the <code><strong>name</strong></code> option\\.\n- When <code><strong>default\\_release</strong></code> is used\\, an implicit priority of 990 is used\\. This is the same behavior as <code>apt\\-get \\-t</code>\\.\n- When an exact version is specified\\, an implicit priority of 1001 is used\\." }, range = { ["end"] = { character = 25, line = 3 }, start = { character = 6, line = 3 } } }}
Albert24GG commented