p ~/samples/2024/pyside2709/main.py Python 3.10.12 Qt 6.7.2 (x86_64-little_endian-lp64 shared (dynamic) debug build; by GCC 11.4.0) [Python limited API 3.10.12] qmlRegisterType legacy: uri= pyside2709 qmlName= BaseClass qmlRegisterType o= PyObject(type: "Shiboken.ObjectType") PyObject(type: "Shiboken.ObjectType") "pyside2709" v= 1 0 TypeRevision= 1.0 metaObject =0x55d8f460ed00 "BaseClass" inherits QObject classInfo #0 QML.Element, BaseClass property #1 text, QString QMetaType: QMetaType(BaseClass*) "BaseClass*" 24 bytes listId= QMetaType(QQmlListProperty) no qmlTypeInfo()) attachedInfo= false extended= false QmlParserStatus= false QmlPropertyValueSource= false qmlRegisterType returns qmlTypeId= 0 qmlRegisterType legacy: uri= pyside2709 qmlName= ChildClass qmlRegisterType o= PyObject(type: "Shiboken.ObjectType") PyObject(type: "Shiboken.ObjectType") "pyside2709" v= 1 0 TypeRevision= 1.0 metaObject =0x55d8f4611d50 "ChildClass" inherits BaseClass inherits QObject classInfo #0 QML.Element, ChildClass QMetaType: QMetaType(ChildClass*) "ChildClass*" 24 bytes listId= QMetaType(QQmlListProperty) no qmlTypeInfo()) attachedInfo= false extended= false QmlParserStatus= false QmlPropertyValueSource= false qmlRegisterType returns qmlTypeId= 1 Context.__init__ <__main__.Context(0x55d8f4684fb0) at 0x7f7bef306400> BaseClass.__init__ <__main__.ChildClass(0x55d8f4685640) at 0x7f7bef306480> ChildClass.__init__ <__main__.ChildClass(0x55d8f4685640) at 0x7f7bef306480> BaseClass.__init__ <__main__.BaseClass(0x55d8f4685a30) at 0x7f7bef306500> inherits= False write Label_QMLTYPE_2_QML_4(0x55d8f46a75e0) "test" QVariant(QObject*, 0x55d8f4685640) QFlags(0x1|0x2) value= ChildClass(0x55d8f4685640) write cannot convert o= ChildClass(0x55d8f4685640) propMo= BaseClass BaseClass valMo= ChildClass ChildClass slowWrite handleWriteError QMetaType(QObject*) QMetaType(BaseClass*) file:///home/fruser/samples/2024/pyside2709/MainWindow.qml:18: TypeError: Cannot read property 'text' of null file:///home/fruser/samples/2024/pyside2709/MainWindow.qml:17:17: Unable to assign ChildClass to BaseClass DECORATOR ========= p ~/samples/2024/pyside2709_decorator/main.py qmlElementMacro decorator QmlElement typeName= "auto" qmlRegisterType o= PyObject(type: "Shiboken.ObjectType") PyObject(type: "Shiboken.ObjectType") "pyside2709" v= 1 0 TypeRevision= 1.0 metaObject =0x55fc54c43fb0 "BaseClass" inherits QObject classInfo #0 QML.Element, auto property #1 text, QString QMetaType: QMetaType(BaseClass*) "BaseClass*" 24 bytes listId= QMetaType(QQmlListProperty) no qmlTypeInfo()) attachedInfo= false extended= false QmlParserStatus= false QmlPropertyValueSource= false qmlRegisterType returns qmlTypeId= 0 qmlElementMacro decorator QmlElement typeName= "auto" qmlRegisterType o= PyObject(type: "Shiboken.ObjectType") PyObject(type: "Shiboken.ObjectType") "pyside2709" v= 1 0 TypeRevision= 1.0 metaObject =0x55fc54f070b0 "ChildClass" inherits BaseClass inherits QObject classInfo #1 QML.Element, auto QMetaType: QMetaType(ChildClass*) "ChildClass*" 24 bytes listId= QMetaType(QQmlListProperty) no qmlTypeInfo()) attachedInfo= false extended= false QmlParserStatus= false QmlPropertyValueSource= false qmlRegisterType returns qmlTypeId= 1 Python 3.10.12 Qt 6.7.2 (x86_64-little_endian-lp64 shared (dynamic) debug build; by GCC 11.4.0) [Python limited API 3.10.12] Context.__init__ <__main__.Context(0x55fc54fe95c0) at 0x7fc8a616a380> BaseClass.__init__ <__main__.ChildClass(0x55fc54fe9c50) at 0x7fc8a616a400> ChildClass.__init__ <__main__.ChildClass(0x55fc54fe9c50) at 0x7fc8a616a400> BaseClass.__init__ <__main__.BaseClass(0x55fc54fea040) at 0x7fc8a616a480> inherits= True