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

mimeData crashes when drag & drop

    XMLWordPrintable

Details

    • Bug
    • Resolution: Incomplete
    • Not Evaluated
    • None
    • 6.3.0
    • PySide
    • None
    • Windows

    Description

      from PySide6 import QAbstractItemModel ...

      def mimeData(self, indexes):
      ...
      mimeData = QMimeData()
      ....
      return mimeData

      This code crashes app.

      So I create an attribute in initializer and recreate this attribute in mimeData method because it is garbaged after drop.

      def _init_(self):
      self.mimeData = QMimeData()

      def mimeData(self, indexes):
      ...
      self.mimeData = QMimeData()
      ...
      return self.mimeData

      I think this problem is a kind of lifecycle of PySide.
      On the past time, I have reported a bug about createObject of QTextDocument. I think this is very similar to this bug.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            crmaurei Cristian Maureira-Fredes
            nori Harunori Fujimoto
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes