Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package kf6-kcrash for openSUSE:Leap:16.0 checked in at 2025-04-23 10:08:32 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Leap:16.0/kf6-kcrash (Old) and /work/SRC/openSUSE:Leap:16.0/.kf6-kcrash.new.30101 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "kf6-kcrash" Wed Apr 23 10:08:32 2025 rev:3 rq:1271447 version:6.13.0 Changes: -------- --- /work/SRC/openSUSE:Leap:16.0/kf6-kcrash/kf6-kcrash.changes 2025-03-19 11:47:49.252505499 +0100 +++ /work/SRC/openSUSE:Leap:16.0/.kf6-kcrash.new.30101/kf6-kcrash.changes 2025-04-23 10:11:32.443471992 +0200 @@ -1,0 +2,78 @@ +Sat Apr 5 12:32:58 UTC 2025 - Christophe Marin <christo...@krop.fr> + +- Update to 6.13.0 + * New feature release + * For more details please see: + * https://kde.org/announcements/frameworks/6/6.13.0 +- Changes since 6.12.0: + * It compiles fine without qt6.9 deprecated methods + * It compiles fine without kf6.12 deprecated methods + * Update dependency version to 6.13.0 + +------------------------------------------------------------------- +Tue Mar 11 09:29:12 UTC 2025 - Christophe Marin <christo...@krop.fr> + +- Update to 6.12.0 + * New feature release + * For more details please see: + * https://kde.org/announcements/frameworks/6/6.12.0 +- Changes since 6.11.0: + * Update dependency version to 6.12.0 + * Update version to 6.12.0 + +------------------------------------------------------------------- +Sat Feb 8 12:16:45 UTC 2025 - Christophe Marin <christo...@krop.fr> + +- Update to 6.11.0 + * New feature release + * For more details please see: + * https://kde.org/announcements/frameworks/6/6.11.0 +- Changes since 6.10.0: + * Update dependency version to 6.11.0 + * replace opengl use with explicit app-driven api + * don't access nullptrs + * metadata: don't assume asserts are on + * metadata: make code more readable + * add support for arbitrary details metadata + * Add xml/yaml linting + * CI: Add linux-qt6-next build + * Update version to 6.11.0 + +------------------------------------------------------------------- +Tue Jan 7 18:17:26 UTC 2025 - Christophe Marin <christo...@krop.fr> + +- Update to 6.10.0 + * New feature release + * For more details please see: + * https://kde.org/announcements/frameworks/6/6.10.0 +- Changes since 6.9.0: + * Update dependency version to 6.10.0 + * Update version to 6.10.0 + +------------------------------------------------------------------- +Sun Dec 8 10:09:11 UTC 2024 - Christophe Marin <christo...@krop.fr> + +- Update to 6.9.0 + * New feature release + * For more details please see: + * https://kde.org/announcements/frameworks/6/6.9.0 +- Changes since 6.8.0: + * Update dependency version to 6.9.0 + * It compiles fine without deprecated methods + * ci: add Alpine/musl job + * Add static CI build + * Disable X11 and link with libnetwork on Haiku + * Update version to 6.9.0 + +------------------------------------------------------------------- +Mon Nov 4 11:18:02 UTC 2024 - Christophe Marin <christo...@krop.fr> + +- Update to 6.8.0 + * New feature release + * For more details please see: + * https://kde.org/announcements/frameworks/6/6.8.0 +- Changes since 6.7.0: + * Update dependency version to 6.8.0 + * Update version to 6.8.0 + +------------------------------------------------------------------- Old: ---- kcrash-6.7.0.tar.xz kcrash-6.7.0.tar.xz.sig New: ---- kcrash-6.13.0.tar.xz kcrash-6.13.0.tar.xz.sig ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ kf6-kcrash.spec ++++++ --- /var/tmp/diff_new_pack.L0OPmO/_old 2025-04-23 10:11:32.739484370 +0200 +++ /var/tmp/diff_new_pack.L0OPmO/_new 2025-04-23 10:11:32.739484370 +0200 @@ -1,7 +1,7 @@ # # spec file for package kf6-kcrash # -# Copyright (c) 2024 SUSE LLC +# Copyright (c) 2025 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -19,13 +19,13 @@ %define qt6_version 6.7.0 %define rname kcrash -# Full KF6 version (e.g. 6.7.0) +# Full KF6 version (e.g. 6.13.0) %{!?_kf6_version: %global _kf6_version %{version}} # Last major and minor KF6 version (e.g. 6.0) %{!?_kf6_bugfix_version: %define _kf6_bugfix_version %(echo %{_kf6_version} | awk -F. '{print $1"."$2}')} %bcond_without released Name: kf6-kcrash -Version: 6.7.0 +Version: 6.13.0 Release: 0 Summary: An application crash handler License: LGPL-2.1-or-later ++++++ kcrash-6.7.0.tar.xz -> kcrash-6.13.0.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/.gitlab-ci.yml new/kcrash-6.13.0/.gitlab-ci.yml --- old/kcrash-6.7.0/.gitlab-ci.yml 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/.gitlab-ci.yml 2025-04-04 16:00:00.000000000 +0200 @@ -5,5 +5,10 @@ - project: sysadmin/ci-utilities file: - /gitlab-templates/linux-qt6.yml + - /gitlab-templates/linux-qt6-next.yml + - /gitlab-templates/linux-qt6-static.yml + - /gitlab-templates/alpine-qt6.yml - /gitlab-templates/freebsd-qt6.yml - /gitlab-templates/windows-qt6.yml + - /gitlab-templates/xml-lint.yml + - /gitlab-templates/yaml-lint.yml diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/.kde-ci.yml new/kcrash-6.13.0/.kde-ci.yml --- old/kcrash-6.7.0/.kde-ci.yml 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/.kde-ci.yml 2025-04-04 16:00:00.000000000 +0200 @@ -1,9 +1,9 @@ Dependencies: -- 'on': ['@all'] - 'require': + - 'on': ['@all'] + 'require': 'frameworks/extra-cmake-modules': '@same' - 'frameworks/kcoreaddons' : '@same' + 'frameworks/kcoreaddons': '@same' Options: - test-before-installing: True - require-passing-tests-on: [ 'Linux', 'FreeBSD', 'Windows' ] + test-before-installing: true + require-passing-tests-on: ['Linux', 'FreeBSD', 'Windows'] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/CMakeLists.txt new/kcrash-6.13.0/CMakeLists.txt --- old/kcrash-6.7.0/CMakeLists.txt 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/CMakeLists.txt 2025-04-04 16:00:00.000000000 +0200 @@ -1,14 +1,14 @@ cmake_minimum_required(VERSION 3.16) -set(KF_VERSION "6.7.0") # handled by release scripts -set(KF_DEP_VERSION "6.7.0") # handled by release scripts +set(KF_VERSION "6.13.0") # handled by release scripts +set(KF_DEP_VERSION "6.13.0") # handled by release scripts project(KCrash VERSION ${KF_VERSION}) set(CMAKE_CXX_STANDARD 20) set(CMAKE_CXX_STANDARD_REQUIRED ON) include(FeatureSummary) -find_package(ECM 6.7.0 NO_MODULE) +find_package(ECM 6.13.0 NO_MODULE) set_package_properties(ECM PROPERTIES TYPE REQUIRED DESCRIPTION "Extra CMake Modules." URL "https://commits.kde.org/extra-cmake-modules") feature_summary(WHAT REQUIRED_PACKAGES_NOT_FOUND FATAL_ON_MISSING_REQUIRED_PACKAGES) @@ -20,10 +20,10 @@ include(KDEGitCommitHooks) include(ECMDeprecationSettings) -set(REQUIRED_QT_VERSION 6.5.0) -find_package(Qt6 ${REQUIRED_QT_VERSION} CONFIG REQUIRED Core Gui OpenGL) +set(REQUIRED_QT_VERSION 6.6.0) +find_package(Qt6 ${REQUIRED_QT_VERSION} CONFIG REQUIRED Core Gui) -if(UNIX AND NOT APPLE AND NOT ANDROID) +if(UNIX AND NOT APPLE AND NOT ANDROID AND NOT HAIKU) option(WITH_X11 "Build with X11 integration" ON) else() set(WITH_X11 OFF) @@ -61,8 +61,8 @@ "Raising signals to kernel core patterns (iff the pattern is a process). You may wish to not install drkonqi if this can cause a UI conflict.") ecm_set_disabled_deprecation_versions( - QT 6.5 - KF 5.102.0 + QT 6.9.0 + KF 6.12.0 ) add_subdirectory(src) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/autotests/metadatatest.cpp new/kcrash-6.13.0/autotests/metadatatest.cpp --- old/kcrash-6.7.0/autotests/metadatatest.cpp 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/autotests/metadatatest.cpp 2025-04-04 16:00:00.000000000 +0200 @@ -22,6 +22,7 @@ Metadata data("BEFEHL"); #ifdef Q_OS_LINUX MetadataINIWriter iniWriter(iniFile.toLocal8Bit()); + iniWriter.startKCrashGroup(); data.setAdditionalWriter(&iniWriter); #endif data.add("--ABC", "FOO\nBAR"); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/metainfo.yaml new/kcrash-6.13.0/metainfo.yaml --- old/kcrash-6.7.0/metainfo.yaml 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/metainfo.yaml 2025-04-04 16:00:00.000000000 +0200 @@ -11,7 +11,7 @@ deprecated: false release: true libraries: - - cmake: "KF6::Crash" + - cmake: "KF6::Crash" cmakename: KF6Crash public_lib: true diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/src/CMakeLists.txt new/kcrash-6.13.0/src/CMakeLists.txt --- old/kcrash-6.7.0/src/CMakeLists.txt 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/src/CMakeLists.txt 2025-04-04 16:00:00.000000000 +0200 @@ -45,7 +45,11 @@ target_include_directories(KF6Crash INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF}/KCrash>") target_link_libraries(KF6Crash PUBLIC Qt6::Core) -target_link_libraries(KF6Crash PRIVATE Qt6::Gui Qt6::OpenGL KF6::CoreAddons) +target_link_libraries(KF6Crash PRIVATE Qt6::Gui KF6::CoreAddons) + +if (HAIKU) + target_link_libraries(KF6Crash PRIVATE network) +endif () # FIXME: It is needed to work around undefined reference error on FreeBSD # caused by --no-undefined because the `environ' variable does not exist diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/src/kcrash.cpp new/kcrash-6.13.0/src/kcrash.cpp --- old/kcrash-6.7.0/src/kcrash.cpp 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/src/kcrash.cpp 2025-04-04 16:00:00.000000000 +0200 @@ -45,9 +45,6 @@ #include <QFile> #include <QGuiApplication> #include <QLibraryInfo> -#include <QOffscreenSurface> -#include <QOpenGLContext> -#include <QOpenGLFunctions> #include <QStandardPaths> #include <QThread> @@ -65,6 +62,7 @@ #undef Q_GLOBAL_STATIC using namespace std::chrono_literals; +using namespace Qt::StringLiterals; struct Args { Args() = default; @@ -127,28 +125,12 @@ { const KCrash::CoreConfig s_coreConfig; -std::unique_ptr<char[]> s_glRenderer; // the GL_RENDERER std::unique_ptr<char[]> s_qtVersion; -QString glRenderer() -{ - QOpenGLContext context; - QOffscreenSurface surface; - surface.create(); - - if (!context.create()) { - return {}; - } - - if (!context.makeCurrent(&surface)) { - return {}; - } - - auto done = qScopeGuard([&context] { - context.doneCurrent(); - }); - return QString::fromUtf8(reinterpret_cast<const char *>(context.functions()->glGetString(GL_RENDERER))); -} +using DetailsHash = QHash<QByteArray, QByteArray>; +std::unique_ptr<const DetailsHash> s_tags; // Sentry tags +std::unique_ptr<const DetailsHash> s_extraData; // Sentry extra data +std::unique_ptr<const DetailsHash> s_gpuContext; // Sentry gpu context QString bootId() { @@ -230,9 +212,6 @@ const QString path = QCoreApplication::applicationFilePath(); s_appFilePath.reset(qstrdup(qPrintable(path))); // This intentionally cannot be changed by the application! KCrash::setApplicationFilePath(path); - if (qobject_cast<QGuiApplication *>(QCoreApplication::instance())) { - s_glRenderer.reset(qstrdup(glRenderer().toUtf8().constData())); - } } else { qWarning() << "This process needs a QCoreApplication instance in order to use KCrash"; } @@ -488,8 +467,42 @@ if (!s_appFilePath) { fprintf(stderr, "KCrash: appFilePath points to nullptr!\n"); } else if (ini.isWritable()) { + if (s_tags) { + // [KCrashTags] + ini.startTagsGroup(); + // Add our dynamic details. Note that since we only add them to the ini they do not count against our static argv limit in the Metadata class. + for (const auto &[key, value] : s_tags->asKeyValueRange()) { + ini.add(key.constData(), value.constData(), MetadataWriter::BoolValue::No); + } + } + + if (s_extraData) { + // [KCrashExtra] + ini.startExtraGroup(); + // Add our dynamic details. Note that since we only add them to the ini they do not count against our static argv limit in the Metadata class. + for (const auto &[key, value] : s_extraData->asKeyValueRange()) { + ini.add(key.constData(), value.constData(), MetadataWriter::BoolValue::No); + } + } + if (s_kcrashErrorMessage) { + // And also our legacy error message + ini.add("--_kcrash_ErrorMessage", s_kcrashErrorMessage.get(), MetadataWriter::BoolValue::No); + } + + if (s_gpuContext) { + // [KCrashGPU] + ini.startGPUGroup(); + // Add our dynamic details. Note that since we only add them to the ini they do not count against our static argv limit in the Metadata class. + for (const auto &[key, value] : s_gpuContext->asKeyValueRange()) { + ini.add(key.constData(), value.constData(), MetadataWriter::BoolValue::No); + } + } + + // [KCrash] + ini.startKCrashGroup(); // Add the canonical exe path so the coredump daemon has more data points to map metadata to journald entry. ini.add("--exe", s_appFilePath.get(), MetadataWriter::BoolValue::No); + data.setAdditionalWriter(&ini); } #endif @@ -503,10 +516,6 @@ } } - if (s_glRenderer) { - data.add("--glrenderer", s_glRenderer.get()); - } - if (s_qtVersion) { data.add("--qtversion", s_qtVersion.get()); } @@ -773,3 +782,36 @@ { s_kcrashErrorMessage.reset(qstrdup(message.toUtf8().constData())); } + +void KCrash::setErrorTags(const QHash<QString, QString> &details) +{ + DetailsHash data; + for (const auto &[key, value] : details.asKeyValueRange()) { + data.insert(("--"_L1 + key).toUtf8(), value.toUtf8()); + } + // A bit awkard. We want the s_details to be const so we can't accidentally cause + // detachments, so we move our data into a unique ptr that is const. + s_tags = std::make_unique<const DetailsHash>(std::move(data)); +} + +void KCrash::setErrorExtraData(const QHash<QString, QString> &details) +{ + DetailsHash data; + for (const auto &[key, value] : details.asKeyValueRange()) { + data.insert(("--"_L1 + key).toUtf8(), value.toUtf8()); + } + // A bit awkard. We want the s_details to be const so we can't accidentally cause + // detachments, so we move our data into a unique ptr that is const. + s_extraData = std::make_unique<const DetailsHash>(std::move(data)); +} + +void KCrash::setGPUData(const QVariantHash &gpuData) +{ + DetailsHash data; + for (const auto &[key, value] : gpuData.asKeyValueRange()) { + data.insert(("--"_L1 + key).toUtf8(), value.toByteArray()); + } + // A bit awkard. We want the s_details to be const so we can't accidentally cause + // detachments, so we move our data into a unique ptr that is const. + s_gpuContext = std::make_unique<const DetailsHash>(std::move(data)); +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/src/kcrash.h new/kcrash-6.13.0/src/kcrash.h --- old/kcrash-6.7.0/src/kcrash.h 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/src/kcrash.h 2025-04-04 16:00:00.000000000 +0200 @@ -148,12 +148,40 @@ KCRASH_EXPORT bool isDrKonqiEnabled(); /** - * Allows providing information to be included in the bug report. + * Allows providing information to be included in the bug report. Prefer setErrorExtraInformation as it is more flexible. * * @since 5.69 */ KCRASH_EXPORT void setErrorMessage(const QString &message); +/** + * Sets the error tags to be included in the crash report. These are rendered as tags in the crash reporting system. + * Note that server-side limits apply to the length of these so you should only put short, sortable data in here. + * @since 6.11 + */ +KCRASH_EXPORT void setErrorTags(const QHash<QString, QString> &details); + +/** + * Sets the error details to be included in the crash report. These are rendered as extra blobs of data and can any form. + * Note that these are subject to event ingestion limits and should be kept at reasonable sizes to prevent event rejection. + * @since 6.11 + */ +KCRASH_EXPORT void setErrorExtraData(const QHash<QString, QString> &details); + +/** + * Sets better GPU data. + * By default KCrash will try to determine the GPU name, this may however not be accurate data. In particular on + * multi-gpu systems it may not be possible to determine whether the integrated or dedicated GPU is in use. + * You should call this function once you know which GPU will be in use for application. This is a free form string. + * Server-side limits may apply; keep it as short as possible. + * + * At least 'name' should be set. Additional supported fields follow Sentry unless documented otherwise. + * + * Supported fields are listed at + * https://develop.sentry.dev/sdk/data-model/event-payloads/contexts/#gpu-context + * @since 6.11 + */ +KCRASH_EXPORT void setGPUData(const QVariantHash &data); } #endif diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/src/metadata.cpp new/kcrash-6.13.0/src/metadata.cpp --- old/kcrash-6.7.0/src/metadata.cpp 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/src/metadata.cpp 2025-04-04 16:00:00.000000000 +0200 @@ -31,14 +31,45 @@ fprintf(stderr, "Failed to open metadata file: %s\n", strerror(errno)); } else if (fd >= 0) { writable = true; - const char *header = "[KCrash]\n"; - write(fd, header, strlen(header)); } else { fprintf(stderr, "MetadataINIWriter: Unexpected fd %d\n", fd); Q_UNREACHABLE(); } } +void MetadataINIWriter::startGroup(const char *group) const +{ + Q_ASSERT(group); // not null + Q_ASSERT(strlen(group) > 0); // not empty + Q_ASSERT(group[strlen(group) - 1] == '\n'); // end in newline + + if (!writable) { + return; + } + + write(fd, group, strlen(group)); +} + +void MetadataINIWriter::startTagsGroup() const +{ + startGroup("[KCrashTags]\n"); +} + +void MetadataINIWriter::startExtraGroup() const +{ + startGroup("[KCrashExtra]\n"); +} + +void MetadataINIWriter::startGPUGroup() const +{ + startGroup("[KCrashGPU]\n"); +} + +void MetadataINIWriter::startKCrashGroup() const +{ + startGroup("[KCrash]\n"); +} + void MetadataINIWriter::close() { if (fd >= 0 && ::close(fd) == -1) { @@ -54,7 +85,7 @@ Q_ASSERT(key[0] == '-' && key[1] == '-'); // well-formed '--' prefix. This is important. MetadataWriter presume this Q_UNUSED(boolValue); // value is a bool string but we don't care, we always write the value anyway - if (fd < 0) { + if (!writable) { return; } @@ -125,7 +156,11 @@ Q_ASSERT(key); Q_ASSERT(value); Q_ASSERT(key[0] == '-' && key[1] == '-'); // well-formed '--' prefix. This is important. MetadataWriter presume this - Q_ASSERT(argc < argv.max_size()); // argv has a static max size. guard against exhaustion + const auto belowCap = argc < argv.max_size(); + Q_ASSERT(belowCap); // argv has a static max size. guard against exhaustion + if (!belowCap) { + return; + } argv.at(argc++) = key; if (!boolValue) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcrash-6.7.0/src/metadata_p.h new/kcrash-6.13.0/src/metadata_p.h --- old/kcrash-6.7.0/src/metadata_p.h 2024-10-04 17:06:28.000000000 +0200 +++ new/kcrash-6.13.0/src/metadata_p.h 2025-04-04 16:00:00.000000000 +0200 @@ -40,6 +40,10 @@ explicit MetadataINIWriter(const QByteArray &path); ~MetadataINIWriter() override = default; + void startTagsGroup() const; + void startExtraGroup() const; + void startGPUGroup() const; + void startKCrashGroup() const; void add(const char *key, const char *value, BoolValue boolValue) override; void close() override; @@ -47,6 +51,7 @@ [[nodiscard]] bool isWritable() const; private: + void startGroup(const char *group) const; bool writable = false; int fd = -1;