aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2022-08-17 03:01:04 +0000
committerQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2022-08-17 03:01:04 +0000
commit54a301d83910a760ff7f7aa5bea1e3c3d7226bc8 (patch)
tree308551b320478f20afbb28f06b2ced1b96ea4758
parentfb2b6694b8a405bf9d3d1b1b0f3cf0e643806b7a (diff)
parentee6e659a483d11b4e77dbb1c66d7dc314e0864b1 (diff)
Merge branch 6.3 into wip/6.3_pypy
-rw-r--r--doc/changelogs/changes-6.3.256
-rw-r--r--sources/pyside6/libpyside/signalmanager.cpp6
-rw-r--r--tools/snippets_translate/handlers.py7
-rw-r--r--tools/snippets_translate/tests/test_converter.py1
4 files changed, 67 insertions, 3 deletions
diff --git a/doc/changelogs/changes-6.3.2 b/doc/changelogs/changes-6.3.2
new file mode 100644
index 000000000..18573e329
--- /dev/null
+++ b/doc/changelogs/changes-6.3.2
@@ -0,0 +1,56 @@
+Qt for Python 6.3.2 is a bug-fix release.
+
+For more details, refer to the online documentation included in this
+distribution. The documentation is also available online:
+
+https://doc.qt.io/qtforpython/
+
+Some of the changes listed in this file include issue tracking numbers
+corresponding to tasks in the Qt Bug Tracker:
+
+https://bugreports.qt.io/
+
+Each of these identifiers can be entered in the bug tracker to obtain more
+information about a particular change.
+
+****************************************************************************
+* PySide6 *
+****************************************************************************
+
+ - [PYSIDE-1735] The duplication of enum values into the enclosing scope,
+ allowing to write Qt.AlignLeft instead of Qt.Alignment.AlignLeft,
+ is now implemented differently and no longer advertized in PYI
+ files or line completion.
+ - [PYSIDE-1735] The new Python enums are made as compatible to the old ones
+ as possible. It is again allowed to use Qt.Alignment()
+ instead of Qt.AlignmentFlag(0), and a default of 0 is
+ always allowed but also not advertized.
+ - [PYSIDE-1735] Most former IntEnum/IntFlag are replaced by pure Enum/Flag
+ classes in a generally compatible way to other implementations.
+ - [PYSIDE-1735] Python Enums use the newest implementation for Python (3.10)
+ for compatibility and speed.
+ - [PYSIDE-1735] A weird build problem on macOS and other platforms was fixed.
+ - [PYSide-1735] The cleanup calls by were sped up by using PyName for
+ staticMetaObject.
+ - [PYSIDE-1930] Returning enums from QAbstractItemModel.flags() and
+ QAbstractItemModel.data() has been fixed.
+ - [PYSIDE-1934] The type hinting for the return value of
+ QListWidget.selected_indexes() has been fixed.
+ - [PYSIDE-1960] Initial support for Python 3.11 has been added.
+ - [PYSIDE-1968] The signature of QPixmap.save() has been fixed.
+ - [PYSIDE-1978] The signal
+ QAbstractItemModel.layoutAboutToBeChanged(QList<QPersistentModelIndex>)
+ has been fixed.
+ Also, the error message about using the wrong signal overload
+ has been improved.
+ - [PYSIDE-2019] Crashes related to QtDataVisualization'QValue3DAxisFormatter
+ have been fixed
+
+****************************************************************************
+* Shiboken6 *
+****************************************************************************
+
+ - [PYSIDE-1964] The error message about mistakenly using keyword arguments
+ has been improved.
+ - [PYSIDE-1988] Fixed a mistaken PySequence_Check() type check to be
+ PyTuple_Check(), which only showed in Python 3.11.
diff --git a/sources/pyside6/libpyside/signalmanager.cpp b/sources/pyside6/libpyside/signalmanager.cpp
index 67302beab..ce4283fda 100644
--- a/sources/pyside6/libpyside/signalmanager.cpp
+++ b/sources/pyside6/libpyside/signalmanager.cpp
@@ -413,8 +413,12 @@ int SignalManager::SignalManagerPrivate::qtPropertyMetacall(QObject *object,
pp->d->metaCall(pySelf, call, args);
Py_XDECREF(pp);
- if (PyErr_Occurred())
+ if (PyErr_Occurred()) {
+ qWarning().noquote().nospace()
+ << "An error occurred executing the property metacall " << call
+ << " on property \"" << mp.name() << "\" of " << object;
handleMetaCallError(object, &result);
+ }
return result;
}
diff --git a/tools/snippets_translate/handlers.py b/tools/snippets_translate/handlers.py
index 6ededfc06..40ba71841 100644
--- a/tools/snippets_translate/handlers.py
+++ b/tools/snippets_translate/handlers.py
@@ -516,10 +516,13 @@ def handle_methods_return_type(x):
def handle_functions(x):
- re_capture = re.compile(r"^ *[a-zA-Z0-9]+ ([\w\*\&]+\(.*\)$)")
+ re_capture = re.compile(r"^ *([a-zA-Z0-9]+) ([\w\*\&]+\(.*\)$)")
capture = re_capture.search(x)
if capture:
- content = capture.group(1)
+ return_type = capture.group(1)
+ if return_type == "return": # "return QModelIndex();"
+ return x
+ content = capture.group(2)
function_name = content.split("(")[0]
re_par = re.compile(r"\((.+)\)")
par_capture = re_par.search(x)
diff --git a/tools/snippets_translate/tests/test_converter.py b/tools/snippets_translate/tests/test_converter.py
index 84e266f41..b2d6468d8 100644
--- a/tools/snippets_translate/tests/test_converter.py
+++ b/tools/snippets_translate/tests/test_converter.py
@@ -367,6 +367,7 @@ def test_functions():
st("QString myDecoderFunc(const QByteArray &localFileName);")
== "def myDecoderFunc(localFileName):"
)
+ assert st("return QModelIndex();") == "return QModelIndex()"
def test_foreach():