aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* libshiboken6: Add warnings for conversion errorsFriedemann Kleint2025-05-161-2/+11
| | | | | | | | | | | | Add warnings for: - Copy conversion Python to C++ is requested, but no copy conversion functions are registered. - Pointer conversion of non-SbkObject was requested, which falls back to pass through. Task-number: PYSIDE-2193 Change-Id: Id5c9d82c981bc63156187593da3593237186adba Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Fix some warnings in testsFriedemann Kleint2025-05-164-19/+20
| | | | | | | | | Fix exec_ and deprecated QMenu.addAction() overloads. Fix warnings about inactive QPainter in bug_919.py. Pick-to: 6.9 Change-Id: I483190480ca5b467bd070c3239f78166e6de3a51 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Add changelog 6.9.1Friedemann Kleint2025-05-161-0/+56
| | | | | | Pick-to: 6.9 Change-Id: I70ce0113dcbfcfa5e9849cd0fd112246f8de86c3 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* type hints: Fix QInputDialog get methodsEce Cinucen2025-05-151-0/+5
| | | | | | | | | | | QInputDialog.get* methods should accept None as parent Fixes: PYSIDE-3078 Pick-to: 6.8 6.9 Change-Id: I5e6889800040a44649f99e1e7f95ab07e127c550 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* type hints: Improve topological sorting between Sequence and IterableChristian Tismer2025-05-141-1/+7
| | | | | | | | | | | | | | | | Sorting between Sequence and Iterable defaulted to alphabetical. For an order of generality, the sorting order needs to be defined. The reason for this was a problem with the 6.10 branch of PySide which has enhanced NumPy support. Note that this re-ordering of Sequence and Iterable is for PYI files, only. The NumPy support code has completely different needs for sorting that is unrelated. Task-number: PYSIDE-3098 Change-Id: I2325d4c0a7aa6dbac8337a03e466d992ada5cb06 Pick-to: 6.8 6.9 Reviewed-by: Ece Cinucen <ece.cinucen@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* libpyside: Make PyObjectWrapper movableFriedemann Kleint2025-05-132-2/+14
| | | | | | | | | This is required by today's QVariant conversion code. Task-number: PYSIDE-2193 Pick-to: 6.9 Change-Id: I66efcfb797653fe1d617f1f0027fd60ec95e8a79 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* CI: Use Python 3.10 instead of 3.8 on Win x86_64Simo Fält2025-05-131-0/+12
| | | | | | | Pick-to: 6.9 Change-Id: I61bb4b1963c5ba27bd3d19f97378cedf6608aefb Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Ece Cinucen <ece.cinucen@qt.io>
* type hints: Correct the collections import in the pyi filesEce Cinucen2025-05-121-1/+1
| | | | | | | | | Amends 00a5b350ec3d6f552ad0753d9c8fdbde4464d9ad. Fixes: PYSIDE-3092 Pick-to: 6.8 6.9 Change-Id: Ibc44e51342f926353795005137da802973ad67cd Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Example: Port qtcharts audio example to qtgraphsEce Cinucen2025-05-126-0/+143
| | | | | | | | Task-number: PYSIDE-841 Pick-to: 6.8 6.9 Change-Id: Id8a81c06078c147eb50f1f1d688841e8a6bab18b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Fix pyside6-project relative paths handling and pyproject.toml migrationJaime Resano2025-05-095-29/+72
| | | | | | | | | | | | | | | | | | | | | This patch fixes two existing bugs in the pyside6-project tool: 1. Relative file paths outside the project folder in the .pyproject file e.g. files = ["../main.py"] are not handled correctly. A ValueError is raised due to the usage of Path.relative_to Fixed using a new function: robust_relative_to_posix() Updated the example_project test to contain this edge case (Suggestion: use this as a replacement for the rel_path() function located in tools/example_gallery/main.py) 2. The migration of a .pyproject to a pyproject.toml file with existing content is not done properly due to removing the tomlkit implementation. Fixed by appending the [tool.pyside6-project] section (and the [project] section too) at the end of the file (I don't know how the tests were passing before ??) Change-Id: Ie061c9fa172c429c8b45381bbec35ad30d01f4ee Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Fix crash retrieving a QGraphicsProxyObject from QVariantFriedemann Kleint2025-05-095-2/+62
| | | | | | | | | | | | | | | | | | Remove the default-superclass specification QGraphicsItem for QGraphicsObject since it causes the type discovery to directly cast from QGraphicsObject* to QGraphicsItem*. This crashes since QGraphicsObject inherits from QObject as first base class. The intention of the class attribute was to ensure that any QGraphicsObject class is stored as a QGraphicsItem. To preserve this, hardcode it in QVariant_resolveMetaType(). Pick-to: 6.9 Fixes: PYSIDE-3069 Task-number: PYSIDE-86 Task-number: PYSIDE-1887 Change-Id: I3704988f105b118b1e4ef8d078b68c01ba89386c Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* shiboken6/Documentation: Fix wrong code snippetsFriedemann Kleint2025-05-091-2/+2
| | | | | | | | | The snippets for the method call are flipped. Pick-to: 6.9 6.8 Change-Id: I8b571c51d6d82391f4bcfca45fd3f9892bfb688a Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> Reviewed-by: Ece Cinucen <ece.cinucen@qt.io>
* shiboken6: Add code injection for the wrapper declarationFriedemann Kleint2025-05-094-75/+84
| | | | | | | | | | | [ChangeLog][shiboken6] It is now possible to inject code into the the wrapper class declaration, which can be used to import base class members via the "using" keyword. Task-number: PYSIDE-3011 Change-Id: Iaf205c16aecd789ea39817999c4eb74e5005c2c3 Reviewed-by: Ece Cinucen <ece.cinucen@qt.io> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Documentation: Recommend using a Dev Drive on WindowsFriedemann Kleint2025-05-091-2/+9
| | | | | | Pick-to: 6.9 6.8 Change-Id: I2004096735d0a5852eeca23176e25ffd30a6fe4c Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* libshiboken: Move override name calculation into basewrapperFriedemann Kleint2025-05-074-20/+32
| | | | | | Task-number: PYSIDE-2916 Change-Id: I4e4619b5144451512be3eadc6810df3f3f47ada0 Reviewed-by: Christian Tismer <tismer@stackless.com>
* libshiboken: Add utility class for stashing Python errorsFriedemann Kleint2025-05-0711-58/+106
| | | | | | | | | It encapsulates fetching/restoring errors and uses the old or new exception API depending on version. Task-number: PYSIDE-3067 Change-Id: I6e39d92c7e79fed864b364a90c5bd5b474a41ed6 Reviewed-by: Christian Tismer <tismer@stackless.com>
* libshiboken: Use PyErr_SetRaisedException() for unraisable exceptionsFriedemann Kleint2025-05-071-11/+38
| | | | | | | | | | | Complements baedbe8353ee20eb7ac98e67b7985eb80959f14f. Task-number: PYSIDE-3067 Task-number: PYSIDE-2310 Task-number: PYSIDE-2321 Task-number: PYSIDE-2335 Change-Id: Ie55a89eab0743b25095cab56d38ce321ce5a0131 Reviewed-by: Christian Tismer <tismer@stackless.com>
* CI: Fix filetype of artifacts archiveSimo Fält2025-05-071-1/+1
| | | | | | | | The compression of artifacts was changed in COIN. Pick-to: 6.9 6.8 Change-Id: I2cee55323583b0893607279390be7671a35d9876 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Improve example_gallery scriptJaime Resano2025-05-041-332/+340
| | | | | | | | | | | | | | | | Changes: - Fix unnecessary ../ in some file names of certain examples which have the .pyproject file in the doc directory. e.g. widget binding example - Add .html code highlighting to the code snippets - Fix file docstring (__doc__) Refactoring: - Add type hints to functions - General code clean up Change-Id: Iaebabf10f59aa515613566256a94bece65b4ffd3 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* libshiboken: Introduce define for old PyErr_ APIFriedemann Kleint2025-05-022-5/+10
| | | | | | | | | | | The triple arguments functions PyErr_Fetch/PyErr_Restore() were replaced by PyErr_Get/SetRaisedException() in 3.12, which was added to the stable API for 3.13. Introduce a define PEP_OLD_ERR_API for the old functions. Task-number: PYSIDE-3067 Change-Id: I57378299a48ba4884ed6304db6bc681e4e5d196b Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Fix unused variable warning in QVariant conversionFriedemann Kleint2025-05-021-3/+1
| | | | | | | | Amends caa9d339c3ba96879ae5972b08787506ec36d92b. Task-number: PYSIDE-3084 Change-Id: I17c70441e050b713edca8f3f31ebc8c6bf251bba Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Allow for building with Clang 14 (Yocto)Friedemann Kleint2025-04-303-1/+22
| | | | | | | | | | | | | | | Replace clang functions clang_CXXMethod_isCopyAssignmentOperator() and clang_CXXMethod_isMoveAssignmentOperator() by a manual check function depending on clang version. Amends 6410710ab9580f71ab58ac38e67d74bbde5dbce4. Complements b887919ea244a057f15be9c1cdc652538e3fe9a0. Fixes: PYSIDE-3091 Task-number: PYSIDE-3004 Pick-to: 6.9 Change-Id: I18b073e7fe572ffe8b4635a26cec45b0b6adbac3 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* shiboken6: Rephrase documentation of the default-superclass attributeFriedemann Kleint2025-04-281-3/+6
| | | | | | | | | | | Mention that it needs to be a direct base class. Pick-to: 6.9 6.8 Task-number: PYSIDE-3069 Task-number: PYSIDE-86 Task-number: PYSIDE-1887 Change-Id: I7e153bd839ba600d98993d24cfcc40feb0299849 Reviewed-by: Christian Tismer <tismer@stackless.com>
* Fix pyside6-metaobjectdump crash when using @Slot(result=None)Jaime Resano2025-04-251-1/+3
| | | | | | | | | | | | | This patch fixes a crash of the pyside6-metaobjectdump tool run in a file that contains a @Slot(result=None) decorator. The fix contains in improving the existing _name function to handle ast.Constant nodes. Fixes: PYSIDE-3089 Pick-to: 6.9 Change-Id: Id006898021efbc2cc0f9a48f2ce5ac94fcef1836 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Remove dependency on tomlkitShyamnath Premnadh2025-04-242-47/+96
| | | | | | | | | | | | | - Since we only needed parsing and since the pyproject.toml only contained two sections relevant for deployment/project tool, we can remove the dependency of tomlkit and replace it with simple function doing the parsing and writing of the pyproject.toml Pick-to: 6.8 6.9 Fixes: PYSIDE-3087 Change-Id: Idff951578f7bab311d8bc469c1d437b022ca475a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* PySide6/type system: Remove obsolete "since" attributesFriedemann Kleint2025-04-235-88/+88
| | | | | | Pick-to: 6.9 Change-Id: I184a939af6814a04f76f1047217bc9736143bd74 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* libshiboken: Refactor BindingManager::getOverride()Friedemann Kleint2025-04-231-47/+33
| | | | | | | | Introduce AutoDecRef to simplify the code. Task-number: PYSIDE-2916 Change-Id: I1ee65f6349d112fd82a2f9a0e35ba84b74506d5d Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Fix QMetaEnum conversions into QVariantRenato Araujo Oliveira Filho2025-04-238-19/+49
| | | | | | | | | Make sure to store QtEnums in QVariant when the enum has a metatype. Fixes: PYSIDE-3084 Change-Id: I94b89f89e6fb3c58560325f2a6843a5260d86557 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* type-hints: Fix properties on __init__ functionsEce Cinucen2025-04-231-1/+5
| | | | | | | | | | | When the variable name from constructor and the properties are the same, one overwrites the other. This is fixed by omitting the name from the property. Fixes: PYSIDE-3007 Fixes: PYSIDE-3012 Fixes: PYSIDE-3029 Pick-to: 6.8 6.9 Change-Id: I309bc1a808907981d2d624c7491e6ef18e8087e3 Reviewed-by: Christian Tismer <tismer@stackless.com>
* Fix crash when entering a Qt message handler with a Python error setFriedemann Kleint2025-04-231-0/+5
| | | | | | | | | | Stash and restore the Python errors in the message handler. Fixes: PYSIDE-3067 Pick-to: 6.9 6.8 6.5 Change-Id: If0d8ec08f939dae6c4d6bd33a0b15f9a21d740af Reviewed-by: Ece Cinucen <ece.cinucen@qt.io> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Fix building of .pyi files for Windows debugFriedemann Kleint2025-04-171-4/+7
| | | | | | | | | | | | | | Port an incomprehensible list comprehension to pathlib and strip the "_d" debug prefix from the file name. Amends 3d9e42f33fad5b2eeee62d3eced1c69aa7f35fff. Fixes: PYSIDE-3061 Task-number: PYSIDE-1890 Task-number: PYSIDE-2895 Pick-to: 6.9 6.8 Change-Id: I2989ec411ae73790515ac282a2c3eccc7d222c97 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* PySide/Signal manager: Fix corruption when connecting to temporary objectFriedemann Kleint2025-04-171-0/+1
| | | | | | | | | | | | | Guard the deletion tracker listening on QObject::destroyed() using GIL. Amends 33bd61d13d8d9e3794b6049891be62f3351313d9. Fixes: PYSIDE-3072 Task-number: PYSIDE-2810 Task-number: PYSIDE-2221 Pick-to: 6.9 6.8 Change-Id: Ia085fa551903dd39c7a9624f6995d8720e9f7fb0 Reviewed-by: Ece Cinucen <ece.cinucen@qt.io> Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Expose QPolygonF operator==, != inherited from QListRenato Araujo Oliveira Filho2025-04-162-0/+17
| | | | | | | | These operators were missing. Change based on QPolygon fix Change-Id: I8d0a4846f91aac1e2dfa1817ec6d15903519e819 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* CI: Use master.qt.io instead of mirror for downloading libclangSimo Fält2025-04-162-2/+2
| | | | | | Pick-to: 6.9 Change-Id: I8cc018ef70f453be97b34f2aadcaf56118ca42f0 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* shiboken6: Fix invalid function parameters caused by lambdas in inline codeFriedemann Kleint2025-04-161-2/+6
| | | | | | | | | Exclude all expressions and statements. Fixes: PYSIDE-3081 Pick-to: 6.9 6.8 Change-Id: I6178624ad7415b6320b7e86b9a10d4869fc1c687 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Replace Py_GetProgramFullPath by PySys_GetObjectCristián Maureira-Fredes2025-04-101-1/+1
| | | | | | | | | Py_GetProgramFullPath is deprecated from 3.13 and the recommendation is to use PySys_GetObject("executable") instead. Pick-to: 6.9 Change-Id: Ia0b0424d6fe593343272d862b05727579fad2a86 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Replace strncpy by memcpyCristián Maureira-Fredes2025-04-101-1/+2
| | | | | | | | Avoid a warning while building. Pick-to: 6.9 Change-Id: I4064c730bed07156027dd1bd0688622941286090 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Deployment: Rephrase a warning messageShyamnath Premnadh2025-04-101-2/+2
| | | | | | | | | | | - The error in the specific warning message leads to confusion. This should now be fixed by rephrasing the message to be more clear. Pick-to: 6.9 Task-number: PYSIDE-1612 Change-Id: I2cb3b6b33bd05efe60a54e722a6b626fae7bd1e7 Reviewed-by: Ece Cinucen <ece.cinucen@qt.io> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* PySide6: Add class QMessageLoggerShyamnath Premnadh2025-04-106-0/+160
| | | | | | | | | | | | | | | - Also add documentation with a minimal example showing the use case of QMessageLogger in Python. [ChangeLog][PySide6] Added QMessageLogger class to handle debug, info, warning, critical, and fatal messages, including support for QLoggingCategory. Task-number: PYSIDE-3052 Pick-to: 6.9 6.8 Change-Id: Iaaf586288de4aaccf01d1e6547df9a2f478a7c8c Reviewed-by: Ece Cinucen <ece.cinucen@qt.io> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Use QT_CONFIG when possibleCristián Maureira-Fredes2025-04-073-5/+5
| | | | | | | | | | A few places were still using the double negation on a couple of Qt configuration options. Pick-to: 6.9 Change-Id: Id182e7a3958af21368cb890e645dc4a2902f8260 Reviewed-by: Ece Cinucen <ece.cinucen@qt.io> Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* qtasyncio: fix f-string quotationCristián Maureira-Fredes2025-04-071-2/+2
| | | | | | | | | | | Considering we still support old Python versions, we cannot have the same quotation mark for f-string and for variables within the f-string. Fixes: PYSIDE-3068 Pick-to: 6.8 6.9 6.9.0 Change-Id: Ie9f1ed91f1a1965631bc71f35600780bb4f00603 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* build: drop license from classifiersCristián Maureira-Fredes2025-04-041-4/+0
| | | | | | | | | Using the SPDX codes in pyproject.toml allow us to drop the classifiers about licenses. Pick-to: 6.9 6.8 6.5 6.2 Change-Id: Ia2e75012ff8ae707ef2fef6eb5cfcce43fe87f75 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* type-hints: Correct QMessagebox annotationsEce Cinucen2025-04-041-10/+30
| | | | | | | | | parent parameter of about, aboutQt, critical, information, question, and warning changed to Optional[QWidget]. Fixes: PYSIDE-3021 Pick-to: 6.8 6.9 Change-Id: I31e556933f25f6c21e18debb274db6a13ffbe2ed Reviewed-by: Christian Tismer <tismer@stackless.com>
* doc: Fix unclosed command formattingJaime Resano2025-04-041-1/+1
| | | | | | | | | | | | | | Currently there is an unclosed backtick (`) which shows the following error while building the documentation: sources\pyside6\doc\building_from_source/macOS.rst:77: WARNING: Inline interpreted text or phrase reference start-string without end-string. This patch fixes the issue. Pick-to: 6.9 Change-Id: I37ae34ca12e249e219ae765f121ee2f1bb2d371c Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* doc: Fix broken ref: "parent"Jaime Resano2025-04-031-2/+2
| | | | | | | | | | | | | | | The :ref:`parent` is currently broken and showing an error during the generation of the documentation files: sources\shiboken6\doc\typesystem_arguments.rst:192: WARNING: undefined label: 'parent' This patch fixes the issue. Change-Id: Ib3cc8ec010c9ccf1dc44fd129705ac13576f026e Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io> Reviewed-by: Jaime Resano <gemailpersonal02@gmail.com> Reviewed-by: Ece Cinucen <ece.cinucen@qt.io>
* doc: Add remoteobjects/modelview screenshotJaime Resano2025-04-031-0/+0
| | | | | | | | | | | | | | | Currently, the example docs refer to a non-existent image and the following error is shown: sources\pyside6\doc\examples\example_remoteobjects_modelview.rst:11: WARNING: image file not readable: examples/modelview.png This patch adds a screenshot of the application. Change-Id: I163fd68431e7ae87cb015cc49d75577a56f88969 Reviewed-by: Ece Cinucen <ece.cinucen@qt.io> Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io> Reviewed-by: Jaime Resano <gemailpersonal02@gmail.com>
* type hints: Correct type signature for QObject classEce Cinucen2025-04-031-0/+3
| | | | | | | | | connect, disconnect and receivers functions accept input str instead of byte Fixes: PYSIDE-3059 Pick-to: 6.8 6.9 Change-Id: I41eacdc4386fe5e9e6e83e73299fb99c474cd73d Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* type hints: Correct type signature for Property classEce Cinucen2025-04-031-4/+4
| | | | | | | | Task-number: PYSIDE-3012 Pick-to: 6.8 6.9 Change-Id: I720dd730f6dd28ae33a6019494b7b67b8f704a10 Reviewed-by: Christian Tismer <tismer@stackless.com> Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* build: fix author metadata for cross compiled wheelsCristián Maureira-Fredes2025-03-271-3/+3
| | | | | | Pick-to: 6.8 6.9 Change-Id: Iabc55c386790bd9fda8ad56589951ac8c8d3bcea Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Android Building: Fix error in macOSShyamnath Premnadh2025-03-271-9/+2
| | | | | | | | | | | | - When building the macOS wheel locally, there was an error that the Android NDK path prefix was repeated causing the path not to be found. This patch fixes this error. - Additionally simplify some code. Pick-to: 6.8 6.9 Task-number: PYSIDE-1612 Change-Id: Ifce51e6e84c5ab51e03a11c6766a652e3784b32b Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>