diff --git a/salt/modules/yumpkg.py b/salt/modules/yumpkg.py index 4b10f34c0b..064a6aaa45 100644 --- a/salt/modules/yumpkg.py +++ b/salt/modules/yumpkg.py @@ -181,7 +181,9 @@ def _check_versionlock(): Ensure that the appropriate versionlock plugin is present ''' if _yum() == 'dnf': - if int(__grains__.get('osmajorrelease')) < 26: + if six.PY3: + vl_plugin = 'python3-dnf-plugins-extras-versionlock' + elif int(__grains__.get('osmajorrelease')) < 26: vl_plugin = 'python-dnf-plugins-extras-versionlock' else: vl_plugin = 'python2-dnf-plugins-extras-versionlock'