Bug 2216407 - Disabling module does not disable modular dependencies
Summary: Disabling module does not disable modular dependencies
Keywords:
Status: NEW
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: dnf
Version: 8.8
Hardware: All
OS: Linux
low
unspecified
Target Milestone: rc
: ---
Assignee: David Cantrell
QA Contact: swm-qe
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-06-21 08:41 UTC by Mikhail Campos
Modified: 2023-08-17 10:19 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHEL-1447 0 None None None 2023-08-17 10:19:50 UTC
Red Hat Issue Tracker RHELPLAN-160347 0 None None None 2023-06-21 08:45:23 UTC

Description Mikhail Campos 2023-06-21 08:41:30 UTC
Description of problem:
When we disable a module with

  dnf module disable

all other modules which are not disabled and depend on it trigger showing warnings. This happens on any dnf operation, even not related to modularity. For example:

$ dnf module disable llvm-toolset
<... output skipped>
Modular dependency problems with Defaults:

 Problem 1: module rust-toolset:rhel8:8030020200807201053:d48633fe.x86_64 requires module(llvm-toolset:rhel8), but none of the providers can be installed
  - conflicting requests
  - module llvm-toolset:rhel8:8060020220204053142:d63f516d.x86_64 is disabled
<... output skipped>
$ dnf search smb
Updating Subscription Management repositories.
Last metadata expiration check: 0:02:05 ago on Wed 21 Jun 2023 10:21:45 AM CEST.
Modular dependency problems:

 Problem 1: module rust-toolset:rhel8:8030020200807201053:d48633fe.x86_64 requires module(llvm-toolset:rhel8), but none of the providers can be installed
  - conflicting requests
  - module llvm-toolset:rhel8:8060020220204053142:d63f516d.x86_64 is disabled
<... output skipped>
================================== Name & Summary Matched: smb ===================================
gvfs-smb-debuginfo.x86_64 : Debug information for package gvfs-smb
gvfs-smb-debuginfo.i686 : Debug information for package gvfs-smb
libsmbclient.i686 : The SMB client library
libsmbclient.x86_64 : The SMB client library
<... output skipped>

Note, that all dnf operations can complete, but we have annoying warnings during each operation.

The proposal is to disable also all dependent modules on module disable op. For example above, the operation 'dnf module disable llvm-toolset' should also disable rust-toolset module as well.


Version-Release number of selected component (if applicable):
# rpm -qa | grep dnf-
python3-dnf-4.7.0-16.el8_8.noarch
python3-libdnf-0.63.0-8.el8.x86_64
dnf-4.7.0-16.el8_8.noarch
python3-dnf-plugins-core-4.0.21-19.el8_8.noarch
dnf-plugin-subscription-manager-1.28.36-2.el8.x86_64
dnf-plugins-core-4.0.21-19.el8_8.noarch
libdnf-0.63.0-8.el8.x86_64
kpatch-dnf-0.2-5.el8.noarch
dnf-data-4.7.0-16.el8_8.noarch

How reproducible:
Always

Actual results:
Module in status disabled, while dependent modules are not

Expected results:
Module in status disabled, all dependent modules are also disabled

Additional info:
The similar rule can be applied for module enable

Comment 1 Jaroslav Mracek 2023-07-31 09:09:48 UTC
I think the request is valid, but fix would be very difficult. Disabled operation is not handled as remove but as an exclude, therefore it creates unsatisfied dependency. The change would require to change the scheme of modular solver (not deliverable during lifecycle of RHEL). As a workaround I suggest to manually disable `rust-toolset`.


Note You need to log in before you can comment on or make changes to this bug.