Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.

Bug 1379906

Summary: Traceback when dependency of plugin is removed and plugin calls the dependency
Product: [Fedora] Fedora Reporter: Bill Crawford <billcrawford1970>
Component: dnfAssignee: rpm-software-management
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: medium    
Version: 24CC: jmracek, mluscon, packaging-team-maint, rpm-software-management, vmukhame
Target Milestone: ---Keywords: EasyFix, Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: dnf-2.5.0-2.fc26 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-06-09 19:05:42 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:
Embargoed:

Description Bill Crawford 2016-09-28 04:05:30 UTC
Description of problem:
Traceback due to removal of tracer plugin. I'm filing against dnf because the component field didn't seem to want to accept the plugin package name ...

Version-Release number of selected component (if applicable):
1.1.10-1.fc24

How reproducible:
Remove plugins until one causes a traceback from dnf.

Steps to Reproduce:
1. dnf install python3-dnf-plugins-extras-\*
2. dnf erase python3-dnf-plugins-extras-snapper # (succeeded)
3. dnf erase python3-dnf-plugins-extras-tracer  # (traceback, below)

Actual results:

[root@william ~]# dnf erase python3-dnf-plugins-extras-tracer
Dependencies resolved.
================================================================================================
 Package                                 Arch         Version              Repository      Size
================================================================================================
Removing:
 python2-psutil                          x86_64       3.2.1-5.fc24         @fedora        530 k
 python2-tracer                          noarch       0.6.11-1.fc24        @updates       325 k
 python3-dnf-plugins-extras-tracer       noarch       0.0.12-3.fc24        @updates       9.8 k

Transaction Summary
================================================================================================
Remove  3 Packages

Installed size: 865 k
Is this ok [y/N]: y
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Erasing     : python3-dnf-plugins-extras-tracer-0.0.12-3.fc24.noarch                      1/3 
  Erasing     : python2-tracer-0.6.11-1.fc24.noarch                                         2/3 
  Erasing     : python2-psutil-3.2.1-5.fc24.x86_64                                          3/3 
  Verifying   : python3-dnf-plugins-extras-tracer-0.0.12-3.fc24.noarch                      1/3 
  Verifying   : python2-tracer-0.6.11-1.fc24.noarch                                         2/3 
  Verifying   : python2-psutil-3.2.1-5.fc24.x86_64                                          3/3 

Removed:
  python2-psutil.x86_64 3.2.1-5.fc24                       python2-tracer.noarch 0.6.11-1.fc24  
  python3-dnf-plugins-extras-tracer.noarch 0.0.12-3.fc24  

DDEBUG:dnf:Cleaning up.
SUBDEBUG:dnf:
Traceback (most recent call last):
  File "/usr/lib/python3.5/site-packages/dnf/cli/main.py", line 60, in main
    return _main(base, args)
  File "/usr/lib/python3.5/site-packages/dnf/cli/main.py", line 120, in _main
    ret = resolving(cli, base)
  File "/usr/lib/python3.5/site-packages/dnf/cli/main.py", line 159, in resolving
    base._plugins.run_transaction()
  File "/usr/lib/python3.5/site-packages/dnf/plugin.py", line 82, in fn
    dnf.util.mapall(operator.methodcaller(method), self.plugins)
  File "/usr/lib/python3.5/site-packages/dnf/util.py", line 183, in mapall
    return list(map(fn, *seq))
  File "/usr/lib/python3.5/site-packages/dnf-plugins/tracer.py", line 70, in transaction
  File "/usr/lib64/python3.5/subprocess.py", line 950, in __init__
    restore_signals, start_new_session)
  File "/usr/lib64/python3.5/subprocess.py", line 1544, in _execute_child
    raise child_exception_type(errno_num, err_msg)
FileNotFoundError: [Errno 2] No such file or directory: 'tracer'
[Errno 2] No such file or directory: 'tracer'
CRITICAL:dnf:[Errno 2] No such file or directory: 'tracer'

Comment 1 Honza Silhan 2016-10-03 11:13:42 UTC
DNF should stop calling plugin hooks when the plugin is in transaction.remove_set or better define in demands if the plugin should be skipped this way.

Comment 2 Jaroslav Mracek 2017-05-11 11:07:27 UTC
I created a pull-request that should help: https://github.com/rpm-software-management/dnf/pull/807

Comment 3 Fedora Update System 2017-05-22 12:40:05 UTC
dnf-plugins-extras-2.0.1-1.fc26 dnf-plugins-core-2.1.0-1.fc26 libdnf-0.9.0-1.fc26 dnf-2.5.0-1.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-92e5a01da8

Comment 4 Fedora Update System 2017-05-22 16:39:42 UTC
dnf-2.5.0-1.fc26, dnf-plugins-core-2.1.0-1.fc26, dnf-plugins-extras-2.0.1-1.fc26, libdnf-0.9.0-1.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-92e5a01da8

Comment 5 Fedora Update System 2017-05-24 08:31:13 UTC
dnf-2.5.0-1.fc26 dnf-plugins-core-2.1.0-1.fc26 dnf-plugins-extras-2.0.1-1.fc26 dnfdaemon-0.3.17-3.fc26 libdnf-0.9.0-1.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-92e5a01da8

Comment 6 Fedora Update System 2017-05-24 14:32:39 UTC
dnf-2.5.0-2.fc26 dnf-plugins-core-2.1.0-1.fc26 dnf-plugins-extras-2.0.1-1.fc26 dnfdaemon-0.3.18-1.fc26 libdnf-0.9.0-1.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-92e5a01da8

Comment 7 Fedora Update System 2017-05-25 19:17:12 UTC
dnf-2.5.0-2.fc26, dnf-plugins-core-2.1.0-1.fc26, dnf-plugins-extras-2.0.1-1.fc26, dnfdaemon-0.3.18-2.fc26, libdnf-0.9.0-1.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-92e5a01da8

Comment 8 Fedora Update System 2017-06-09 19:05:42 UTC
dnf-2.5.0-2.fc26, dnf-plugins-core-2.1.0-1.fc26, dnf-plugins-extras-2.0.1-1.fc26, dnfdaemon-0.3.18-2.fc26, libdnf-0.9.0-1.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.