Giter Site home page Giter Site logo

Comments (13)

joshhansen avatar joshhansen commented on May 7, 2024 1

I ran the latest version and see the new add sources button. I think something else may be causing my difficulty. I loaded my executable, and added its source file, and then clicked "Run". The terminal gives a stacktrace followed by "gdb.error: The program is not being run." I could not copy and paste the error from the terminal so I pieced it together from the HTML inspector in my browser:

GNU gdb (GDB) Fedora 8.3-7.fc30
Copyright (C) 2019 Free Software Foundation, Inc.                       
License GPLv3+: GNU GPL version 3 or later <
This is free software: you are free to change and redistribute it. 
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu". 
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
http://www.gnu.org/software/gdb/bugs/
Find the GDB manual and other documentation resources online at:
http://www.gnu.org/software/gdb/documentation/
For help, type "help". 
Type "apropos word" to search for commands related to "word". 
(gdb) warning: Missing auto-load script at offset 0 in section .debug_gdb_scripts
of file /home/josh/Projects/Umpire/target/debug/umpire-train-ai. 
Use `info auto-load python-scripts [REGEXP]\' to list them.
(gdb) Traceback (most recent call last):
  File "/home/josh/Projects/External/gdb-frontend/api/debug.py", line 60, in _exec__mT
    output = callback(*args, **kwargs)
  File "/home/josh/Projects/External/gdb-frontend/api/debug.py", line 488, in cont
    gdb.execute("c")
gdb.error: The program is not being run.

(gdb) 

from gdb-frontend.

joshhansen avatar joshhansen commented on May 7, 2024 1

I was clicking the button to the right of the bug icon. The bug button looked like the logo so I think I just ignored it.

from gdb-frontend.

rohanrhu avatar rohanrhu commented on May 7, 2024

Look this: https://github.com/rohanrhu/gdb-frontend#gdb-related-issues-and-tips

When you step over a line that calls a function from the linked object, GDB will get source files from linked object.

Loading additional sources is a TODO: #3

Also, after trying that trick, you can provide more information on especially Rust debugging for this issue.

Until when "additional sources" feature is come, you can open source files on Developer Tools with following command:

GDBFrontend.components.gdbFrontend.openSource({file: {path: '/path/to/source.rust'}})

This will open your source file on source viewer.

from gdb-frontend.

rohanrhu avatar rohanrhu commented on May 7, 2024

I added open source button to sources section (also shortcut: Ctrl+O). (0ad3570)

I'm closing this issue but also I will add an another feature like adding additional source folders feature.

from gdb-frontend.

rohanrhu avatar rohanrhu commented on May 7, 2024

It is fixed.

from gdb-frontend.

rohanrhu avatar rohanrhu commented on May 7, 2024

I ran the latest version and see the new add sources button. I think something else may be causing my difficulty. I loaded my executable, and added its source file, and then clicked "Run". The terminal gives a stacktrace followed by "gdb.error: The program is not being run." I could not copy and paste the error from the terminal so I pieced it together from the HTML inspector in my browser:

GNU gdb (GDB) Fedora 8.3-7.fc30
Copyright (C) 2019 Free Software Foundation, Inc.                       
License GPLv3+: GNU GPL version 3 or later <
This is free software: you are free to change and redistribute it. 
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu". 
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
http://www.gnu.org/software/gdb/bugs/
Find the GDB manual and other documentation resources online at:
http://www.gnu.org/software/gdb/documentation/
For help, type "help". 
Type "apropos word" to search for commands related to "word". 
(gdb) warning: Missing auto-load script at offset 0 in section .debug_gdb_scripts
of file /home/josh/Projects/Umpire/target/debug/umpire-train-ai. 
Use `info auto-load python-scripts [REGEXP]\' to list them.
(gdb) Traceback (most recent call last):
  File "/home/josh/Projects/External/gdb-frontend/api/debug.py", line 60, in _exec__mT
    output = callback(*args, **kwargs)
  File "/home/josh/Projects/External/gdb-frontend/api/debug.py", line 488, in cont
    gdb.execute("c")
gdb.error: The program is not being run.

(gdb) 

I'm not sure what was this problem exactly. You can tell me about if last revision (124ee0f) solved the problem.

from gdb-frontend.

joshhansen avatar joshhansen commented on May 7, 2024

The latest revision has the same error, but I am able to see the loaded source file now.

from gdb-frontend.

rohanrhu avatar rohanrhu commented on May 7, 2024

The latest revision has the same error, but I am able to see the loaded source file now.

Are you sure you are clicking to run button not continue button?

Run button has a bug icon.

from gdb-frontend.

rohanrhu avatar rohanrhu commented on May 7, 2024

I was clicking the button to the right of the bug icon. The bug button looked like the logo so I think I just ignored it.

So, there is no any problem now?

from gdb-frontend.

joshhansen avatar joshhansen commented on May 7, 2024

It runs now though I am unable to set breakpoints in the UI. You may also want to reconsider the icon---it is common for debugging to start with the triangle "play" icon, e.g. VSCode. It may be confusing to others as well as myself. Or maybe not, I'll leave that to you!

from gdb-frontend.

rohanrhu avatar rohanrhu commented on May 7, 2024

What is the problem for setting breakpoints? If you are setting breakpoints before loading executable, GDB will disable them when you load an executable. In this case, you can re-enable that breakpoints on "Breakpoints" section on the right side. Otherwise, you must provide more information about that.

from gdb-frontend.

joshhansen avatar joshhansen commented on May 7, 2024

When I click the red dot in the left margin to set a breakpoint for a line, nothing happens.

from gdb-frontend.

rohanrhu avatar rohanrhu commented on May 7, 2024

When I click the red dot in the left margin to set a breakpoint for a line, nothing happens.

Very interesting.. There maybe an issue about espacially Rust debugging. Can you open a new issue with more information about the issue like rust source (that causes this issue), video, screenshots, and instructions to reproduce the same issue.

from gdb-frontend.

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.