#4079 www: fix for non-existent target_info
Merged by mikem. Opened by tkopecek.
tkopecek/koji issue4078  into  master

Download 4079.patch

Related: https://pagure.io/koji/issue/4078

:thumbsup:

Just to clarify (since cheetah doesn't give us good traces) the issue occurs inside the printValue function that is defined inside the taskinfo template. It has this stanza

  #elif $key in ('build_target', 'target_info')
<a href="buildtargetinfo?targetID=$value['id']">$value['name']</a>

This function is used to print the task parameters. The code is assuming that either of these keys will map to a dictionary. The existing code replaces 'target' and 'build_target' parameters with a sanitized built_target parameter that is a dict, however prior to this PR it did not do this for target_info even though printValue seems to expect this.

See also: PR #3455

At any rate, this fix is fine, though I think it ensures that printValue will never encounter a target_info key.

Metadata Update from @tkopecek:
- Pull-request tagged with: testing-ready

Metadata Update from @mfilip:
- Pull-request tagged with: testing-done

Commit d8668410 fixes this pull-request

Pull-Request has been merged by mikem

Metadata