svrana / neosolarized.nvim

Truecolor solarized theme for neovim in Lua using colorbuddy
Other
158 stars 35 forks source link

E5105 Error while calling LUA chunk #15

Open illegitimate-egg opened 1 year ago

illegitimate-egg commented 1 year ago

I don't know anything about LUA so I can't begin to debug this. When starting nvim I'm left with the error below and no solarized theme.

Error detected while processing /home/ubuntu/.config/nvim/init.vim:
line   13:
E5105: Error while calling lua chunk: ...nvim/site/plugged/neosolarized.nvim/lua/neosolarized.lua:36: attempt to call up
value 'cmd' (a nil value)
Press ENTER or type command to continue

Don't worry this is WSL running Ubuntu 20.04, I don't have brain damage

svrana commented 1 year ago

Hmm, that's odd. cmd is a reference to vim.cmd which should always exist. Certainly has existed as long as this plugin has been around, which is about neovim .6. What version are you using?

illegitimate-egg commented 1 year ago

ah, 0.4.3

illegitimate-egg commented 1 year ago

Apt moment

svrana commented 1 year ago

Do you have colorbuddy installed?

Also make sure you have colorbuddy installed, if you haven't already: https://github.com/tjdevries/colorbuddy.nvim

illegitimate-egg commented 1 year ago

Yes

illegitimate-egg commented 1 year ago

The neovim version is way to low

illegitimate-egg commented 1 year ago

updating it now

svrana commented 1 year ago

Awesome, latest version .8.x, get as close as you can!

illegitimate-egg commented 1 year ago

I got v0.8.1 installed and now I have a different error!

Error detected while processing /home/ubuntu/.config/nvim/init.vim:
line   13:
E5108: Error executing lua ...nvim/site/plugged/neosolarized.nvim/lua/neosolarized.lua:36: Vim(packadd):E919: Directory not found in 'packpath': "pack/*/opt/colorbuddy.nvim"
stack traceback:
        [C]: in function 'cmd'
        ...nvim/site/plugged/neosolarized.nvim/lua/neosolarized.lua:36: in function 'setup'
        [string ":lua"]:1: in main chunk
Press ENTER or type command to continue
svrana commented 1 year ago

It's failing trying to load colorbuddy. Not sure how you install packages, but a help packpath will describe how neovim will attempt to find them.

illegitimate-egg commented 1 year ago

For packages I use vimplug, and your package installed completely normally

svrana commented 1 year ago

Do you see a path containing colorbuddy when you run :echo &rtp?

illegitimate-egg commented 1 year ago

yep

/home/ubuntu/.config/nvim,/home/ubuntu/.local/share/nvim/site/plugged/colorbuddy.nvim,/home/ubuntu/.local/share/nvim/site/plugged/neosolarized.nvim,/etc/xdg/nvim,/home/ubuntu/.local/share/
nvim/site,/usr/local/share/nvim/site,/usr/share/nvim/site,/var/lib/snapd/desktop/nvim/site,/tm
p/.mount_nvim8rnqIF/usr/share/nvim/runtime,/tmp/.mount_nvim8rnqIF/usr/share/nvim/runtime/pack/
dist/opt/matchit,/tmp/.mount_nvim8rnqIF/usr/lib/nvim,/var/lib/snapd/desktop/nvim/site/after,/u
sr/share/nvim/site/after,/usr/local/share/nvim/site/after,/home/ubuntu/.local/share/nvim/site/
after,/etc/xdg/nvim/after,/home/ubuntu/.config/nvim/after
svrana commented 1 year ago

sorry, :echo &packpath

illegitimate-egg commented 1 year ago

Nope, don't see colour buddy in that one

/home/ubuntu/.config/nvim,/etc/xdg/nvim,/home/ubuntu/.local/share/nvim/site,/usr/local/share/nvim/site,/usr/share/nvim/s                                                                      nvim/runtime,/tmp/.mount_nvim8rnqIF/usr/lib/nvim,/var/lib/snapd/desktop/nvim/site/after,/usr/share/nvim/site/after,/usr/
/etc/xdg/nvim/after,/home/ubuntu/.config/nvim/after
svrana commented 1 year ago

You could try including /home/ubuntu/.local/share/nvim/site/plugged/colorbuddy.nvim in your packpath. Looks like nvim does not inherit packpath from rtp.

in vimscript

set packpath=/home/ubuntu/.config/nvim,/etc/xdg/nvim,/home/ubuntu/.local/share/nvim/site,/usr/local/share/nvim/site,/usr/share/nvim/s                                                                      nvim/runtime,/tmp/.mount_nvim8rnqIF/usr/lib/nvim,/var/lib/snapd/desktop/nvim/site/after,/usr/share/nvim/site/after,/usr/
/etc/xdg/nvim/after,/home/ubuntu/.config/nvim/after,/home/ubuntu/.local/share/nvim/site/plugged
illegitimate-egg commented 1 year ago

I think that set command had some syntax errors in it, because now I have more errors on startup

Error detected while processing /home/ubuntu/.config/nvim/init.vim:
line    8:
E518: Unknown option: nvim/runtime,/tmp/.mount_nvim8rnqIF/usr/lib/nvim,/var/lib/snapd/desktop/nvim/site/after,/usr/share/nvim/site/after,/usr/
line   15:
E5108: Error executing lua ...nvim/site/plugged/neosolarized.nvim/lua/neosolarized.lua:36: Vim(packadd):E919: Directory not found in 'packpath': "pack/*/opt/colorbuddy.nvim"
stack traceback:
        [C]: in function 'cmd'
        ...nvim/site/plugged/neosolarized.nvim/lua/neosolarized.lua:36: in function 'setup'
        [string ":lua"]:1: in main chunk
Press ENTER or type command to continue
svrana commented 1 year ago

Getting munged.. but it's just your existing packpath and /home/ubuntu/.local/share/nvim/site/plugged/colorbuddy.nvim, separated with a comma.

illegitimate-egg commented 1 year ago

back to just

Error detected while processing /home/ubuntu/.config/nvim/init.vim:
line   15:
E5108: Error executing lua ...nvim/site/plugged/neosolarized.nvim/lua/neosolarized.lua:36: Vim(packadd):E919: Directory not found in 'packpath': "pack/*/opt/colorbuddy.nvim"
stack traceback:
        [C]: in function 'cmd'
        ...nvim/site/plugged/neosolarized.nvim/lua/neosolarized.lua:36: in function 'setup'
        [string ":lua"]:1: in main chunk
Press ENTER or type command to continue
svrana commented 1 year ago

I removed the packadd call that was causing the problem. You'll need to update the plugin, but should work after that.

illegitimate-egg commented 1 year ago

I don't have any errors anymore, but I also don't have any colour anymore

svrana commented 1 year ago

No color at all?

This theme won't set the background unless you set background_set=true; it probably should but doesn't for historical reasons.