Created attachment 1063664 [details]
Description of problem:
Opening 'Discovery Rules' page results with an error:
undefined method `name' for nil:NilClass
Version-Release number of selected component (if applicable):
Open 'Discovery Rules'
Steps to Reproduce:
Satellite was upgraded from 6.1.0 to 6.1.1
Upstream seems to solve this issue at https://github.com/theforeman/foreman_discovery/blob/develop/app/views/discovery_rules/index.html.erb#L19
Can this be cherry-picked?
Which commit sha is that? Can you please prepare cherry pick request for that?
Reproduced. If we delete Hostgroup after associating it to Discovery Rule.
Upstream patch: https://github.com/theforeman/foreman_discovery/commit/7b7b2acde1c51a33ca09a2b56b1f635c84d09c53
The above commit only masks the fact a rule does not have a hostgroup.
Upstream patch done: https://github.com/theforeman/foreman_discovery/pull/212
Cherry pick the UI patch as well ^^^
Upstream bug assigned to email@example.com
Moving to POST since upstream bug http://projects.theforeman.org/issues/11574 has been closed
Applied in changeset commit:foreman_discovery|82d93bfb7748482ca32ab293d8c0b47c38c4c018.
Created hostgroup Foo, with discovery rule Bar. Tried to delete hostgroup Foo, it's no longer possible: "Cannot delete record because dependent discovery rules exist"
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.