diff --git a/coin/instructions/provision.yaml b/coin/instructions/provision.yaml index bbed89c3885..c11325d1375 100644 --- a/coin/instructions/provision.yaml +++ b/coin/instructions/provision.yaml @@ -23,44 +23,41 @@ instructions: ref: master directory: "build/qtsdk" userMessageOnFailure: "Failed to install qtsdk, check logs" - - type: ExecuteCommand - command: "python3 -m pip install pipenv==2022.4.8 --user" - maxTimeInSeconds: 1200 - maxTimeBetweenOutput: 120 - userMessageOnFailure: "Failed to install Pipenv" + - type: InstallSourceArchive + maxTimeInSeconds: 600 + maxTimeBetweenOutput: 600 + project: qtsdk/tqtc-qtsdk + ref: master + directory: "build/tqtc-qtsdk" + userMessageOnFailure: "Failed to install tqtc-qtsdk, check logs" + - type: Group + instructions: + - type: ExecuteCommand + command: python tqtc-qtsdk/jenkins-templates/jenkins/scripts/pkg_bootstrap.py + maxTimeInSeconds: 36000 + maxTimeBetweenOutput: 3600 + userMessageOnFailure: "pkg_bootstrap.py failed" enable_if: - condition: property - property: host.os - in_values: [MacOS, Linux] - - type: ExecuteCommand - command: "python -m pip install pipenv==2022.4.8 --user" - maxTimeInSeconds: 1200 - maxTimeBetweenOutput: 120 - userMessageOnFailure: "Failed to install Pipenv" + condition: and + conditions: + - condition: property + property: host.os + equals_value: Windows + - type: Group + instructions: + - type: ExecuteCommand + command: python3 tqtc-qtsdk/jenkins-templates/jenkins/scripts/pkg_bootstrap.py + maxTimeInSeconds: 36000 + maxTimeBetweenOutput: 3600 + userMessageOnFailure: "pkg_bootstrap.py failed" enable_if: - condition: property - property: host.os - equals_value: Windows + condition: and + conditions: + - condition: property + property: host.os + not_equals_value: Windows - type: ChangeDirectory - directory: "{{.AgentWorkingDir}}/build/qtsdk/packaging-tools" - - type: ExecuteCommand - command: "python3 -m pipenv install --skip-lock" - maxTimeInSeconds: 1200 - maxTimeBetweenOutput: 120 - userMessageOnFailure: "Failed to install requirements from Pipfile" - enable_if: - condition: property - property: host.os - in_values: [MacOS, Linux] - - type: ExecuteCommand - command: "python -m pipenv install --skip-lock" - maxTimeInSeconds: 1200 - maxTimeBetweenOutput: 120 - userMessageOnFailure: "Failed to install requirements from Pipfile" - enable_if: - condition: property - property: host.os - equals_value: Windows + directory: "{{.BuildDir}}/qtsdk/packaging-tools" - type: ExecuteCommand command: "python3 -m pipenv run python -u install_qt.py --qt-path {{.BuildDir}}/qt_install_dir --base-url {{.Env.QTC_QT_BASE_URL}} --base-url-postfix={{.Env.QTC_QT_POSTFIX}} --icu7z http://master.qt.io/development_releases/prebuilt/icu/prebuilt/56.1/icu-linux-g++-Rhel7.2-x64.7z {{.Env.QTC_QT_MODULES}}" executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution diff --git a/dist/changelog/changes-10.0.1.md b/dist/changelog/changes-10.0.1.md new file mode 100644 index 00000000000..a7fcfba973f --- /dev/null +++ b/dist/changelog/changes-10.0.1.md @@ -0,0 +1,105 @@ +Qt Creator 10.0.1 +================= + +Qt Creator version 10.0.1 contains bug fixes. + +The most important changes are listed in this document. For a complete list of +changes, see the Git log for the Qt Creator sources that you can check out from +the public Git repository. For example: + + git clone git://code.qt.io/qt-creator/qt-creator.git + git log --cherry-pick --pretty=oneline origin/v10.0.0..v10.0.1 + +General +------- + +* Enabled example categories for Qt 6.5.1 and later + +Editing +------- + +* Fixed layout issues in the editor toolbar (QTCREATORBUG-28765) + +### C++ + +* Clangd + * Fixed the renaming of macros and namespaces + * Fixed that renaming appended `_new` to the replacement by default + (QTCREATORBUG-28321, QTCREATORBUG-28910) + * Fixed that Cuda files were not passed to Clangd (QTCREATORBUG-28984) +* Clang Format + * Fixed the formatting for advanced C++ (QTCREATORBUG-29033) + * Fixed the updating of the coding style preview (QTCREATORBUG-29043) + * Fixed the indentation of `QML_*` macros (QTCREATORBUG-29086) + +### QML + +* Fixed a crash when trying to open non-existing `.qml` files + (QTCREATORBUG-29021) + +Projects +-------- + +* Re-added a Qt Quick Application wizard that works with Qt 5 and other build + systems than CMake +* Fixed that additional empty lines could be added to files created by wizards + (QTCREATORBUG-29040) + +### CMake + +* Added missing `RUNTIME DESTINATION` properties to the `install` commands of + wizard-generated projects (QTCREATORBUG-28999) +* Fixed that macros were not expanded for all configure cache variables + (QTCREATORBUG-28982) +* Fixed switching from `.c` files to their header (QTCREATORBUG-28991) +* Presets + * Fixed that boolean values for cache variables were interpreted as string + values (QTCREATORBUG-29078) + * Fixed inheritance over multiple levels + (QTCREATORBUG-29076) + +Debugging +--------- + +### Clang + +* Fixed the pretty printers of `std::string` for Clang 15 and later + +Analyzer +-------- + +### Clang + +* Fixed starting Clazy and Clang-Tidy while a build is running + (QTCREATORBUG-29044) + +Platforms +--------- + +### Android + +* Fixed that changes to the `JDK Location` did not take effect immediately + (QTCREATORBUG-28827) +* Fixed debugging on Android Automotive devices (QTCREATORBUG-28851) + +Credits for these changes go to: +-------------------------------- +Alessandro Portale +Artem Sokolovskii +Christian Kandeler +Christian Stenger +Cristian Adam +David Schulz +Eike Ziller +Haowei Hsu +Jaroslaw Kobus +Jussi Witick +Leena Miettinen +Marcus Tillmanns +Orgad Shaneh +Patrik Teivonen +Robert Löhning +Sivert Krøvel +Thiago Macieira +Ulf Hermann +Zoltan Gera diff --git a/doc/qtcreator/images/qtcreator-project-qt-quick.webp b/doc/qtcreator/images/qtcreator-project-qt-quick.webp index 48a83d2dda2..ac329a5c430 100644 Binary files a/doc/qtcreator/images/qtcreator-project-qt-quick.webp and b/doc/qtcreator/images/qtcreator-project-qt-quick.webp differ diff --git a/doc/qtcreator/src/qtquick/creator-only/qtquick-creating.qdoc b/doc/qtcreator/src/qtquick/creator-only/qtquick-creating.qdoc index af5f9ac321b..2c8a4e8e8e1 100644 --- a/doc/qtcreator/src/qtquick/creator-only/qtquick-creating.qdoc +++ b/doc/qtcreator/src/qtquick/creator-only/qtquick-creating.qdoc @@ -75,6 +75,10 @@ \image qtcreator-project-qt-quick.webp {New Project dialog} + \note To use \l qmake as the build system, develop with Qt 5, + or add translations to the application, select + \uicontrol {Qt Quick Application (compat)}. + \li In the \uicontrol {Project Location} dialog, \uicontrol Name field, enter a name for the project. Keep in mind that you cannot easily change the project name later. @@ -93,8 +97,8 @@ \QDS, select \uicontrol {Create a project that you can open in \QDS}. \li In the \uicontrol {Build system} field, select the build system to - use for building and running the project: \l qmake, - \l {Setting Up CMake}{CMake}, or \l {Setting Up Qbs}{Qbs}. + use for building and running the project: \l {Setting Up CMake} + {CMake} or \l {Setting Up Qbs}{Qbs}. \li Select \uicontrol Next to open the \uicontrol {Define Project Details} dialog. diff --git a/doc/qtcreator/src/qtquick/creator-only/qtquick-tutorial-create-empty-project.qdocinc b/doc/qtcreator/src/qtquick/creator-only/qtquick-tutorial-create-empty-project.qdocinc index 5c933d5305d..f01fae3bd8a 100644 --- a/doc/qtcreator/src/qtquick/creator-only/qtquick-tutorial-create-empty-project.qdocinc +++ b/doc/qtcreator/src/qtquick/creator-only/qtquick-tutorial-create-empty-project.qdocinc @@ -30,8 +30,8 @@ {CMake} as the build system to use for building and running the project. - \note If you select \l qmake, the instructions for configuring the - project won't apply. + \note If you select \l {Setting Up Qbs}{Qbs}, the instructions for + configuring the project won't apply. \li Select \uicontrol Next to open the \uicontrol {Define Project Details} dialog. diff --git a/doc/qtcreator/src/widgets/qtdesigner-app-tutorial.qdoc b/doc/qtcreator/src/widgets/qtdesigner-app-tutorial.qdoc index fb0dc11b4bd..1298e81e9f8 100644 --- a/doc/qtcreator/src/widgets/qtdesigner-app-tutorial.qdoc +++ b/doc/qtcreator/src/widgets/qtdesigner-app-tutorial.qdoc @@ -15,8 +15,8 @@ \title Creating a Qt Widget Based Application This tutorial describes how to use \QC to create a small Qt application, - Text Finder. It is a simplified version of the Qt UI Tools \l{Text Finder - Example}. We use \QD to construct the application user interface from + Text Finder. It is a simplified version of the Qt UI Tools \l{Text Finder} + example. You'll use \QD to construct the application user interface from Qt widgets and the code editor to write the application logic in C++. \image qtcreator-textfinder-screenshot.png diff --git a/share/qtcreator/templates/wizards/classes/cpp/file.h b/share/qtcreator/templates/wizards/classes/cpp/file.h index 77f1b213516..ad2b178e8ff 100644 --- a/share/qtcreator/templates/wizards/classes/cpp/file.h +++ b/share/qtcreator/templates/wizards/classes/cpp/file.h @@ -17,6 +17,7 @@ ( '%{IncludeQMainWindow}' ) ? 'QtWidgets/%{IncludeQMainWindow}' : '', ( '%{IncludeQDeclarativeItem}' ) ? 'QtQuick1/%{IncludeQDeclarativeItem}' : '', ( '%{IncludeQQuickItem}' ) ? 'QtDeclarative/%{IncludeQQuickItem}' : '', + ( '%{AddQmlElementMacro}' && !'%{IncludeQQuickItem}' ) ? 'QtQml/QQmlEngine' : '', ( '%{IncludeQSharedData}' ) ? 'QtCore/QSharedDataPointer' : '' ])}\ %{JS: Cpp.openNamespaces('%{Class}')} @if '%{IncludeQSharedData}' diff --git a/share/qtcreator/translations/qtcreator_zh_TW.ts b/share/qtcreator/translations/qtcreator_zh_TW.ts index bf09c6b901e..c1f35c81802 100644 --- a/share/qtcreator/translations/qtcreator_zh_TW.ts +++ b/share/qtcreator/translations/qtcreator_zh_TW.ts @@ -5512,7 +5512,7 @@ Add, modify, and remove document filters, which determine the documentation set Hide Sidebar - 隱藏邊列 + 隱藏側邊條 Increase Font Size @@ -13006,11 +13006,11 @@ For qmlproject projects, use the importPaths property to add import paths. Toggle &Left Sidebar - 切換左邊欄(&L) + 切換左側邊條(&L) Toggle &Right Sidebar - 切換右邊欄(&R) + 切換右側邊條(&R) Projects @@ -14917,11 +14917,11 @@ Ids must begin with a lowercase letter. Hide Sidebar - 隱藏邊列 + 隱藏側邊條 Show Sidebar - 顯示邊列 + 顯示側邊條 @@ -15671,7 +15671,7 @@ instead of its installation directory when run outside git bash. QtC::Help Show Sidebar - 顯示邊列 + 顯示側邊條 Qt Creator Offline Help diff --git a/src/plugins/cppeditor/cppeditorwidget.cpp b/src/plugins/cppeditor/cppeditorwidget.cpp index 20fe8e6254b..0430f210a0b 100644 --- a/src/plugins/cppeditor/cppeditorwidget.cpp +++ b/src/plugins/cppeditor/cppeditorwidget.cpp @@ -1267,20 +1267,16 @@ std::unique_ptr CppEditorWidget::createAssistInterface(AssistKi if (cap) return cap->createAssistInterface(textDocument()->filePath(), this, getFeatures(), reason); - else { - if (isOldStyleSignalOrSlot()) - return CppModelManager::instance() - ->completionAssistProvider() - ->createAssistInterface(textDocument()->filePath(), this, getFeatures(), reason); - return TextEditorWidget::createAssistInterface(kind, reason); + + if (isOldStyleSignalOrSlot()) { + return CppModelManager::instance() + ->completionAssistProvider() + ->createAssistInterface(textDocument()->filePath(), this, getFeatures(), reason); } - } else if (kind == QuickFix) { - if (isSemanticInfoValid()) - return std::make_unique(const_cast(this), reason); - } else { - return TextEditorWidget::createAssistInterface(kind, reason); } - return nullptr; + if (kind == QuickFix && isSemanticInfoValid()) + return std::make_unique(const_cast(this), reason); + return TextEditorWidget::createAssistInterface(kind, reason); } QSharedPointer CppEditorWidget::declDefLink() const diff --git a/src/plugins/cppeditor/cppquickfixassistant.cpp b/src/plugins/cppeditor/cppquickfixassistant.cpp index 89af86e334c..19514387d71 100644 --- a/src/plugins/cppeditor/cppquickfixassistant.cpp +++ b/src/plugins/cppeditor/cppquickfixassistant.cpp @@ -149,7 +149,8 @@ QTextCursor CppQuickFixInterface::adjustedCursor() QuickFixOperations quickFixOperations(const TextEditor::AssistInterface *interface) { const auto cppInterface = dynamic_cast(interface); - QTC_ASSERT(cppInterface, return {}); + if (!cppInterface) + return {}; QuickFixOperations quickFixes; for (CppQuickFixFactory *factory : CppQuickFixFactory::cppQuickFixFactories()) factory->match(*cppInterface, quickFixes); diff --git a/src/plugins/genericprojectmanager/genericproject.cpp b/src/plugins/genericprojectmanager/genericproject.cpp index 518b765bcb2..fbe77e74a9f 100644 --- a/src/plugins/genericprojectmanager/genericproject.cpp +++ b/src/plugins/genericprojectmanager/genericproject.cpp @@ -330,8 +330,9 @@ bool GenericBuildSystem::addFiles(Node *, const FilePaths &filePaths_, FilePaths QSet toAdd; for (const QString &filePath : filePaths) { - const QString directory = QFileInfo(filePath).absolutePath(); - if (!includes.contains(directory)) + const QFileInfo fi(filePath); + const QString directory = fi.absolutePath(); + if (fi.fileName() == "include" && !includes.contains(directory)) toAdd << directory; } diff --git a/src/plugins/genericprojectmanager/genericprojectwizard.cpp b/src/plugins/genericprojectmanager/genericprojectwizard.cpp index 27d2a3932b5..1f125ff321c 100644 --- a/src/plugins/genericprojectmanager/genericprojectwizard.cpp +++ b/src/plugins/genericprojectmanager/genericprojectwizard.cpp @@ -141,6 +141,8 @@ Core::GeneratedFiles GenericProjectWizard::generateFiles(const QWizard *w, const QDir dir(projectPath.toString()); for (const QString &path : paths) { QFileInfo fileInfo(path); + if (fileInfo.fileName() != "include") + continue; QDir thisDir(fileInfo.absoluteFilePath()); if (! thisDir.entryList(nameFilters, QDir::Files).isEmpty()) { diff --git a/src/plugins/qmljseditor/qmljseditor.cpp b/src/plugins/qmljseditor/qmljseditor.cpp index 590ef1da581..ccc94a5ea42 100644 --- a/src/plugins/qmljseditor/qmljseditor.cpp +++ b/src/plugins/qmljseditor/qmljseditor.cpp @@ -1042,7 +1042,7 @@ std::unique_ptr QmlJSEditorWidget::createAssistInterface( return std::make_unique( const_cast(this), reason); } - return nullptr; + return TextEditorWidget::createAssistInterface(assistKind, reason); } QString QmlJSEditorWidget::foldReplacementText(const QTextBlock &block) const diff --git a/src/plugins/texteditor/codeassist/codeassistant.cpp b/src/plugins/texteditor/codeassist/codeassistant.cpp index 34ba897d8db..b3d9d477e24 100644 --- a/src/plugins/texteditor/codeassist/codeassistant.cpp +++ b/src/plugins/texteditor/codeassist/codeassistant.cpp @@ -175,8 +175,7 @@ void CodeAssistantPrivate::requestProposal(AssistReason reason, std::unique_ptr assistInterface = m_editorWidget->createAssistInterface(kind, reason); - if (!assistInterface) - return; + QTC_ASSERT(assistInterface, return); // We got an assist provider and interface so no need to reset the current context anymore earlyReturnContextClear.reset({}); @@ -395,8 +394,10 @@ void CodeAssistantPrivate::notifyChange() if (m_editorWidget->position() < m_proposalWidget->basePosition()) { destroyContext(); } else { - m_proposalWidget->updateProposal( - m_editorWidget->createAssistInterface(m_assistKind, m_proposalWidget->reason())); + std::unique_ptr assistInterface + = m_editorWidget->createAssistInterface(m_assistKind, m_proposalWidget->reason()); + QTC_ASSERT(assistInterface, destroyContext(); return); + m_proposalWidget->updateProposal(std::move(assistInterface)); if (!isDisplayingProposal()) requestActivationCharProposal(); } diff --git a/src/shared/qbs b/src/shared/qbs index e002680feb4..03e717b06ed 160000 --- a/src/shared/qbs +++ b/src/shared/qbs @@ -1 +1 @@ -Subproject commit e002680feb415ee7d26e3a31d70afeef0d50dea2 +Subproject commit 03e717b06ed5c0864618e763f08f91d9fc94b733 diff --git a/tests/auto/qml/persistenttrie/persistenttrie.qbs b/tests/auto/qml/persistenttrie/persistenttrie.qbs index 9f03227ee7c..0d6490a5b6b 100644 --- a/tests/auto/qml/persistenttrie/persistenttrie.qbs +++ b/tests/auto/qml/persistenttrie/persistenttrie.qbs @@ -5,7 +5,6 @@ QtcAutotest { Depends { name: "QmlJS" } files: [ "tst_testtrie.h", "tst_testtrie.cpp" ] cpp.defines: base.concat([ - 'QMLJS_LIBRARY', 'QTCREATORDIR="' + project.ide_source_tree + '"', 'TESTSRCDIR="' + path + '"' ]) diff --git a/tests/system/shared/project.py b/tests/system/shared/project.py index 06c7e115e38..babbf0eb6ea 100644 --- a/tests/system/shared/project.py +++ b/tests/system/shared/project.py @@ -544,6 +544,7 @@ def checkAndCopyFiles(dataSet, fieldName, templateDir): files = map(lambda record: os.path.normpath(os.path.join(srcPath, testData.field(record, fieldName))), dataSet) + files = list(files) # copy data from map object to list to make it reusable for currentFile in files: if not neededFilePresent(currentFile): return [] diff --git a/tests/system/shared/utils.py b/tests/system/shared/utils.py index 7397fad5ed6..96e63f29f05 100644 --- a/tests/system/shared/utils.py +++ b/tests/system/shared/utils.py @@ -513,8 +513,13 @@ def progressBarWait(timeout=60000, warn=True): checkIfObjectExists(":Qt Creator_Core::Internal::ProgressBar", False, timeout) def readFile(filename): - with open(filename, "r") as f: - return f.read() + try: + with open(filename, "r") as f: + return f.read() + except: + # Read file as binary + with open(filename, "rb") as f: + return f.read() def simpleFileName(navigatorFileName): # try to find the last part of the given name, assume it's inside a (folder) structure diff --git a/tests/system/suite_editors/tst_clean_whitespaces/test.py b/tests/system/suite_editors/tst_clean_whitespaces/test.py index cdf2add27c4..6dab4720f9e 100644 --- a/tests/system/suite_editors/tst_clean_whitespaces/test.py +++ b/tests/system/suite_editors/tst_clean_whitespaces/test.py @@ -12,7 +12,7 @@ TripleTab = '\t\t\t' def main(): files = map(lambda record: os.path.join(srcPath, testData.field(record, "filename")), testData.dataset("files.tsv")) - files = filter(lambda x: not x.endswith(".bin"), files) + files = list(filter(lambda x: not x.endswith(".bin"), files)) for currentFile in files: if not neededFilePresent(currentFile): return diff --git a/tests/system/suite_editors/tst_select_all/test.py b/tests/system/suite_editors/tst_select_all/test.py index be96e8f4823..bf95250cf77 100644 --- a/tests/system/suite_editors/tst_select_all/test.py +++ b/tests/system/suite_editors/tst_select_all/test.py @@ -8,7 +8,7 @@ source("../../shared/qtcreator.py") def main(): files = map(lambda record: os.path.join(srcPath, testData.field(record, "filename")), testData.dataset("files.tsv")) - files = filter(lambda x: not x.endswith(".bin"), files) + files = list(filter(lambda x: not x.endswith(".bin"), files)) for currentFile in files: if not neededFilePresent(currentFile): return