Bug 2203738

Summary: libmodulemd fails to build with rpm-4.18.90: modulemd:ci+c+c_release / module_index_release - FAIL - killed by signal 6 SIGABRT
Product: [Fedora] Fedora Reporter: Tomáš Hrnčiar <thrnciar>
Component: rpmAssignee: Packaging Maintenance Team <packaging-team-maint>
Status: MODIFIED --- QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 39CC: ffesti, igor.raits, mdomonko, mhroncok, nphilipp, packaging-team-maint, pmatilai, ppisar, sgallagh, thrnciar
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: rpm-4.18.90-3.fc39 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Tomáš Hrnčiar 2023-05-15 07:14:20 UTC
libmodulemd fails to build with Python 3.12.0a7.

 23/113 modulemd:ci+c+c_release / module_index_release                                           FAIL              0.29s   killed by signal 6 SIGABRT
>>> MALLOC_PERTURB_=246 TEST_DATA_PATH=/builddir/build/BUILD/modulemd-2.15.0/modulemd/tests/test_data MESON_BUILD_ROOT=/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build LD_LIBRARY_PATH=/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd MESON_SOURCE_ROOT=/builddir/build/BUILD/modulemd-2.15.0 LC_ALL=C /builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd/module_index
――――――――――――――――――――――――――――――――――――― ✀  ―――――――――――――――――――――――――――――――――――――
stdout:
TAP version 13
# random seed: R02Sef23c9527096d34bd824e4f26157f954
1..18
# Start of modulemd tests
# Start of v2 tests
# Start of module tests
# Start of index tests
ok 1 /modulemd/v2/module/index/dump
ok 2 /modulemd/v2/module/index/read
ok 3 /modulemd/v2/module/index/remove_module
ok 4 /modulemd/v2/module/index/custom_read
ok 5 /modulemd/v2/module/index/custom_write
ok 6 /modulemd/v2/module/index/get_default_streams
ok 7 /modulemd/v2/module/index/empty
not ok /modulemd/v2/module/index/compressed - libmodulemd:ERROR:../modulemd/tests/test-modulemd-moduleindex.c:1493:test_module_index_read_compressed: assertion failed (error == NULL): Parser error (modulemd-yaml-error-quark, 2)
Bail out!
stderr:
**
libmodulemd:ERROR:../modulemd/tests/test-modulemd-moduleindex.c:1493:test_module_index_read_compressed: assertion failed (error == NULL): Parser error (modulemd-yaml-error-quark, 2)
――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――

 24/113 modulemd:ci+ci_valgrind+c+c_debug / module_index_debug                                   FAIL              2.23s   killed by signal 6 SIGABRT
>>> MALLOC_PERTURB_=64 TEST_DATA_PATH=/builddir/build/BUILD/modulemd-2.15.0/modulemd/tests/test_data MESON_BUILD_ROOT=/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build LD_LIBRARY_PATH=/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd MESON_SOURCE_ROOT=/builddir/build/BUILD/modulemd-2.15.0 LC_ALL=C G_MESSAGES_DEBUG=all G_DEBUG=fatal-warnings,fatal-criticals /builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd/module_index
――――――――――――――――――――――――――――――――――――― ✀  ―――――――――――――――――――――――――――――――――――――

...

(/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd/module_index:1775): libmodulemd-DEBUG: 13:57:27.044: Parser error
(/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd/module_index:1775): libmodulemd-DEBUG: 13:57:27.044: Error: Parser error
not ok /modulemd/v2/module/index/compressed - libmodulemd:ERROR:../modulemd/tests/test-modulemd-moduleindex.c:1493:test_module_index_read_compressed: assertion failed (error == NULL): Parser error (modulemd-yaml-error-quark, 2)
Bail out!
stderr:
**
libmodulemd:ERROR:../modulemd/tests/test-modulemd-moduleindex.c:1493:test_module_index_read_compressed: assertion failed (error == NULL): Parser error (modulemd-yaml-error-quark, 2)
――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――


https://docs.python.org/3.12/whatsnew/3.12.html

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.12/fedora-rawhide-x86_64/05911438-libmodulemd/

For all our attempts to build libmodulemd with Python 3.12, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.12/package/libmodulemd/

Testing and mass rebuild of packages is happening in copr. You can follow these instructions to test locally in mock if your package builds with Python 3.12:
https://copr.fedorainfracloud.org/coprs/g/python/python3.12/

Let us know here if you have any questions.

Python 3.12 is planned to be included in Fedora 39. To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.12.
A build failure prevents us from testing all dependent packages (transitive [Build]Requires), so if this package is required a lot, it's important for us to get it fixed soon.
We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side.

Comment 1 Petr Pisar 2023-05-15 15:48:02 UTC
The build log for a test in debug mode shows more details:

(/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd/module_index:1775): libmodulemd-DEBUG: 13:57:27.044: Processing /builddir/build/BUILD/modulemd-2.15.0/modulemd/tests/test_data/compression/bzipped, expecting success
(/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd/module_index:1775): libmodulemd-DEBUG: 13:57:27.044: Calling rpmio::Fdopen (0x557f54abad40, r.bzdio)
(/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd/module_index:1775): libmodulemd-DEBUG: 13:57:27.044: rpmio::Fdopen (0x557f54abad40, r.bzdio) succeeded
(/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd/module_index:1775): libmodulemd-DEBUG: 13:57:27.044: Parser error
(/builddir/build/BUILD/modulemd-2.15.0/redhat-linux-build/modulemd/module_index:1775): libmodulemd-DEBUG: 13:57:27.044: Error: Parser error
not ok /modulemd/v2/module/index/compressed - libmodulemd:ERROR:../modulemd/tests/test-modulemd-moduleindex.c:1493:test_module_index_read_compressed: assertion failed (error == NULL): Parser error (modulemd-yaml-error-quark, 2)
Bail out!

Especially it failed to parse a bzip2-compressed file. The decompression is performed with librpmio. librpmio library is packaged in rpm-libs RPM package.

root.log claims rpm-libs-4.18.90-1.fc39.x86_64. That's a developmental version of rpm only built in a side tag, not available in Rawhide. It seems your COPR build root is infected with developmental rpm and the cause is not Python 3.12, but rpm-4.18.90.

Comment 2 Florian Festi 2023-05-15 16:46:40 UTC
This is an issue in RPM itself. Turns out the new CMake build system does not detect libbzip2 properly fixed upstream with https://github.com/rpm-software-management/rpm/commit/d18d6ce41df4a5887df47a69052a401808aef19f and with rpm-4.18.90-3.fc39.

Note that rpm is not yet build in rawhide as there are (obviously) still some hiccups to be cleared up and the build requires a bit delicate dance with changes to the whole software stack while trying not breaking the build system.

Comment 3 Petr Pisar 2023-05-16 07:13:04 UTC
Thanks for the quick fix, I confirm that libmodulemd builds fine, including tests, with rpm-4.18.90-3.fc39.x86_64.

Though, I would expect an earlier failure already in Fdopen(, "r.bzdio"), if rpm is built without bzip2 support.

Comment 4 Fedora Release Engineering 2023-08-16 07:14:12 UTC
This bug appears to have been reported against 'rawhide' during the Fedora Linux 39 development cycle.
Changing version to 39.