mirror of
https://github.com/void-linux/void-packages.git
synced 2025-06-13 02:23:51 +02:00
orca: patch for compatibility with Python 3.10
This commit is contained in:
parent
bae6e08254
commit
8fc9c14244
2 changed files with 32 additions and 1 deletions
31
srcpkgs/orca/patches/python3.10.patch
Normal file
31
srcpkgs/orca/patches/python3.10.patch
Normal file
|
@ -0,0 +1,31 @@
|
||||||
|
From 41b7a370addd507d6583c135c8ac99c7c06076e5 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Kalev Lember <klember@redhat.com>
|
||||||
|
Date: Fri, 10 Sep 2021 10:12:23 +0200
|
||||||
|
Subject: [PATCH] Fix compatibility with Python 3.10
|
||||||
|
|
||||||
|
Python 3.10 removed aliases to Collections Abstract Base Classes that
|
||||||
|
were deprecated in Python 3.3.
|
||||||
|
|
||||||
|
Fix this by just using collections.abc directly without using the alias.
|
||||||
|
|
||||||
|
https://docs.python.org/3.10/whatsnew/changelog.html#python-3-10-0-alpha-5
|
||||||
|
---
|
||||||
|
src/orca/generator.py | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/src/orca/generator.py b/src/orca/generator.py
|
||||||
|
index e98970992..e9a9d89de 100644
|
||||||
|
--- a/src/orca/generator.py
|
||||||
|
+++ b/src/orca/generator.py
|
||||||
|
@@ -78,7 +78,7 @@ class Generator:
|
||||||
|
self._activeProgressBars = {}
|
||||||
|
self._methodsDict = {}
|
||||||
|
for method in \
|
||||||
|
- [z for z in [getattr(self, y).__get__(self, self.__class__) for y in [x for x in dir(self) if x.startswith(METHOD_PREFIX)]] if isinstance(z, collections.Callable)]:
|
||||||
|
+ [z for z in [getattr(self, y).__get__(self, self.__class__) for y in [x for x in dir(self) if x.startswith(METHOD_PREFIX)]] if isinstance(z, collections.abc.Callable)]:
|
||||||
|
name = method.__name__[len(METHOD_PREFIX):]
|
||||||
|
name = name[0].lower() + name[1:]
|
||||||
|
self._methodsDict[name] = method
|
||||||
|
--
|
||||||
|
GitLab
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# Template file for 'orca'
|
# Template file for 'orca'
|
||||||
pkgname=orca
|
pkgname=orca
|
||||||
version=40.0
|
version=40.0
|
||||||
revision=2
|
revision=3
|
||||||
build_style=gnu-configure
|
build_style=gnu-configure
|
||||||
hostmakedepends="intltool itstool pkg-config"
|
hostmakedepends="intltool itstool pkg-config"
|
||||||
makedepends="at-spi2-atk-devel liblouis-devel python3-gobject-devel"
|
makedepends="at-spi2-atk-devel liblouis-devel python3-gobject-devel"
|
||||||
|
|
Loading…
Add table
Reference in a new issue