diff options
author | Khem Raj <raj.khem@gmail.com> | 2023-11-04 13:33:51 -0700 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2023-11-06 08:47:42 -0800 |
commit | 039ed44201bbf5bb80f9ade434d04fe835d5dffa (patch) | |
tree | 9f2f4c5b40b3afbd78bed9f41b28b66b45d3b90d | |
parent | 348df1a7ef8f5ccaed1375f7fcc210a936343b61 (diff) | |
download | meta-openembedded-039ed44201bbf5bb80f9ade434d04fe835d5dffa.tar.gz |
python3-wxgtk4: upgrade 4.2.0 -> 4.2.1
Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r-- | meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4/0001-pypubsub-Replace-deprecated-inspect.getargspec.patch | 65 | ||||
-rw-r--r-- | meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4_4.2.1.bb (renamed from meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4_4.2.0.bb) | 3 |
2 files changed, 1 insertions, 67 deletions
diff --git a/meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4/0001-pypubsub-Replace-deprecated-inspect.getargspec.patch b/meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4/0001-pypubsub-Replace-deprecated-inspect.getargspec.patch deleted file mode 100644 index 9bec4c5ba6..0000000000 --- a/meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4/0001-pypubsub-Replace-deprecated-inspect.getargspec.patch +++ /dev/null | |||
@@ -1,65 +0,0 @@ | |||
1 | Upstream-Status: Backport [https://github.com/wxWidgets/Phoenix/commit/9986a0d5] | ||
2 | |||
3 | Signed-off-by: Kai Kang <kai.kang@windriver.com> | ||
4 | |||
5 | From 9986a0d5c24b5d45ddf571d60351f68765a8a9be Mon Sep 17 00:00:00 2001 | ||
6 | From: Scott Talbert <swt@techie.net> | ||
7 | Date: Mon, 8 Aug 2022 22:35:58 -0400 | ||
8 | Subject: [PATCH] pypubsub: Replace deprecated inspect.getargspec | ||
9 | |||
10 | inspect.getargspec was removed in Python 3.11. This is a backport of: | ||
11 | https://github.com/schollii/pypubsub/commit/089c7a73f85c76a3aa22e4b10c71db1bf65a8637 | ||
12 | --- | ||
13 | wx/lib/pubsub/core/callables.py | 23 +++++++++++++++-------- | ||
14 | 1 file changed, 15 insertions(+), 8 deletions(-) | ||
15 | |||
16 | diff --git a/wx/lib/pubsub/core/callables.py b/wx/lib/pubsub/core/callables.py | ||
17 | index 65eb1ebe..7e798c54 100644 | ||
18 | --- a/wx/lib/pubsub/core/callables.py | ||
19 | +++ b/wx/lib/pubsub/core/callables.py | ||
20 | @@ -12,7 +12,7 @@ CallArgsInfo regarding its autoTopicArgName data member. | ||
21 | |||
22 | """ | ||
23 | |||
24 | -from inspect import getargspec, ismethod, isfunction | ||
25 | +from inspect import ismethod, isfunction, signature, Parameter | ||
26 | |||
27 | from .. import py2and3 | ||
28 | |||
29 | @@ -133,19 +133,26 @@ class CallArgsInfo: | ||
30 | self.autoTopicArgName = None.""" | ||
31 | |||
32 | #args, firstArgIdx, defaultVals, acceptsAllKwargs | ||
33 | - (allParams, varParamName, varOptParamName, defaultVals) = getargspec(func) | ||
34 | - if defaultVals is None: | ||
35 | - defaultVals = [] | ||
36 | - else: | ||
37 | - defaultVals = list(defaultVals) | ||
38 | + allParams = [] | ||
39 | + defaultVals = [] | ||
40 | + varParamName = None | ||
41 | + varOptParamName = None | ||
42 | + for argName, param in signature(func).parameters.items(): | ||
43 | + if param.default != Parameter.empty: | ||
44 | + defaultVals.append(param.default) | ||
45 | + if param.kind == Parameter.VAR_POSITIONAL: | ||
46 | + varParamName = argName | ||
47 | + elif param.kind == Parameter.VAR_KEYWORD: | ||
48 | + varOptParamName = argName | ||
49 | + else: | ||
50 | + allParams.append(argName) | ||
51 | |||
52 | self.acceptsAllKwargs = (varOptParamName is not None) | ||
53 | self.acceptsAllUnnamedArgs = (varParamName is not None) | ||
54 | - | ||
55 | self.allParams = allParams | ||
56 | - del self.allParams[0:firstArgIdx] # does nothing if firstArgIdx == 0 | ||
57 | |||
58 | self.numRequired = len(self.allParams) - len(defaultVals) | ||
59 | + assert len(self.allParams) >= len(defaultVals) | ||
60 | assert self.numRequired >= 0 | ||
61 | |||
62 | # if listener wants topic, remove that arg from args/defaultVals | ||
63 | -- | ||
64 | 2.34.1 | ||
65 | |||
diff --git a/meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4_4.2.0.bb b/meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4_4.2.1.bb index bf87b0a73d..fb011cb71b 100644 --- a/meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4_4.2.0.bb +++ b/meta-python/recipes-devtools/python3-wxgtk4/python3-wxgtk4_4.2.1.bb | |||
@@ -13,10 +13,9 @@ PYPI_PACKAGE = "wxPython" | |||
13 | SRC_URI += "file://add-back-option-build-base.patch \ | 13 | SRC_URI += "file://add-back-option-build-base.patch \ |
14 | file://wxgtk-fixup-build-scripts.patch \ | 14 | file://wxgtk-fixup-build-scripts.patch \ |
15 | file://not-overwrite-cflags-cxxflags.patch \ | 15 | file://not-overwrite-cflags-cxxflags.patch \ |
16 | file://0001-pypubsub-Replace-deprecated-inspect.getargspec.patch \ | ||
17 | file://0001-sip-Conditionally-use-GetAssertStackTrace-under-USE_.patch \ | 16 | file://0001-sip-Conditionally-use-GetAssertStackTrace-under-USE_.patch \ |
18 | " | 17 | " |
19 | SRC_URI[sha256sum] = "663cebc4509d7e5d113518865fe274f77f95434c5d57bc386ed58d65ceed86c7" | 18 | SRC_URI[sha256sum] = "e48de211a6606bf072ec3fa778771d6b746c00b7f4b970eb58728ddf56d13d5c" |
20 | 19 | ||
21 | S = "${WORKDIR}/wxPython-${PV}" | 20 | S = "${WORKDIR}/wxPython-${PV}" |
22 | 21 | ||