Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-2966

Retrieving QScrollerProperties from QScroller causes SegFault

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P2: Important
    • None
    • 6.7.2, 6.8.1
    • PySide
    • None
    • macOS
    • a067880f7 (dev), dfc0cd3dc (dev), c78ddb92a (dev), 50db2651a (6.8), 3b5303a35 (dev), d8ac9b9d2 (dev)

    Description

      The following code demonstrates the SegFault I receive when using QScoller.scrollerProperties to access QScrollerProperties for a QGraphicsView:

      from PySide6.QtWidgets import QApplication, QGraphicsView, QScroller
      
      app = QApplication([])
      
      view = QGraphicsView()
      scroller = QScroller(view.viewport())
      properties = scroller.scrollerProperties()
      
      app.exec()

      The stack trace (shortened):

      -------------------------------------
      Translated Report (Full Report Below)
      -------------------------------------
      
      Process: Python [2801]
      Path: /Library/Frameworks/Python.framework/Versions/3.11/Resources/Python.app/Contents/MacOS/Python
      Identifier: org.python.python
      Version: 3.11.8 (3.11.8)
      Code Type: ARM-64 (Native)
      Parent Process: pycharm [1788]
      Responsible: pycharm [1788]
      User ID: 501
      
      Date/Time: 2024-11-08 08:55:57.6126 +0100
      OS Version: macOS 15.1 (24B83)
      Report Version: 12
      Anonymous UUID: 1C75841B-80CB-5D0F-D360-4BBAB773D591
      
      
      Time Awake Since Boot: 2200 seconds
      
      System Integrity Protection: enabled
      
      Crashed Thread: 0 Dispatch queue: com.apple.main-thread
      
      Exception Type: EXC_BAD_ACCESS (SIGSEGV)
      Exception Codes: KERN_INVALID_ADDRESS at 0x0000000000000020
      Exception Codes: 0x0000000000000001, 0x0000000000000020
      
      Termination Reason: Namespace SIGNAL, Code 11 Segmentation fault: 11
      Terminating Process: exc handler [2801]
      
      VM Region Info: 0x20 is not in any region. Bytes before following region: 4341710816
       REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL
       UNUSED SPACE AT START
      ---> 
       __TEXT 102c94000-102c98000 [ 16K] r-x/r-x SM=COW /Library/Frameworks/Python.framework/Versions/3.11/Resources/Python.app/Contents/MacOS/Python
      
      Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
      0 QtWidgets 	 0x1082a81f4 QScrollerProperties::QScrollerProperties(QScrollerProperties const&) + 48
      1 QtWidgets.abi3.so 	 0x108b18000 Sbk_QScrollerFunc_scrollerProperties(_object*) + 120
      2 Python 	 0x103b44338 cfunction_vectorcall_NOARGS + 88
      3 Python 	 0x103c06990 _PyEval_EvalFrameDefault + 53096
      4 Python 	 0x103bf8774 PyEval_EvalCode + 276
      5 Python 	 0x103c767d4 pyrun_file + 240
      6 Python 	 0x103c75fa4 _PyRun_SimpleFileObject + 288
      7 Python 	 0x103c75518 _PyRun_AnyFileObject + 232
      8 Python 	 0x103c9f288 pymain_run_file_obj + 220
      9 Python 	 0x103c9ea6c pymain_run_file + 72
      10 Python 	 0x103c9e280 Py_RunMain + 1828
      11 Python 	 0x103c9f404 pymain_main + 52
      12 Python 	 0x103c9fc3c Py_BytesMain + 40
      13 dyld 	 0x1837dc274 start + 2840 

       

      Attachments

        1. pyside_2966.py
          0.5 kB
          Tilman Krummeck
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            kleint Friedemann Kleint
            tilmankrummeck Tilman Krummeck
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: