Giter Site home page Giter Site logo

module 'gdb.app' not found about nvim-gdb HOT 6 CLOSED

sakhnik avatar sakhnik commented on April 28, 2024
module 'gdb.app' not found

from nvim-gdb.

Comments (6)

Darkheron avatar Darkheron commented on April 28, 2024 1

All is working again. I was testing on three different machines and forgot that we had a custom compiled/named version of gdb on the one that generated that last error. It worked fine on the others. My bad. :) This can be closed. Thank you for the help.

from nvim-gdb.

sakhnik avatar sakhnik commented on April 28, 2024

Could you please provide the whole output of :messages?

from nvim-gdb.

Darkheron avatar Darkheron commented on April 28, 2024

Error detected while processing /home/darkheron/.local/share/nvim/plugged/nvim-gdb/autoload/nvimgdb.vim:
line 4:
E5105: Error while calling lua chunk: [string ""]:1: module 'gdb.app' not found:^@^Ino field package.preload['gdb.app']^@^Ino file '/home/darkheron/.con
fig/nvim/lua/gdb/app.lua'^@^Ino file '/home/darkheron/.config/nvim/lua/gdb/app/init.lua'^@^Ino file '/home/darkheron/.local/share/nvim/plugged/gruvbox//lua/gdb/app.lua'^@^Ino
file '/home/darkheron/.local/share/nvim/plugged/gruvbox//lua/gdb/app/init.lua'^@^Ino file '/home/darkheron/.local/share/nvim/plugged/vim-airline//lua/gdb/app.lua'^@^Ino file
'/home/darkheron/.local/share/nvim/plugged/vim-airline//lua/gdb/app/init.lua'^@^Ino file '/home/darkheron/.local/share/nvim/plugged/vim-easy-align//lua/gdb/app.lua'^@^Ino fi
le '/home/darkheron/.local/share/nvim/plugged/vim-easy-align//lua/gdb/app/init.lua'^@^Ino file '/home/darkheron/.local/share/nvim/plugged/vim-plugin-autosess//lua/gdb/app.lua
'^@^Ino file '/home/darkheron/.local/share/nvim/plugged/vim-plugin-autosess//lua/gdb/app/init.lua'^@^Ino file '/home/darkheron/.local/share/nvim/plugged/vim-multiple-cursors/
/lua
Error detected while processing function nvimgdb#Spawn:
line 1:
E5108: Error while calling lua chunk for luaeval(): [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing BufLeave Auto commands for "":
E5105: Error while calling lua chunk: [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing TabLeave Auto commands for "
":
E5105: Error while calling lua chunk: [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing function nvimgdb#CheckWindowClosed:
line 2:
E5108: Error while calling lua chunk for luaeval(): [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing TabEnter Auto commands for "":
E5105: Error while calling lua chunk: [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing BufEnter Auto commands for "
":
E5105: Error while calling lua chunk: [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing BufLeave Auto commands for "":
E5105: Error while calling lua chunk: [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing TabLeave Auto commands for "
":
E5105: Error while calling lua chunk: [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing function nvimgdb#CheckWindowClosed:
line 2:
E5108: Error while calling lua chunk for luaeval(): [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing TabEnter Auto commands for "":
E5105: Error while calling lua chunk: [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing BufEnter Auto commands for "
":
E5105: Error while calling lua chunk: [string ""]:1: attempt to index global 'gdb' (a nil value)
Error detected while processing function nvimgdb#CheckWindowClosed:
line 2:
E5108: Error while calling lua chunk for luaeval(): [string ""]:1: attempt to index global 'gdb' (a nil value)

This or something else?

from nvim-gdb.

sakhnik avatar sakhnik commented on April 28, 2024

Are you sure the script install.sh finished successfully? Could you please run it manually in a terminal shell?
It looks like the Lua files are missing, they should be compiled from the Moonscript sources. That's what the install.sh does.

from nvim-gdb.

Darkheron avatar Darkheron commented on April 28, 2024

Thank you for taking the time to help.
I made progress by running the install.sh manually and finding that lua.h could not be found... even though Plugged indicated it was installed correctly. After finding the package liblua5.1-0-dev from the repositories progess was made and I can now invoke GdbStart, but I have another problem.

After invoking GdbStart on the test application you provide: a.out I get the following output in the window:

File "/home/darkheron/.local/share/nvim/plugged/nvim-gdb/lib/BaseProxy.py", line 153, in Create
13 return BaseProxy(features, args.address, args.cmd)
12 File "/home/darkheron/.local/share/nvim/plugged/nvim-gdb/lib/BaseProxy.py", line 45, in init
11 os.execlp(argv[0], *argv)
10 File "/usr/lib/python3.5/os.py", line 598, in execlp
9 execvp(file, args)
8 File "/usr/lib/python3.5/os.py", line 615, in execvp
7 _execvpe(file, args)
6 File "/usr/lib/python3.5/os.py", line 660, in _execvpe
5 raise last_exc.with_traceback(tb)
4 File "/usr/lib/python3.5/os.py", line 650, in _execvpe
3 exec_func(fullname, *argrest)
2 FileNotFoundError: [Errno 2] No such file or directory
1
18 [Process exited 0]

I don't think this is the full output of the error so I can't figure out what file is missing. Where does the text error dump for this invocation get saved? Any keystroke causes the window to close so I can't yank the whole buffer.. Or is there a command I can use to do such a thing.

from nvim-gdb.

sakhnik avatar sakhnik commented on April 28, 2024

I assumed that install.sh should have failed because bash was invoked with -e. And the vim-plugged should have propagated the error.
Now, the debugger is started by the proxy script lib/gdbproxy.py, that's how it works in both branches: legacy and master. The proxy couldn't launch the debugger because it wasn't reachable in the PATH? Make sure the first argument of the command :GdbStart is gdb. Try the keystroke <leader>dd as an example if you haven't remapped it yet.

from nvim-gdb.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.