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

"undefined variable: json" after luasnip upgrade to current master #1290

Open
torstello opened this issue Jan 25, 2025 · 0 comments
Open

"undefined variable: json" after luasnip upgrade to current master #1290

torstello opened this issue Jan 25, 2025 · 0 comments

Comments

@torstello
Copy link

after upgrading the plugin with lazy, it get this error when calling snippets that contain a placeholder:

~/.local/share/nvim/lazy/LuaSnip/lua/luasnip/util/functions.lua:39: nvim_exec2(): Vim(echo):E121: Undefined variable: json

Version:
branch master
commit 98d9cb5

my plugin configuration:

return {
      {
        "L3MON4D3/LuaSnip",
        build = vim.fn.has "win32" ~= 0 and "make install_jsregexp" or nil,
        dependencies = {
          "rafamadriz/friendly-snippets",
          "benfowler/telescope-luasnip.nvim",
          "molleweide/LuaSnip-snippets.nvim",
        },
        config = function(_, opts)
          if opts then require("luasnip").config.setup(opts) end
          vim.tbl_map(
            function(type) require("luasnip.loaders.from_" .. type).lazy_load() end,
            { "vscode", "snipmate" }
          )

          require("luasnip.loaders.from_vscode").lazy_load({ paths = { "./snippets" } })

          require("luasnip").filetype_extend("go", { "godoc" })
          require("luasnip").filetype_extend("lua", { "luadoc" })
          require("luasnip").filetype_extend("python", { "pydoc" })
          require("luasnip").filetype_extend("sh", { "shelldoc" })
        end,
      },
}

any help is very much appreciated.

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

1 participant