| Summary: | [rpm-python] rpm._rpms: undefined symbol: spec_Type | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Carl George <carl> | ||||
| Component: | rpm | Assignee: | Packaging Maintenance Team <packaging-team-maint> | ||||
| Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
| Severity: | unspecified | Docs Contact: | |||||
| Priority: | unspecified | ||||||
| Version: | 24 | CC: | ben.harper, ignatenko, kardos.lubos, novyjindrich, packaging-team-maint, pknirsch, pmatilai, vponcova | ||||
| Target Milestone: | --- | Keywords: | TestBlocker | ||||
| Target Release: | --- | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | |||||||
| : | 1462671 (view as bug list) | Environment: | |||||
| Last Closed: | 2017-05-23 09:07:32 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Bug Depends On: | |||||||
| Bug Blocks: | 1462671 | ||||||
| Attachments: |
|
||||||
|
Description
Carl George
2016-11-10 06:12:05 UTC
Confirm this bug on rawhide. Yup, fixed upstream for some time, 4.13.1 material certainly: https://github.com/rpm-software-management/rpm/commit/eb632e5158fa4ef993b0e5df2a354f0be7a7a71d That is odd, because that typo exists on EL7 as well, but everything works fine there. # yumdownloader --source rpm # rpm -i rpm-4.11.3-21.el7.src.rpm # cd rpmbuild/SOURCES # tar -xf rpm-4.11.3.tar.bz2 # grep -A6 rpm\._rpms rpm-4.11.3/python/setup.py.in rpmsign_mod = Extension('rpm._rpms', sources = ['rpmbmodule.c'], include_dirs = pkgconfig('--cflags'), libraries = pkgconfig('--libs') + ['rpmsign'], extra_compile_args = cflags, extra_link_args = additional_link_args ) # rpm -q rpm rpm-4.11.3-21.el7.x86_64 # python -c 'from rpm._rpms import *' # (In reply to Panu Matilainen from comment #2) > Yup, fixed upstream for some time, 4.13.1 material certainly: > https://github.com/rpm-software-management/rpm/commit/ > eb632e5158fa4ef993b0e5df2a354f0be7a7a71d I think it's different thing. In EL7 setup.py is not used for compiling the shipped python bindings. It *could* be something else too but I don't see what that would be. Can https://github.com/rpm-software-management/rpm/commit/eb632e5158fa4ef993b0e5df2a354f0be7a7a71d be backported as a patch for Fedora 24 and/or 25? I'm currently using rpm.addSign with Python 2 on EL7, but I would like to migrate to Python 3 on Fedora. This bug is preventing me from doing so. Can anyone comment on whether 4.13.1 is due to be released soon, or if that fix can be backported to Fedora 25? This is broken in all current Fedora releases. Please backport that commit in order to fix it. We get a similar error on Fedora Rawhide when we run pylint:
Traceback (most recent call last):
File "/usr/lib/python3.6/site-packages/astroid/manager.py", line 129, in ast_from_module_name
module = modutils.load_module_from_name(modname)
File "/usr/lib/python3.6/site-packages/astroid/modutils.py", line 190, in load_module_from_name
return load_module_from_modpath(dotted_name.split('.'), path, use_sys)
File "/usr/lib/python3.6/site-packages/astroid/modutils.py", line 233, in load_module_from_modpath
module = imp.load_module(curname, mp_file, mp_filename, mp_desc)
File "/usr/lib64/python3.6/imp.py", line 242, in load_module
return load_dynamic(name, filename, file)
File "/usr/lib64/python3.6/imp.py", line 342, in load_dynamic
return _load(spec)
File "<frozen importlib._bootstrap>", line 675, in _load
File "<frozen importlib._bootstrap>", line 648, in _load_unlocked
File "<frozen importlib._bootstrap>", line 560, in module_from_spec
File "<frozen importlib._bootstrap_external>", line 922, in create_module
File "<frozen importlib._bootstrap>", line 205, in _call_with_frames_removed
ImportError: /usr/lib64/python3.6/site-packages/rpm/_rpms.cpython-36m-x86_64-linux-gnu.so: undefined symbol: spec_Type
I tested out adding https://github.com/rpm-software-management/rpm/commit/eb632e5158fa4ef993b0e5df2a354f0be7a7a71d as a patch in COPR https://copr.fedorainfracloud.org/coprs/carlgeorge/rpm-rhbz1393659/ for Fedora 25. It worked as expected. Please add the patch. Created attachment 1281076 [details]
Use correct source file for rpmsign module
This bug breaks anaconda tests for rawhide, so setting as a test blocker. What on earth is anaconda doing with rpm's signing module? Anyway... fixed in rpm-4.13.0.1-21.fc27 In our tests, we run pylint on anaconda and pylint fails to analyse code that imports rpm (see comment 9). Thank you! This is broken in F26, F25, and F24 as well. Can it please be fixed in more than just Rawhide? Hi, this bug now breaks anaconda tests on Fedora 26. Could you please fix it as well? Opened new bug for Fedora 26: https://bugzilla.redhat.com/show_bug.cgi?id=1462671 |