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

RuntimeWarning: CopyCppToPython(): SbkConverter::copyToPython is null for "PySide6.QtOpcUa.QOpcUaWriteResult".

    XMLWordPrintable

Details

    • Linux/X11
    • 0448857f4 (tqtc/dev), 97ab53936 (tqtc/6.8)

    Description

      RuntimeWarning: CopyCppToPython(): SbkConverter::copyToPython is null for "PySide6.QtOpcUa.QOpcUaWriteResult" occurs when the following signal is received:
      
      PySide6.QtOpcUa.QOpcUaClient.writeNodeAttributesFinished(results, serviceResult)
      

      The warning only occurs in PySide, and a similar signal and slot connection in Qt in c++ doesn't show that warning.
      To reproduce the the issue, run the attached pyside project ( an edited version of Qt OPC UA Viewer Example project) and connect to an OPC UA server.
      In mainwindow.py, the following lines have been added:

      @Slot(list, QOpcUa.UaStatusCode)
       def onWriteNodeAttributesFinished(self, results, serviceResult)  # line 407
      
      def onWriteNodeAttributes(self) # line 369 called in line 237
      
      writeNodeAttributesFinished = Signal(list)  # line 71
      
      self._opcua_client.writeNodeAttributesFinished.connect(self.onWriteNodeAttributesFinished)   #line 146
      

      Steps to run an OPC UA server:

      • Use Qt waterpump simulation server when listening on 43344

      or

      void QOpcUaClient::writeNodeAttributesFinished(QList<QOpcUaWriteResult> results, QOpcUa::UaStatusCode serviceResult)
      

      Attachments

        1. pyside3015_repro.diff
          5 kB
          Friedemann Kleint
        2. opcuaviewer_pyside.zip
          160 kB
          Mehdi Belila
        3. opcuaviewer_cpp_no_error.zip
          163 kB
          Mehdi Belila
        4. opcua_debug_logs
          10 kB
          Mehdi Belila

        Issue Links

          For Gerrit Dashboard: PYSIDE-3015
          # Subject Branch Project Status CR V

          Activity

            People

              kleint Friedemann Kleint
              mahdi.belila Mehdi Belila
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes