Bug 1319752

Summary: Creating a container with incorrect/invalid image name raises: undefined method `full_messages' for []:Array
Product: Red Hat Satellite Reporter: Sachin Ghai <sghai>
Component: Container ManagementAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED DUPLICATE QA Contact: Katello QA List <katello-qa-list>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.2.0CC: bbuckingham, lpramuk
Target Milestone: UnspecifiedKeywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-04-08 12:47:37 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
undefined method `full_messages' for []:Array when creating container with invalid image none

Description Sachin Ghai 2016-03-21 12:32:37 UTC
Created attachment 1138580 [details]
undefined method `full_messages' for []:Array when creating container with invalid image

Description of problem: I was trying to reproduce one bz where we need to check if raised error contains link to 'Satellite6 ticketing system' instead of foreman ticketing system. So to reproduce that, I created a container with incorrect image name, when I submitted the new container wizard, I got following error:


2016-03-21 08:10:51 [app] [I] Started PUT "/wizard_states/8/steps/environment" for 10.65.193.200 at 2016-03-21 08:10:51 -0400
2016-03-21 08:10:51 [app] [I] Processing by Containers::StepsController#update as HTML
2016-03-21 08:10:51 [app] [I]   Parameters: {"utf8"=>"✓", "authenticity_token"=>"rUKv4ZleB4al8fjWv2U5LbDbL4mJB1NK6yFXvOKelk4=", "docker_container_wizard_states_environment"=>{"tty"=>"0", "attach_stdin"=>"1", "attach_stdout"=>"1", "attach_stderr"=>"1"}, "button"=>"", "wizard_state_id"=>"8", "id"=>"environment"}
2016-03-21 08:10:53 [app] [W] Action failed
 | NoMethodError: undefined method `full_messages' for []:Array
 | /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_docker-2.0.1/app/controllers/containers/steps_controller.rb:61:in `create_container'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_docker-2.0.1/app/controllers/containers/steps_controller.rb:22:in `update'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_controller/metal/implicit_render.rb:4:in `send_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/abstract_controller/base.rb:189:in `process_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_controller/metal/rendering.rb:10:in `process_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/abstract_controller/callbacks.rb:20:in `block in process_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:113:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:113:in `call'


Version-Release number of selected component (if applicable):
sat6.2 snap4

How reproducible:
always

Steps to Reproduce:
1. create a new container with invalid image.
2.
3.

Actual results:
16-03-21 08:10:53 [app] [W] Action failed
 | NoMethodError: undefined method `full_messages' for []:Array


Expected results:
user should get proper error message instead of :
Oops, we're sorry but something went wrong undefined method `full_messages' for []:Array

Additional info:

Comment 3 Lukas Pramuk 2016-04-08 12:47:37 UTC

*** This bug has been marked as a duplicate of bug 1243140 ***