Skip to content

Errors when using notebook.nvim with lunarvim #7

@miwojc

Description

@miwojc

Description

i have added the plugin to ~/.config/lvim/config.lua:

lvim.plugins = {
  {
    "meatballs/notebook.nvim",
    config = function()
      require("notebook")
    end
  },
}

I run :PackerUpdate to update plugins with success.

When i try to open an existing notebook

lvim jupyter_workflow.ipynb

i get the following error:

Error detected while processing BufReadPost Autocommands for "*.ipynb":
Error executing lua callback: ...im/site/pack/packer/start/notebook.nvim/lua/notebook.lua:41: attempt to index field 'language_info' (a nil value)
stack traceback:
        ...im/site/pack/packer/start/notebook.nvim/lua/notebook.lua:41: in function <...im/site/pack/packer/start/notebook.nvim/lua/notebook.lua:24>
Press ENTER or type command to continue

The notebook opens in lunarvim as json:
image

NBAddCell

:NBAddCell generates the bellow error:

Select cell type:
1: code
2: markdown
3: raw
Type number and <Enter> or click with the mouse (q or empty cancels): 1Error executing Lua callback: ...ack/packer/start/notebook.nvim/lua/notebook/command
s.lua:12: Key not found: notebook.settings
stack traceback:
        [C]: in function 'nvim_buf_get_var'
        ...ack/packer/start/notebook.nvim/lua/notebook/commands.lua:12: in function 'add_cell'
        ...ack/packer/start/notebook.nvim/lua/notebook/commands.lua:27: in function 'on_choice'
        ...al/Cellar/neovim/0.8.3/share/nvim/runtime/lua/vim/ui.lua:54: in function 'select'
        ...ack/packer/start/notebook.nvim/lua/notebook/commands.lua:23: in function 'set_cell_type'
        ...ack/packer/start/notebook.nvim/lua/notebook/commands.lua:38: in function <...ack/packer/start/notebook.nvim/lua/notebook/commands.lua:32>
Press ENTER or type command to continue

Details:

lvim version: release-1-2/neovim-0.8-8f4a7bde

lvim --version
NVIM v0.8.3
Build type: Release
LuaJIT 2.1.0-beta3
Compiled by brew@Ventura

Features: +acl +iconv +tui
See ":help feature-compile"

system vimrc file: "$VIM/sysinit.vim"
fall-back for $VIM: "/usr/local/Cellar/neovim/0.8.3/share/nvim"

:checkhealth details
man: require("man.health").check()

  • OK: plugin/man.vim not in $VIMRUNTIME
  • OK: autoload/man.vim not in $VIMRUNTIME

mason: require("mason.health").check()

mason.nvim report

  • OK: neovim version >= 0.7.0
  • OK: Go: go version go1.19.2 darwin/amd64
  • OK: cargo: cargo 1.67.0 (8ecd4f20a 2023-01-10)
  • WARNING: luarocks: not available
  • OK: Ruby: ruby 2.6.10p210 (2022-04-12 revision 67958) [universal.x86_64-darwin22]
  • OK: RubyGem: 3.0.3.1
  • WARNING: Composer: not available
  • WARNING: PHP: not available
  • OK: npm: 8.15.0
  • OK: node: v16.17.0
  • OK: python3: Python 3.10.8
  • OK: pip3: pip 21.3.1 from /Users/mwojczulis/mambaforge/lib/python3.10/site-packages/pip (python 3.10)
  • WARNING: javac: not available
  • OK: java: java version "1.8.0_351"
  • WARNING: julia: not available
  • OK: wget: GNU Wget 1.21.3 built on darwin22.1.0.
  • OK: curl: curl 7.84.0 (x86_64-apple-darwin22.0) libcurl/7.84.0 (SecureTransport) LibreSSL/3.3.6 zlib/1.2.11 nghttp2/1.47.0
  • OK: gzip: Apple gzip 400
  • OK: tar: bsdtar 3.5.3 - libarchive 3.5.3 zlib/1.2.11 liblzma/5.0.5 bz2lib/1.0.8
  • OK: bash: GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin22)
  • OK: sh: Ok
  • OK: GitHub API rate limit. Used: 0. Remaining: 5000. Limit: 5000. Reset: Sun Mar 26 19:41:42 2023.

null-ls: require("null-ls.health").check()

  • INFO: no sources registered

nvim: health#nvim#check

Configuration

  • WARNING: Missing user config file: /Users/mwojczulis/.config/nvim/init.vim
    • ADVICE:
      • :help |init.vim|

Performance

  • OK: Build type: Release

Remote Plugins

  • OK: Up to date

terminal

  • INFO: key_backspace (kbs) terminfo entry: key_backspace=^H
  • INFO: key_dc (kdch1) terminfo entry: key_dc=\E[3~
  • INFO: $TERM_PROGRAM='WarpTerminal'
  • INFO: $COLORTERM='truecolor'

nvim-treesitter: require("nvim-treesitter.health").check()

Installation

  • OK: tree-sitter found 0.20.7 (b268e412ad4848380166af153300464e5a1cf83f) (parser generator, only needed for :TSInstallFromGrammar)
  • OK: node found v16.17.0 (only needed for :TSInstallFromGrammar)
  • OK: git executable found.
  • OK: cc executable found. Selected from { vim.NIL, "cc", "gcc", "clang", "cl", "zig" }
    Version: Apple clang version 14.0.0 (clang-1400.0.29.202)
  • OK: Neovim was compiled with tree-sitter runtime ABI version 14 (required >=13). Parsers must be compatible with runtime ABI.

Parser/Features H L F I J

  • typescript ✓ ✓ ✓ ✓ ✓
  • help ✓ . . . x
  • java ✓ ✓ . ✓ ✓
  • bash ✓ ✓ ✓ . ✓
  • json ✓ ✓ ✓ ✓ .
  • c ✓ ✓ ✓ ✓ ✓
  • python ✓ ✓ ✓ ✓ ✓
  • lua ✓ ✓ ✓ ✓ ✓
  • rust ✓ ✓ ✓ ✓ ✓
  • javascript ✓ ✓ ✓ ✓ ✓
  • css ✓ . ✓ ✓ ✓
  • yaml ✓ ✓ ✓ ✓ ✓
  • tsx ✓ ✓ ✓ ✓ ✓
  • vim ✓ ✓ ✓ . ✓

Legend: H[ighlight], L[ocals], F[olds], I[ndents], In[j]ections
+) multiple parsers found, only one will be used
x) errors found in the query, try to run :TSUpdate {lang}

The following errors have been detected:

  • ERROR: help(injections): ...im/0.8.3/share/nvim/runtime/lua/vim/treesitter/query.lua:219: query: invalid node type at position 14 for language help
    help(injections) is concatenated from the following files:
    | [ERROR]:"/usr/local/Cellar/neovim/0.8.3/share/nvim/runtime/queries/help/injections.scm", failed to load: ...im/0.8.3/share/nvim/runtime/lua/vim/treesitter/query.lua:219: query: invalid node type at position 14 for language help

provider: health#provider#check

Clipboard (optional)

  • OK: Clipboard tool found: pbcopy

Python 3 provider (optional)

  • INFO: g:python3_host_prog is not set. Searching for python3 in the environment.
  • INFO: Multiple python3 executables found. Set g:python3_host_prog to avoid surprises.
  • INFO: Executable: /Users/mwojczulis/mambaforge/bin/python3
  • INFO: Other python executable: /usr/local/bin/python3
  • INFO: Other python executable: /usr/bin/python3
  • INFO: Python version: 3.10.8
  • INFO: pynvim version: 0.4.3
  • OK: Latest pynvim is installed.

Python virtualenv

  • OK: no $VIRTUAL_ENV

Ruby provider (optional)

  • INFO: Ruby: ruby 2.6.10p210 (2022-04-12 revision 67958) [universal.x86_64-darwin22]
  • WARNING: neovim-ruby-host not found.
    • ADVICE:
      • Run gem install neovim to ensure the neovim RubyGem is installed.
      • Run gem environment to ensure the gem bin directory is in $PATH.
      • If you are using rvm/rbenv/chruby, try "rehashing".
      • See :help |g:ruby_host_prog| for non-standard gem installations.
      • You may disable this provider (and warning) by adding let g:loaded_ruby_provider = 0 to your init.vim

Node.js provider (optional)

  • INFO: Node.js: v16.17.0
  • INFO: Nvim node.js host: /Users/mwojczulis/.config/yarn/global//node_modules/neovim/bin/cli.js
  • OK: Latest "neovim" npm/yarn/pnpm package is installed: 4.10.1

Perl provider (optional)

  • WARNING: "Neovim::Ext" cpan module is not installed
    • ADVICE:
      • See :help |provider-perl| for more information.
      • You may disable this provider (and warning) by adding let g:loaded_perl_provider = 0 to your init.vim

telescope: require("telescope.health").check()

Checking for required plugins

  • OK: plenary installed.
  • OK: nvim-treesitter installed.

Checking external dependencies

  • OK: rg: found ripgrep 13.0.0
  • WARNING: fd: not found. Install sharkdp/fd for extended capabilities

===== Installed extensions =====

Telescope Extension: fzf

  • INFO: No healthcheck provided

Telescope Extension: projects

  • INFO: No healthcheck provided

vim.lsp: require("vim.lsp.health").check()

  • INFO: LSP log level : WARN
  • INFO: Log path: /Users/mwojczulis/.local/state/nvim/lsp.log
  • INFO: Log size: 754 KB

vim.treesitter: require("vim.treesitter.health").check()

  • INFO: Runtime ABI version : 14
  • OK: Loaded parser for bash: ABI version 14
  • OK: Loaded parser for c: ABI version 13
  • OK: Loaded parser for css: ABI version 13
  • OK: Loaded parser for help: ABI version 14
  • OK: Loaded parser for java: ABI version 13
  • OK: Loaded parser for javascript: ABI version 13
  • OK: Loaded parser for json: ABI version 13
  • OK: Loaded parser for lua: ABI version 13
  • OK: Loaded parser for python: ABI version 14
  • OK: Loaded parser for rust: ABI version 14
  • OK: Loaded parser for tsx: ABI version 13
  • OK: Loaded parser for typescript: ABI version 14
  • OK: Loaded parser for vim: ABI version 14
  • OK: Loaded parser for yaml: ABI version 13
  • OK: Loaded parser for c: ABI version 13
  • OK: Loaded parser for help: ABI version 14
  • OK: Loaded parser for lua: ABI version 13
  • OK: Loaded parser for vim: ABI version 14

which_key: health#which_key#check

WhichKey: checking conflicting keymaps

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions