Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. qDebug repeating output

qDebug repeating output

Scheduled Pinned Locked Moved Unsolved Installation and Deployment
10 Posts 4 Posters 428 Views
  • 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.
  • S Offline
    S Offline
    Spacehopper
    wrote on 3 Apr 2025, 17:13 last edited by Spacehopper 4 Mar 2025, 17:38
    #1

    Hi,
    I seem to have managed to do something strange to my Qt5 library on macOS Sequoia 15.4. I resurrected some old C++ code from several years ago and in the process seem to have made every call to qDebug repeat the output.

    For instance: qDebug("Grid solved.")
    results in this output:
    Grid solved.
    Grid solved.

    Is it possible to reinstall the relevant library?

    TIA.

    Chris

    S 1 Reply Last reply 3 Apr 2025, 19:31
    0
    • P Offline
      P Offline
      piervalli
      wrote on 3 Apr 2025, 19:13 last edited by
      #2

      There more load instance.

      1 Reply Last reply
      0
      • S Spacehopper
        3 Apr 2025, 17:13

        Hi,
        I seem to have managed to do something strange to my Qt5 library on macOS Sequoia 15.4. I resurrected some old C++ code from several years ago and in the process seem to have made every call to qDebug repeat the output.

        For instance: qDebug("Grid solved.")
        results in this output:
        Grid solved.
        Grid solved.

        Is it possible to reinstall the relevant library?

        TIA.

        Chris

        S Offline
        S Offline
        SGaist
        Lifetime Qt Champion
        wrote on 3 Apr 2025, 19:31 last edited by
        #3

        @Spacehopper hi,

        Do you see that in Qt Creator ? On the command line ?
        Do you have a custom message handler ?

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        S 1 Reply Last reply 3 Apr 2025, 20:16
        0
        • S SGaist
          3 Apr 2025, 19:31

          @Spacehopper hi,

          Do you see that in Qt Creator ? On the command line ?
          Do you have a custom message handler ?

          S Offline
          S Offline
          Spacehopper
          wrote on 3 Apr 2025, 20:16 last edited by
          #4

          @SGaist

          Thanks for responding.

          I use Xcode as my IDE and I don't have a custom message handler. I don't have access to or use Qt Creator.

          1 Reply Last reply
          0
          • S Offline
            S Offline
            Spacehopper
            wrote on 3 Apr 2025, 20:20 last edited by Spacehopper 4 Mar 2025, 20:21
            #5

            I run the code from Xcode using Product -> Run

            The output from qDebug appears in the console pane of Xcode

            1 Reply Last reply
            0
            • S Offline
              S Offline
              Spacehopper
              wrote on 3 Apr 2025, 20:32 last edited by
              #6

              This is code I started back in 2008 to solve Sudoku puzzles. It ran fine up until 2021 when I lost interest. However my wife has now become a Sudoku fanatic and asked me how to solve a slightly difficult puzzle. I resurrected the code to demonstrate using certain strategies and noticed that all qDebug output to the Xcode console pane was repeated. I put a breakpoint on a common code line using qDebug and when I single stepped through the code line it caused the output to be repeated so I assumed something odd had happened to the relevant library.

              1 Reply Last reply
              0
              • S Offline
                S Offline
                Spacehopper
                wrote on 4 Apr 2025, 08:01 last edited by
                #7

                Ah! Interesting. If I run the app from a terminal the repeated output is absent. Any clue there?

                J 1 Reply Last reply 4 Apr 2025, 08:44
                0
                • S Spacehopper
                  4 Apr 2025, 08:01

                  Ah! Interesting. If I run the app from a terminal the repeated output is absent. Any clue there?

                  J Offline
                  J Offline
                  JonB
                  wrote on 4 Apr 2025, 08:44 last edited by
                  #8

                  @Spacehopper
                  I do not know how it works under Mac/Xcode, but I would say: qDebug() output appears on "stdout"/"stderr" or similar. That is one output you see from a plain terminal. Whatever "IDE" Xcode is, it sounds like inside it it (Xcode) also echoes any such messages --- debug output or stderr or whatever --- to output, hence you see it twice? I do not know whether there is maybe an Xcode setting for that.

                  1 Reply Last reply
                  0
                  • S Offline
                    S Offline
                    Spacehopper
                    wrote on 4 Apr 2025, 09:01 last edited by
                    #9

                    OK, so thinking this through, it looks like the problem lies with some setting in Xcode. I apologise for posting to the wrong forum and thank you for your forbearance.

                    1 Reply Last reply
                    0
                    • S Offline
                      S Offline
                      Spacehopper
                      wrote on 4 Apr 2025, 09:06 last edited by
                      #10

                      @JonB

                      Xcode is the macOS IDE offering for development for ANY Apple OS. I have been using it, on and off, since 2006 without too much in the way of problems but Xcode has changed a lot since I last used it in 2021 hence my rustiness. :-)

                      1 Reply Last reply
                      0

                      5/10

                      3 Apr 2025, 20:20

                      • Login

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