mini.nvim
mini.nvim copied to clipboard
Mini-completion issues with Ansiblels
Contributing guidelines
- [X] I have read CONTRIBUTING.md
- [X] I have read CODE_OF_CONDUCT.md
- [X] I have updated 'mini.nvim' to latest version
Module(s)
mini.completion
Description
I have found that mini.completion is not allowing me to auto complete module names like "ansible.builtin.*" where star is a string that doesn't start with an "a".
Typing the following yaml file:
- name: Test
ansible.builtin.
I am presented with a very long 100+ list of auto complete options while auto completing the last line, ranging from ansible.builtin.add_host to ansible.builtin.azure_rm_webappslot.
If I try to type "ansible.builtin.dnf" (class I found this problem with), no auto complete options are available.
I found that typing any class name that doesn't start with "a" does not appear (like ansible.builtin.systemd).
Ansible has a large variety of modules available. Is there a limit to the number of items that can appear in auto completion list?
I have verified that I am able to autocomplete modules such as ansible.builtin.dnf and ansible.builtin.systemd using CMP.
-- with ansible.builtin.
-- after adding "d" to string
Neovim version
NVIM v0.10.2 Build type: Release LuaJIT 2.1.1727870382
Steps to reproduce
return {
{
'echasnovski/mini.completion',
event = 'InsertEnter',
version = false,
config = function()
require('mini.completion').setup {
lsp_completion = { source_func = 'omnifunc', auto_setup = false },
window = {
info = { height = 25, width = 80, border = 'single' },
signature = { height = 25, width = 80, border = 'single' },
},
}
end,
},
{
'neovim/nvim-lspconfig',
cmd = { 'LspInfo', 'LspInstall', 'LspStart' },
ft = { 'yaml' },
config = function()
local capabilities = vim.lsp.protocol.make_client_capabilities()
capabilities.textDocument.completion.completionItem.snippetSupport = false
local servers = {
ansiblels = {},
}
for server, config in pairs(servers) do
require('lspconfig')[server].setup(vim.tbl_deep_extend('force', config, {
capabilities = capabilities,
on_attach = function(_, buf)
vim.api.nvim_set_option_value('omnifunc', 'v:lua.MiniCompletion.completefunc_lsp', { buf = buf })
end,
}))
end
end,
},
}
Expected behavior
I should be able to do complete any module in the LSP
Actual behavior
Currently auto completion fails to provide options that do not match modules matching "ansible.builtin.a*"