Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Debugger: Undefined command "bb" trying to use Locals and Expressions
Forum Updated to NodeBB v4.3 + New Features

Debugger: Undefined command "bb" trying to use Locals and Expressions

Scheduled Pinned Locked Moved Qt Creator and other tools
8 Posts 4 Posters 5.8k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    controlhorus
    wrote on last edited by
    #1

    Hello

    I can start my application and put breakpoints. But I am not able to see anything at 'Local and Expressions' window. I can see at Debugger Log window that at process start sequence there is a 'bb ...' command that give us the undefined command message. If I try to Insert New Expression Evaluator I got the same error:

    DUMPER FAILED:60^error,data={msg="Undefined command: \"bb" Try "help"."}

    I have been looking for bb command on the GDB commands list but I can not find it. Is really bb a GDB command? Is there another interpreter between QT desktop and GDB?

    QtCreator 2.8.0 Based on Qt 4.8.4 running on Ubuntu 12.04
    Using GDB 7.5.1

    Thanks and best regards,
    Jose

    1 Reply Last reply
    0
    • C Offline
      C Offline
      controlhorus
      wrote on last edited by
      #2

      Hello

      As I understand it, QT calls to * dumpers* to visualize the variables and expressions. At last in my installation they seems to be executed through Python. I suppose the undefined bb is part of the dumper commands.

      I did not pay attention to previous messages on Debbuger log window. Going back, looking before the bb error, there are previous errors related to dumpers and python.

      <24-interpreter-exec console "python execfile('/opt/qt4/share/qtcreator/dumper/gbridge.py')"
      <25importPlainDumpers

      &"Traceback (most recent call last):\n"
      &" File "<string>", line 1, in <module>\n"
      &" File "/opt/qt4/share/qtcreator/dumper/gbridge.py", line 9, in <module>\n"
      &" import subprocess\n"
      &"ImportError: No module named subprocess\n"
      &"Error while executing Python code.\n"
      24^error,msg="Error while executing Python code."

      &"importPlainDumpers\n"
      &"Undefined command: "importPlainDumpers". Try "help".\n"
      25^error,msg="Undefined command: \"importPlainDumpers". Try "help"."

      So python is failing. Any clue?

      Best regards

      1 Reply Last reply
      0
      • C Offline
        C Offline
        controlhorus
        wrote on last edited by
        #3

        Hello

        So, We went to pythonland. Here, thats is Ubuntu 12.04. Python version 2.7.3

        If I execute execfile(’/opt/qt4/share/qtcreator/dumper/gbridge.py’) inside python from a terminal window, it detects subprocess module without problem.

        If I add a "print sys.version_info" as an additional start debugger command at QtCreator, it shows me: python 2.7.3
        For that printing, I added a 'import sys' command that worked. If I add a 'import subprocces'' ... it is not found 8:|

        Why QTCreator python execute does not find subprocess module? Where is it being disabled?

        Thanks and best regards

        1 Reply Last reply
        0
        • C Offline
          C Offline
          controlhorus
          wrote on last edited by
          #4

          Hello

          Problem found. We have TWO ptyhonlands. Doing a print sys.path at QT debugger start, we get a totally different path from doing it from a terminal window.

          We are starting QTCreator using a special script for a embedded target. That script change the PYTHONHOME variable and redirect it to another different python with the same version number ... but different default modules.

          (Our) QTCreator uses the actual python to call the dumpers to show the variables values. To test what python are you using, you must add this commands to Debugger options:

          python

          import sys

          print sys.version_info

          print sys.path

          end

          Then you can see that values on Debugger Log window

          Thanks and best regards

          1 Reply Last reply
          0
          • M Offline
            M Offline
            mapcat
            wrote on last edited by
            #5

            The second section of this post will help: http://getmoai.com/forums/debugging-moai-source-on-linux-t2149/

            1 Reply Last reply
            0
            • N Offline
              N Offline
              Na2bp
              wrote on last edited by
              #6

              Hello,

              I have the same problem as reported above. I get this error message when using the debugger in QT Creator:

              &"Traceback (most recent call last):\n"
              &" File "<string>", line 1, in <module>\n"
              &" File "/home/dirk/Sitara/Qt5.1.1/Tools/QtCreator/share/qtcreator/dumper/gbridge.py", line 9, in <module>\n"
              &" import subprocess\n"
              &"ImportError: No module named subprocess\n"
              &"Error while executing Python code.\n"
              1302^error,msg="Error while executing Python code."

              &"importPlainDumpers\n"
              &"Undefined command: "importPlainDumpers". Try "help".\n"
              1303^error,msg="Undefined command: \"importPlainDumpers". Try "help"."

              I am using QT 5.1.1 (QT Creator), the TI SDK 6.00 for cross-compiling to the AM335x EVM.
              My python version is according to "print sys.version_info" 2.7.3.
              My debugger is an "arm-linux-gnueabihf-gdb" version 7.5.

              Can someone help? I didn't figure out how to solve it.

              Thanks in advance,
              Dirk

              1 Reply Last reply
              0
              • A Offline
                A Offline
                andrep
                wrote on last edited by
                #7

                @Nazb2: The problem here is that your python installation does not have the 'subprocess' module which is used by the LLDB backend and on the GDB side only by one of the advanced dumper features (display vector data in gnuplot). Since 3.0 beta Qt Creator should silently disable the gnuplot feature when the subprocess module is not found, prior to that you can do it manually by removing or commenting out the offending 'import subprocess' line.

                1 Reply Last reply
                0
                • N Offline
                  N Offline
                  Na2bp
                  wrote on last edited by
                  #8

                  Ok, thanks andrep, works fine for me.

                  1 Reply Last reply
                  0

                  • Login

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • Users
                  • Groups
                  • Search
                  • Get Qt Extensions
                  • Unsolved