RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1774096 - network role broken with Ansible Engine 2.9 due to missing python-jmespath
Summary: network role broken with Ansible Engine 2.9 due to missing python-jmespath
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: rhel-system-roles
Version: 7.7
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: 7.8
Assignee: Pavel Cahyna
QA Contact: David Jež
URL:
Whiteboard:
Depends On: 1774150
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-11-19 14:40 UTC by Pavel Cahyna
Modified: 2020-02-04 19:27 UTC (History)
5 users (show)

Fixed In Version: rhel-system-roles-1.0-10.el7_7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-02-04 19:27:07 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2020:0407 0 None None None 2020-02-04 19:27:15 UTC

Description Pavel Cahyna 2019-11-19 14:40:18 UTC
Description of problem:

Ansible Engine 2.9 repos for RHEL 7 do not include the python-jmespath package anymore, needed by the json_query filter. This filter is used in the network role (and will be used elsewhere), so the network role now fails.

How reproducible:
easily when using official Ansible Engine 2.9 to run system roles

Steps to Reproduce:
run network role tests (tests_default.yml against localhost is enough)

Actual results:
FAILED! => {"msg": "The conditional check 'not
network_packages is subset(ansible_facts.packages.keys())' failed. The
error was: An unhandled exception occurred while templating '{{
_network_provider_setup[network_provider]['packages'] }}'.
Error was a <class 'ansible.errors.AnsibleError'>,
original message: An unhandled exception occurred while templating
'{u'initscripts': {u'service_name': u'{{
network_service_name_default_initscripts }}', u'packages': u'{{
network_packages_default_initscripts }}'}, u'nm': {u'service_name':
u'{{ network_service_name_default_nm }}', u'packages': u'{{
network_packages_default_nm }}'}}'.
Error was a <class 'ansible.errors.AnsibleError'>,
original message: An unhandled exception occurred while templating '{{
['ethtool'] + _network_packages_default_initscripts_bridge|select()|list()
+ _network_packages_default_initscripts_network_scripts|select()|list()
}}'.
Error was a <class 'ansible.errors.AnsibleError'>,
original message: An unhandled exception occurred while templating
'[u\"{% if ['bridge'] in network_connections|json_query('[*][type]')
and ( (ansible_distribution in ['RedHat', 'CentOS'] and
ansible_distribution_major_version is version('7', '<=')) or
(ansible_distribution == 'Fedora' and
ansible_distribution_major_version is version('28', '<=')) )
%}bridge-utils{% endif %}\"]'.
Error was a <class 'ansible.errors.AnsibleError'>, original message:
You need to install \"jmespath\" prior to running json_query
filter\n\n
The error appears to be in
'/usr/share/ansible/roles/rhel-system-roles.network/tasks/main.yml':
line 20, column 3, but may\nbe elsewhere in the file depending on the
exact syntax problem.\n\n
The offending line appears to be:\n\n# Therefore install packages only
when rpm does not find them\n- name: Install packages\n  ^ here\n"}

Expected results:
tests should succeed

Additional info:

Similar problem occured in RHEL 8 when python-jmespath was removed from AE repositories for RHEL 8 and was solved by adding python-jmespath as a dependency of rhel-system-roles (bz1660559). The same approach will need to be taken here. Note that the package will need to be re-added - it was added in bz1489592 for a similar reason, as a dependency of Ansible then, see bz1484910 - but was deprecated with the rest of Ansible and its dependecies, bz1533106, and readding it to composes requires a new Maitai process.

Comment 4 errata-xmlrpc 2020-02-04 19:27:07 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2020:0407


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