Project

General

Profile

Actions

Bug #21704

closed

Rerunning a ReX job with JobTemplate not in current Org/Loc shows undefined method `input_values' for nil:NilClass

Added by Ivan Necas over 6 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Foreman
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1515082

Description of problem: We were working on verifying https://bugzilla.redhat.com/show_bug.cgi?id=1500263. After upgrade from 6.2.12 > 6.3 snap 25, we were trying to rerun/ rerun failed the ReX job which was created on 6.2.12. But clicking submit button gives error as Oops, we're sorry but something went wrong undefined method `input_values' for nil:NilClass.

Version-Release number of selected component (if applicable): Satellite 6.3 snap 25

How reproducible: always

Steps to Reproduce:
1. Install 6.2.12
2. Perform some remote execution job (atleast one successful and one failed)
3. Upgrade to satellite 6.3 snap 25
4. Try to rerun/ rerun failed the ReX job

Actual results:
Clicking submit gave Oops, we're sorry but something went wrong undefined method `input_values' for nil:NilClass and production.log showed 500 Internal Server Error. (see attachments)

Expected results:
ReX job should rerun successfully.

Additional info:

Actions #1

Updated by Ivan Necas over 6 years ago

  • Subject changed from After upgrade from 6.2 > 6.3, Rerunning the ReX job shows undefined method `input_values' for nil:NilClass to After upgrade from 6.2 > 6.3, Rerunning the ReX job shows undefined method `input_values' for nil:NilClass
  • Category set to Foreman
Actions #2

Updated by Adam Ruzicka over 6 years ago

  • Subject changed from After upgrade from 6.2 > 6.3, Rerunning the ReX job shows undefined method `input_values' for nil:NilClass to Rerunning a ReX job with JobTemplate not in current Org/Loc shows undefined method `input_values' for nil:NilClass

The bug is caused by templates not being assigned to Organizations/Locations. This happens after an upgrade is already handled in another issue1

How reproducible: always

Steps to reproduce:
1) Run a job
2) Go to Hosts > Job Templates
3) Edit the template
4) Remove the template from current Organization and Location
5) Rerun the job from 1
6) (optional) notice the job form is malformed (missing some fields, displaying different values in Job category and Job template fields)
7) Click submit anyway

[1] - http://projects.theforeman.org/issues/21888

Actions #3

Updated by The Foreman Bot almost 6 years ago

  • Status changed from New to Ready For Testing
  • Assignee set to Adam Ruzicka
  • Pull request https://github.com/theforeman/foreman_remote_execution/pull/358 added
Actions #4

Updated by Anonymous over 5 years ago

  • Status changed from Ready For Testing to Closed
Actions

Also available in: Atom PDF