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. Qt Creator clipboard-related hang on Macintosh
QtWS25 Last Chance

Qt Creator clipboard-related hang on Macintosh

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
macqt creatorclipboardhang
6 Posts 2 Posters 2.0k 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.
  • H Offline
    H Offline
    hrodstein
    wrote on last edited by
    #1

    We are using Qt 5.9.4 and Qt Creator 4.4.0 to debug a 64-bit application on Mac OS.

    We consistently get a hang when we hit a breakpoint if we happen to copy text to the clipboard before we hit the breakpoint. The same thing happens if we crash after copying to the clipboard. Qt Creator hangs for 3 to 20 minutes during which time we get a spinning pizza. Eventually, Qt Creator becomes responsive and we can continue. This issue is a significant impediment for debugging.

    I believe that the hang is related to Macintosh clipboard "promises" fulfilled by QMacPasteboard::promiseKeeper in qmacclipboard.mm, but I don't know exactly why it happens or how to avoid it.

    I can reproduce the hang using the qtbase/examples/widgets/textedit example program as follows:

    1. Open the qtbase/examples/widgets/textedit project in Qt Creator and launch the debug configuration.

    2. Set a breakpoint at the start of TextEdit::fileOpen in textedit.cpp.

    3. In the Qt textedit example program, select some text from the sample document and copy it to the clipboard.

    4. Choose File->Open File.

    On my machine, this hung Qt Creator with a spinning pizza for 12 minutes.

    When Qt Creator finally responded, I continued the application and repeated the test with a similar result - a 3-minute delay before breaking.

    You can avoid the problem by activating Qt Creator after copying the text in the Qt textedit example but before the breakpoint is hit, if you remember to activate Qt Creator before you trigger the hang.

    I'm not sure if this qualifies as a Qt bug and I did not find any bug reports about it. Perhaps someone in this forum has a suggestion.

    Thanks.

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      Since you can trigger it at will then I'd say it's worth opening a report.

      What version of macOS are you using ?
      Does it also happen with a more recent version of Qt Creator ?

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

      1 Reply Last reply
      0
      • H Offline
        H Offline
        hrodstein
        wrote on last edited by
        #3

        I am running Mac OS 10.13.2. (I see 10.13.3 is now available.)

        I updated to Qt Creator 4.5.2 and the problem remains.

        I have filed a bug report:
        https://bugreports.qt.io/browse/QTCREATORBUG-20122

        1 Reply Last reply
        2
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Can you also give a shot to Qt Creator 4.6 RC ?

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

          H 1 Reply Last reply
          0
          • SGaistS SGaist

            Can you also give a shot to Qt Creator 4.6 RC ?

            H Offline
            H Offline
            hrodstein
            wrote on last edited by
            #5

            I get the same behavior (hang) with Qt Creator 4.6.0-rc1.

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #6

              Ok, thanks for testing !

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

              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