Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. calling QSqlDatabase::open() causes hang (macOS sequoia)

calling QSqlDatabase::open() causes hang (macOS sequoia)

Scheduled Pinned Locked Moved Solved General and Desktop
4 Posts 1 Posters 175 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.
  • D Offline
    D Offline
    davecotter
    wrote on last edited by
    #1

    i recently upgraded to sequoia, and now, more often than not, when running in the debugger, opening my database causes a hang.

    Screenshot 2025-02-12 at 2.08.54 PM.png

    When i run outside the debugger, it opens just fine.

    I suspect it has to do with "full disk access"? but i've given my app full disk access.

    i've also set Qt and Xcode to have "Allow apps to use developer tools" permissions. as a test i also added my app into that permission group, all to no avail.

    the path to the DB being opened is in my user's Music folder, and having full disk access gives permission for everything, including things in that folder.

    confused!

    1 Reply Last reply
    0
    • D Offline
      D Offline
      davecotter
      wrote on last edited by
      #4

      okay the real culprit seems to be that when debugging my app, sometimes i kill the app to keep editing the code, but the killed app turns into a zombie instead of getting killed. so it's lurking in the background, keeping the DB open.

      I'm still not sure why the new run of the app will hang when attempting to open the DB, i'd'a thought it would return immediately with an error.

      solution is to try to force kill the zombine, or sometimes quitting and re-running Qt Creator helps, or as a last resort, duplicate the DB, trash the original DB, and rename the dupe to be the original name

      1 Reply Last reply
      0
      • D Offline
        D Offline
        davecotter
        wrote on last edited by
        #2

        In case it helps:

        -------------------------------------
        Translated Report (Full Report Below)
        -------------------------------------
        
        Process:               kJams 2 Debug [5958]
        Path:                  /Volumes/VOLUME/*/kJams 2 Debug.app/Contents/MacOS/kJams 2 Debug
        Identifier:            com.metamuse.kjams
        Version:               2.1b78r01 (1.0)
        Code Type:             X86-64 (Translated)
        Parent Process:        Exited process [5959]
        User ID:               501
        
        Date/Time:             2025-02-12 14:12:25.3353 -0800
        OS Version:            macOS 15.3.1 (24D70)
        Report Version:        12
        Anonymous UUID:        3144ECD9-1CFD-6473-8DC4-4316440144DF
        
        Sleep/Wake UUID:       5231BC99-5FF5-479E-B72E-6F63F931E3D5
        
        Time Awake Since Boot: 160000 seconds
        
        System Integrity Protection: enabled
        
        Notes:
        PC register does not match crashing frame (0x0 vs 0x7FF8A64D6A84)
        
        Crashed Thread:        0  Main  Dispatch queue: com.apple.main-thread
        
        Exception Type:        EXC_CRASH (SIGABRT)
        Exception Codes:       0x0000000000000000, 0x0000000000000000
        
        External Modification Warnings:
        Debugger attached to process.
        
        Error Formulating Crash Report:
        PC register does not match crashing frame (0x0 vs 0x7FF8A64D6A84)
        
        Thread 0 Crashed:: Main Dispatch queue: com.apple.main-thread
        0   ???                           	    0x7ff8a64d6a84 ???
        1   libsystem_kernel.dylib        	    0x7ff815fc76de __open + 10
        2   libsystem_kernel.dylib        	    0x7ff815fd06e5 open + 202
        3   libqsqlite.dylib              	       0x125ab068e robust_open + 158 (sqlite3.c:39202)
        4   libqsqlite.dylib              	       0x125a93247 unixOpen + 1895 (sqlite3.c:44845)
        5   libqsqlite.dylib              	       0x125ab49a3 sqlite3OsOpen + 20 (sqlite3.c:26484
        6   libqsqlite.dylib              	       0x125ab49a3 sqlite3PagerOpen + 81 (sqlite3.c:62
        7   libqsqlite.dylib              	       0x125ab49a3 sqlite3BtreeOpen + 3059 (sqlite3.c:
        8   libqsqlite.dylib              	       0x125aa6c57 openDatabase + 1623 (sqlite3.c:1845
        9   libqsqlite.dylib              	       0x125a84e1e QSQLiteDriver::open(QString const&,
        10  QtSql                         	       0x10f69b0ba QSqlDatabase::open() + 58 (qsqldata
        11  kJams 2 Debug                 	       0x1005419d4 csql::Database::Open(SuperString co
        
        1 Reply Last reply
        0
        • D Offline
          D Offline
          davecotter
          wrote on last edited by davecotter
          #3

          i thought code signing helped, but it didn't. immediately had the problem again. problem persists even now

          1 Reply Last reply
          0
          • D davecotter has marked this topic as solved on
          • D davecotter has marked this topic as unsolved on
          • D Offline
            D Offline
            davecotter
            wrote on last edited by
            #4

            okay the real culprit seems to be that when debugging my app, sometimes i kill the app to keep editing the code, but the killed app turns into a zombie instead of getting killed. so it's lurking in the background, keeping the DB open.

            I'm still not sure why the new run of the app will hang when attempting to open the DB, i'd'a thought it would return immediately with an error.

            solution is to try to force kill the zombine, or sometimes quitting and re-running Qt Creator helps, or as a last resort, duplicate the DB, trash the original DB, and rename the dupe to be the original name

            1 Reply Last reply
            0
            • D davecotter has marked this topic as solved on

            • Login

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