Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.maint.python > #15489 > unrolled thread
| Started by | Andreas Tille <andreas@an3as.eu> |
|---|---|
| First post | 2024-02-23 08:30 +0100 |
| Last post | 2024-02-23 15:30 +0100 |
| Articles | 2 — 1 participant |
Back to article view | Back to linux.debian.maint.python
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Bug#1061765: Help needed to fix python-coverage-test-runner Andreas Tille <andreas@an3as.eu> - 2024-02-23 08:30 +0100
Bug#1061765: Help needed to fix python-coverage-test-runner Andreas Tille <andreas@an3as.eu> - 2024-02-23 15:30 +0100
| From | Andreas Tille <andreas@an3as.eu> |
|---|---|
| Date | 2024-02-23 08:30 +0100 |
| Subject | Bug#1061765: Help needed to fix python-coverage-test-runner |
| Message-ID | <Iay0F-c1NR-1@gated-at.bofh.it> |
Control: tags -1 help
Hi,
I've attempted to fix python-coverage-test-runner in Git since this
package is finally responsible for the failure of vmdb2:
File "/usr/lib/python3/dist-packages/CoverageTestRunner.py", line 22,
in <module>
import imp
ModuleNotFoundError: No module named 'imp'
In the patch in Git[1] I replaced imp by importlib (and distutils by
setuptools but this is not causing actual problems). Unfortunately
when trying to run vmdb2 test against this patched package I get:
./check
Running unit tests ============================================
Traceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "/usr/lib/python3/dist-packages/CoverageTestRunner.py", line 313, in <module>
run()
File "/usr/lib/python3/dist-packages/CoverageTestRunner.py", line 304, in run
result = runner.run()
^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/CoverageTestRunner.py", line 211, in run
importlib.reload(module)
File "/usr/lib/python3.11/importlib/__init__.py", line 148, in reload
raise ImportError(msg.format(name), name=name)
ImportError: module plugin not in sys.modules
The fact that
importlib.reload(module)
makes me wonder whether my patch for _load_module_from_pathname() is
correct (despite when I added some debug lines it looked sensible). Any
help is welcome.
Kind regards
Andreas.
[1] https://salsa.debian.org/python-team/packages/python-coverage-test-runner/-/blob/master/debian/patches/Python3.12.patch?ref_type=heads
--
http://fam-tille.de
[toc] | [next] | [standalone]
| From | Andreas Tille <andreas@an3as.eu> |
|---|---|
| Date | 2024-02-23 15:30 +0100 |
| Message-ID | <IaEIN-c5LR-1@gated-at.bofh.it> |
| In reply to | #15489 |
HI Andrius, Am Fri, Feb 23, 2024 at 09:29:27AM +0200 schrieb Andrius Merkys: > > ModuleNotFoundError: No module named 'imp' > > I had a similar problem. I worked it around by depending on > python3-zombie-imp, the original code did not require any modifications. Nice hint - implemented. Thanks a lot Andreas. -- http://fam-tille.de
[toc] | [prev] | [standalone]
Back to top | Article view | linux.debian.maint.python
csiph-web