You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When compiling ui files using pyside2-uic (PySide-5.15.4), QtCompat.translate() will sometimes have 3 arguments: QtCompat.translate("MainWindow", u"MainWindow", None)
When executing our program, TypeError is raised:
File "/dd/shows/DEV01/user/work.akelada/tools/cent7_64/package/launchpad/0.1.2/python/launchpad/Ui_launchpad_UI.py", line 205, in retranslateUi
MainWindow.setWindowTitle(QtCompat.translate("MainWindow", u"MainWindow", None))
File "/dd/tools/cent7_64/package/qt_py/1.3.6/python/Qt.py", line 844, in _translate
"Expected 4 or 5 arguments, got {0}.".format(len(args) + 2))
TypeError: Expected 4 or 5 arguments, got 3.
When compiling ui files using
pyside2-uic
(PySide-5.15.4), QtCompat.translate() will sometimes have 3 arguments:QtCompat.translate("MainWindow", u"MainWindow", None)
When executing our program, TypeError is raised:
I believe a fix should be made to
_translate()
as it is forcing us to use a certain number of arguments even though in the original methods, some arguments are optional:https://doc.qt.io/qtforpython-5/PySide2/QtCore/QCoreApplication.html#PySide2.QtCore.PySide2.QtCore.QCoreApplication.translate
Also:
pyside2-uic foo.ui
-->QCoreApplication.translate("MainWindow", u"MainWindow", None)
(pyside-5.15.4)pyside2-uic foo.ui
-->QCoreApplication.translate("MainWindow", u"MainWindow", None, -1)
(pyside-5.12.6)The text was updated successfully, but these errors were encountered: