Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kmod: Don't assume all modules are in kernel/ subdirectory #2532

Merged
merged 2 commits into from
Mar 19, 2024

Conversation

DaanDeMeyer
Copy link
Contributor

@DaanDeMeyer DaanDeMeyer commented Mar 19, 2024

When dkms is used or depending on the distribution, there might be modules
in other directories than kernel/.

@DaanDeMeyer DaanDeMeyer changed the title kernel module fixes kmod: Don't assume all modules are in kernel/ subdirectory Mar 19, 2024
@keszybz
Copy link
Member

keszybz commented Mar 19, 2024

+ env HOME=/ dnf --assumeyes --best --releasever=9 --installroot=/buildroot --setopt=keepcache=1 --setopt=logdir=/var/log --setopt=cachedir=/var/cache/dnf --setopt=persistdir=/var/lib/dnf --setopt=install_weak_deps=0 --setopt=check_config_file_age=0 '--disableplugin=*' --enableplugin=builddep --setopt=debuglevel=10 --setopt=metadata_expire=never --nodocs --config=/etc/dnf/dnf.conf --setopt=reposdir=/etc/yum.repos.d --setopt=varsdir=/etc/dnf/vars makecache --refresh
  Traceback (most recent call last):
    File "/usr/bin/dnf", line 61, in <module>
      from dnf.cli import main
    File "/usr/lib/python3/dist-packages/dnf/__init__.py", line 30, in <module>
      import dnf.base
    File "/usr/lib/python3/dist-packages/dnf/base.py", line 29, in <module>
      import libdnf.transaction
    File "/usr/lib/python3/dist-packages/libdnf/__init__.py", line 13, in <module>
      from . import module
    File "/usr/lib/python3/dist-packages/libdnf/module.py", line 10, in <module>
      from . import _module
  ImportError: cannot import name '_module' from partially initialized module 'libdnf' (most likely due to a circular import) (/usr/lib/python3/dist-packages/libdnf/__init__.py)

@keszybz
Copy link
Member

keszybz commented Mar 19, 2024

I restarted the failed tests.

mkosi/kmod.py Outdated Show resolved Hide resolved
@behrmann
Copy link
Contributor

I restarted the failed tests.

This seems to be a wider issue. I've already restarted a test for the same reason earlier today.

When dkms is used or depending on the distribution, there might be modules
in other directories than kernel/.
@keszybz
Copy link
Member

keszybz commented Mar 19, 2024

+ env HOME=/ dnf --assumeyes --best --releasever=9 --installroot=/buildroot --setopt=keepcache=1 --setopt=logdir=/var/log --setopt=cachedir=/var/cache/dnf --setopt=persistdir=/var/lib/dnf --setopt=install_weak_deps=0 --setopt=check_config_file_age=0 '--disableplugin=*' --enableplugin=builddep --setopt=debuglevel=10 --setopt=metadata_expire=never --nodocs --config=/etc/dnf/dnf.conf --setopt=reposdir=/etc/yum.repos.d --setopt=varsdir=/etc/dnf/vars makecache --refresh
  Traceback (most recent call last):
    File "/usr/bin/dnf", line 61, in <module>
      from dnf.cli import main
    File "/usr/lib/python3/dist-packages/dnf/__init__.py", line 30, in <module>
      import dnf.base
    File "/usr/lib/python3/dist-packages/dnf/base.py", line 29, in <module>
      import libdnf.transaction
    File "/usr/lib/python3/dist-packages/libdnf/__init__.py", line 13, in <module>
      from . import module
    File "/usr/lib/python3/dist-packages/libdnf/module.py", line 10, in <module>
      from . import _module
  ImportError: cannot import name '_module' from partially initialized module 'libdnf' (most likely due to a circular import) (/usr/lib/python3/dist-packages/libdnf/__init__.py)

It seems to be some Debian problem.

2024-03-19T10:45:41.7036765Z Unpacking python3-dnf (4.5.2-6) ...
2024-03-19T10:45:41.7610809Z Unpacking dnf (4.5.2-6) ...

This is ancient, the latest dnf version is 4.19. 4.5.2 is from late 2020.

@behrmann
Copy link
Contributor

This is ancient, the latest dnf version is 4.19. 4.5.2 is from late 2020.

Debian's a bit behind the curve, the current Debian stable release has 4.14 (and there's nothing newer in Debian), but the Ubuntu running in CI has the version from Debian bullseye, which is 4.5.2.

Without a newer OS on the Ci runner we might need to build dnf from source again.

@DaanDeMeyer DaanDeMeyer merged commit a15bf92 into systemd:main Mar 19, 2024
29 of 31 checks passed
@DaanDeMeyer DaanDeMeyer deleted the kmod branch March 19, 2024 11:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants