New version of python-jsonschema requires rpds-py (which needs rust things)

Hi all, one of ansible-lint's dependencies is python-jsonschema, which was updated to 4.18.0a1 recently. Unfortunately this does not build out of the box, because the tests require rpds. I built that (although it was archived in 2019), but then the tests fail, as they cannot import one module from it. Then I found that there is another module called rpds-py, "Python bindings to Rust's persistent data structures (rpds)". This one seems to provide the right module. I tried to build that, but now we are touching rust packaging, and I gave up (for now...). If anyone wants to have a look, here is what I have so far:
https://build.opensuse.org/package/show/home:ojkastl_buildservice:Branch_dev... https://build.opensuse.org/package/show/home:ojkastl_buildservice:Branch_dev...
Kind Regards, Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537

On 20.03.23 at 15:44 Johannes Kastl wrote:
I tried to build that, but now we are touching rust packaging, and I gave up (for now...).
I managed to add cargo vendoring to the package and added the tarball to spec file. However, the build still fails with cargo errors.
https://build.opensuse.org/package/show/home:ojkastl_buildservice:Branch_dev...
Stay tuned, I'll have a closer look tomorrow. Kind Regards, Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537

On 20.03.23 at 15:44 Johannes Kastl wrote:
https://build.opensuse.org/package/show/home:ojkastl_buildservice:Branch_dev...
I am learning new things everyday. I got the package almost ready, it only complains as it has some unpackaged files:
[ 42s] RPM build errors: [ 42s] Installed (but unpackaged) file(s) found: [ 42s] /usr/lib/debug/usr/lib64/python3.10/site-packages/rpds/rpds.abi3.so.debug [ 42s] /usr/lib/debug/usr/lib64/python3.11/site-packages/rpds/rpds.abi3.so.debug [ 42s] /usr/lib/debug/usr/lib64/python3.8/site-packages/rpds/rpds.abi3.so.debug [ 42s] /usr/lib/debug/usr/lib64/python3.9/site-packages/rpds/rpds.abi3.so.debug
On first glance I have not found a macro for that. And I would guess that this needs to go into a debuginfo-subpackage for each python flavor? What would the %files section look like? My first try does not work...
%files %{python_files}-debuginfo /usr/lib/debug/usr/lib64/python%{python_version}/site-packages/rpds/
Maybe someone more experienced than me can lend a hand... :-) Kind Regards, Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537

On 24.03.23 at 08:24 Johannes Kastl wrote:
On 20.03.23 at 15:44 Johannes Kastl wrote:
https://build.opensuse.org/package/show/home:ojkastl_buildservice:Branch_dev...
I am learning new things everyday. I got the package almost ready, it only complains as it has some unpackaged files:
[ 42s] RPM build errors: [ 42s] Installed (but unpackaged) file(s) found: [ 42s] /usr/lib/debug/usr/lib64/python3.10/site-packages/rpds/rpds.abi3.so.debug [ 42s] /usr/lib/debug/usr/lib64/python3.11/site-packages/rpds/rpds.abi3.so.debug [ 42s] /usr/lib/debug/usr/lib64/python3.8/site-packages/rpds/rpds.abi3.so.debug [ 42s] /usr/lib/debug/usr/lib64/python3.9/site-packages/rpds/rpds.abi3.so.debug
This seems to be valid syntax: %files %{python_files debuginfo} /usr/lib/debug/usr/lib64/python%{python_version}/site-packages/rpds/ But now it complains that the debuginfo packages are not existing... Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537

Am 24.03.23 um 08:38 schrieb Johannes Kastl:
On 24.03.23 at 08:24 Johannes Kastl wrote:
On 20.03.23 at 15:44 Johannes Kastl wrote:
https://build.opensuse.org/package/show/home:ojkastl_buildservice:Branch_dev...
I am learning new things everyday. I got the package almost ready, it only complains as it has some unpackaged files:
[ 42s] RPM build errors: [ 42s] Installed (but unpackaged) file(s) found: [ 42s] /usr/lib/debug/usr/lib64/python3.10/site-packages/rpds/rpds.abi3.so.debug [ 42s] /usr/lib/debug/usr/lib64/python3.11/site-packages/rpds/rpds.abi3.so.debug [ 42s] /usr/lib/debug/usr/lib64/python3.8/site-packages/rpds/rpds.abi3.so.debug
[ 42s] /usr/lib/debug/usr/lib64/python3.9/site-packages/rpds/rpds.abi3.so.debug
...
But now it complains that the debuginfo packages are not existing...
Johannes
Remove the `BuildArch: noarch` line. You have platform dependent compiled binaries in there. The debuginfo and debugsource packages of compiled stuff is created by rpm at the end of the %install stage. Do not create such a package manually. - Ben

On 24.03.23 at 10:03 Ben Greiner wrote:
Remove the `BuildArch: noarch` line. You have platform dependent compiled binaries in there. The debuginfo and debugsource packages of compiled stuff is created by rpm at the end of the %install stage. Do not create such a package manually.
Thanks Ben, I was guessing that there is a mechanism in the background. But I did not know that this is triggered by BuildArch... Have a nice weekend. Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537

On 24.03.23 at 13:05 Johannes Kastl wrote:
On 24.03.23 at 10:03 Ben Greiner wrote:
Remove the `BuildArch: noarch` line. You have platform dependent compiled binaries in there. The debuginfo and debugsource packages of compiled stuff is created by rpm at the end of the %install stage. Do not create such a package manually.
Thanks Ben, I was guessing that there is a mechanism in the background. But I did not know that this is triggered by BuildArch...
The package built successfully. Kind Regards, Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
participants (2)
-
Ben Greiner
-
Johannes Kastl