Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error thrown on opening simple documents : invalid 'group': 'lspconfig'" #169

Open
jdonaldson opened this issue Feb 14, 2025 · 3 comments
Open

Comments

@jdonaldson
Copy link

jdonaldson commented Feb 14, 2025

I started running into a problem after updating my nvim plugins. I started getting errors like this when I opened qmd files. Here's the output that shows up in the error message.

Error detected while processing BufReadPost Autocommands for "*":
Error executing lua callback: ...rew/Cellar/neovim/0.10.4/share/nvim/runtime/filetype.lua:35: Error executing lua: .
..rew/Cellar/neovim/0.10.4/share/nvim/runtime/filetype.lua:36: BufReadPost Autocommands for "*"..FileType Autocomman
ds for "*"..function <SNR>1_LoadFTPlugin[20]..script /Users/jdonaldson/.local/share/lunarvim/site/pack/lazy/opt/quar
to-nvim/ftplugin/quarto.lua: Vim(runtime):E5113: Error while calling lua chunk: ...unarvim/site/pack/lazy/opt/otter.
nvim/lua/otter/init.lua:196: Invalid 'group': 'lspconfig'
stack traceback:
        [C]: in function 'nvim_get_autocmds'
        ...unarvim/site/pack/lazy/opt/otter.nvim/lua/otter/init.lua:196: in function 'activate'
        ...arvim/site/pack/lazy/opt/quarto-nvim/lua/quarto/init.lua:193: in function 'activate'
        ...arvim/site/pack/lazy/opt/quarto-nvim/ftplugin/quarto.lua:11: in main chunk
        [C]: in function 'nvim_cmd'
        ...rew/Cellar/neovim/0.10.4/share/nvim/runtime/filetype.lua:36: in function <...rew/Cellar/neovim/0.10.4/sha
re/nvim/runtime/filetype.lua:35>
        [C]: in function 'nvim_buf_call'
        ...rew/Cellar/neovim/0.10.4/share/nvim/runtime/filetype.lua:35: in function <...rew/Cellar/neovim/0.10.4/sha
re/nvim/runtime/filetype.lua:10>
stack traceback:
        [C]: in function 'nvim_cmd'
        ...rew/Cellar/neovim/0.10.4/share/nvim/runtime/filetype.lua:36: in function <...rew/Cellar/neovim/0.10.4/sha
re/nvim/runtime/filetype.lua:35>
        [C]: in function 'nvim_buf_call'
        ...rew/Cellar/neovim/0.10.4/share/nvim/runtime/filetype.lua:35: in function <...rew/Cellar/neovim/0.10.4/sha
re/nvim/runtime/filetype.lua:10>
stack traceback:
        [C]: in function 'nvim_buf_call'
        ...rew/Cellar/neovim/0.10.4/share/nvim/runtime/filetype.lua:35: in function <...rew/Cellar/neovim/0.10.4/sha
re/nvim/runtime/filetype.lua:10>

I'm using Lunarvim/Neovim:

:version
NVIM v0.10.4
Build type: Release
LuaJIT 2.1.1736781742
Run ":verbose version" for more info

From what I can gather, it's an otter.nvim issue, but it wasn't immediately obvious to me where the problem was. I'm putting down some extended notes since I don't see anyone else running into the exact same problem. The problem will trigger even on simple qmd documents like this:

---
title: "simple example"
---

I can get it working by inserting a new line right before the frontmatter block:


---
title: "simple example"
---

Here's the relevant library versions I'm on:

    ● quarto-nvim 14.68ms  start
        dir     /Users/jdonaldson/.local/share/lunarvim/site/pack/lazy/opt/quarto-nvim
        url     https://github.com/quarto-dev/quarto-nvim
        version 1.2.1
        tag     v1.2.1
        branch  main
        commit  abc417c
        readme  README.md
        help    |quarto.txt|
    ● otter.nvim 0.11ms  quarto-nvim
        dir     /Users/jdonaldson/.local/share/lunarvim/site/pack/lazy/opt/otter.nvim
        url     https://github.com/jmbuhr/otter.nvim
        version 2.6.1
        tag     stable
        branch  main
        commit  0e42fa7
        readme  README.md
        help    |otter.nvim.txt|
@jdonaldson jdonaldson changed the title Error thrown on opening simple documents : "E5113: Error while calling lua chunk: ...unarvim/site/pack/lazy/opt/otter. nvim/lua/otter/init.lua:196: Invalid 'group': 'lspconfig'" Error thrown on opening simple documents : invalid 'group': 'lspconfig'" Feb 14, 2025
@jmbuhr
Copy link
Collaborator

jmbuhr commented Feb 15, 2025

See the set_filetype option in https://github.com/jmbuhr/otter.nvim?tab=readme-ov-file#configure-otter
(I actually want to turn this exact error into a more informative note).

@jdonaldson
Copy link
Author

I can confirm setting the set_filetype = false works for me, thanks!

I'll leave the issue open unless you already have a TODO for adding the note.

@jmbuhr
Copy link
Collaborator

jmbuhr commented Feb 16, 2025

I'm also considering to change the default to setting the filetype.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants