From: dataCobra <dataCobra@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: [PR PATCH] krita: fix scripts not working with python3.13
Date: Tue, 14 Jan 2025 13:27:39 +0100 [thread overview]
Message-ID: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-53965@inbox.vuxu.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 607 bytes --]
There is a new pull request by dataCobra against master on the void-packages repository
https://github.com/dataCobra/void-packages krita
https://github.com/void-linux/void-packages/pull/53965
krita: fix scripts not working with python3.13
#### Testing the changes
- I tested the changes in this PR: **YES**
#### Local build testing
- I built this PR locally for my native architecture, (x86_64-glibc)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64-musl
[ci skip]
A patch file from https://github.com/void-linux/void-packages/pull/53965.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-krita-53965.patch --]
[-- Type: text/x-diff, Size: 3516 bytes --]
From bd2696fdc36ed3da2262312cf9dacb420426e209 Mon Sep 17 00:00:00 2001
From: dataCobra <datacobra@thinkbot.de>
Date: Tue, 14 Jan 2025 13:15:37 +0100
Subject: [PATCH] krita: fix scripts not working with python3.13
---
srcpkgs/krita/patches/python-3.13.patch | 56 +++++++++++++++++++++++--
srcpkgs/krita/template | 2 +-
2 files changed, 54 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/krita/patches/python-3.13.patch b/srcpkgs/krita/patches/python-3.13.patch
index 6714059895d0ff..0a23a63adcea44 100644
--- a/srcpkgs/krita/patches/python-3.13.patch
+++ b/srcpkgs/krita/patches/python-3.13.patch
@@ -115,6 +115,56 @@ index fb309bd0b8..aec47da239 100644
*/
static bool setPath(const QStringList& scriptPaths);
---
-2.45.2
-
+diff --git a/plugins/extensions/pykrita/plugin/krita/excepthook.py b/plugins/extensions/pykrita/plugin/krita/excepthook.py
+index 029d5d3cb93..dfaeb560a37 100644
+--- a/plugins/extensions/pykrita/plugin/krita/excepthook.py
++++ b/plugins/extensions/pykrita/plugin/krita/excepthook.py
+@@ -11,7 +11,7 @@ Things to extend: Clicking on the filename should open an editor.
+ Things to consider: Mail exceptions, copy to clipboard or send to bug tracker.
+ """
+ import sys
+-import cgitb
++import traceback
+ import atexit
+
+ from PyQt5.QtCore import pyqtSlot, Qt
+@@ -61,7 +61,7 @@ class ExceptHookDialog(QDialog):
+ self.setWindowTitle(self.windowTitle() + ": " + title)
+ msg = "%s: %s" % (exc_type.__name__, exc_obj)
+ self.ui.exceptionLabel.setText(msg)
+- html = cgitb.text((exc_type, exc_obj, exc_tb))
++ html = traceback.format_exception(exc_type, exc_obj, exc_tb).splitlines()
+ self.ui.tracebackBrowser.setText(html)
+ self.resize(650, 350) # give enough space to see the backtrace better
+
+@@ -74,7 +74,7 @@ if __name__ == "__main__":
+ # Some tests:
+ app = QApplication(sys.argv)
+ install()
+- print("Triggering error 1")
++ print("Triggering error 1")f
+ try:
+ fail = 1 / 0
+ except:
+diff --git a/plugins/extensions/pykrita/plugin/krita/excepthook.py b/plugins/extensions/pykrita/plugin/krita/excepthook.py
+index dfaeb560a37..a6b7fafc4f6 100644
+--- a/plugins/extensions/pykrita/plugin/krita/excepthook.py
++++ b/plugins/extensions/pykrita/plugin/krita/excepthook.py
+@@ -61,7 +61,7 @@ class ExceptHookDialog(QDialog):
+ self.setWindowTitle(self.windowTitle() + ": " + title)
+ msg = "%s: %s" % (exc_type.__name__, exc_obj)
+ self.ui.exceptionLabel.setText(msg)
+- html = traceback.format_exception(exc_type, exc_obj, exc_tb).splitlines()
++ html = "\n".join(traceback.format_exception(exc_type, exc_obj, exc_tb))
+ self.ui.tracebackBrowser.setText(html)
+ self.resize(650, 350) # give enough space to see the backtrace better
+
+@@ -74,7 +74,7 @@ if __name__ == "__main__":
+ # Some tests:
+ app = QApplication(sys.argv)
+ install()
+- print("Triggering error 1")f
++ print("Triggering error 1")
+ try:
+ fail = 1 / 0
+ except:
diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index 9b69726d67dcaf..b151a7bdc0119f 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
# Template file for 'krita'
pkgname=krita
version=5.2.6
-revision=2
+revision=3
build_style=cmake
configure_args="-Wno-dev -DBUILD_TESTING=OFF -DENABLE_UPDATERS=OFF"
hostmakedepends="extra-cmake-modules gettext pkg-config python3
next reply other threads:[~2025-01-14 12:27 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-14 12:27 dataCobra [this message]
2025-01-14 12:49 ` ahesford
2025-01-14 12:52 ` dataCobra
2025-01-14 13:47 ` ahesford
2025-01-15 12:46 ` [PR REVIEW] " sgn
2025-01-15 12:47 ` sgn
2025-01-15 13:07 ` ahesford
2025-02-03 8:57 ` [PR PATCH] [Updated] krita: update to 5.2.9 dataCobra
2025-02-03 9:05 ` dataCobra
2025-02-03 13:06 ` [PR PATCH] [Merged]: " Johnnynator
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-53965@inbox.vuxu.org \
--to=datacobra@users.noreply.github.com \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).