Bug #29109
closedHost edit fails with (ActionView::Template::Error): undefined method `+' for nil:NilClass
Description
Host edit fails with (ActionView::Template::Error): undefined method `+' for nil:NilClass
Steps to Reproduce:
1. Create a VM using with username + ssh_pub_key + script_command
2. VM would create successfully
3. Now try to Edit that VM
Hosts => All Hosts => VM name => Edit
Actual results:
on UI shows : undefined method `+' for nil:NilClass
Expected results:
Able to Edit
Additional info:
/var/log/foreman/production.log
2020-02-21T02:30:21 [W|app|00897148] Action failed
2020-02-21T02:30:21 [D|app|00897148] Backtrace for 'Action failed' error (ActionView::Template::Error): undefined method `+' for nil:NilClass
/opt/theforeman/tfm/root/usr/share/gems/gems/foreman_azure_rm-2.0.6/app/models/foreman_azure_rm/azure_rm_compute.rb:191:in `script_command'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/actionview-5.2.1/lib/action_view/helpers/tags/base.rb:42:in `public_send'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/actionview-5.2.1/lib/action_view/helpers/tags/base.rb:42:in `value'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/actionview-5.2.1/lib/action_view/helpers/tags/base.rb:53:in `value_before_type_cast'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/actionview-5.2.1/lib/action_view/helpers/tags/text_field.rb:15:in `block in render'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/actionview-5.2.1/lib/action_view/helpers/tags/text_field.rb:15:in `fetch'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/actionview-5.2.1/lib/action_view/helpers/tags/text_field.rb:15:in `render'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/actionview-5.2.1/lib/action_view/helpers/form_helper.rb:1136:in `text_field'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/actionview-5.2.1/lib/action_view/helpers/form_helper.rb:1680:in `text_field'
Updated by The Foreman Bot about 4 years ago
- Pull request https://github.com/theforeman/foreman_azure_rm/pull/77 added
Updated by Aditi Puntambekar about 4 years ago
- Status changed from New to Ready For Testing
Updated by Aditi Puntambekar about 4 years ago
- Status changed from Ready For Testing to Closed
Applied in changeset foreman_azure_rm|e34b6b1a727434c83ae62106836ace59f251f3d7.