Bug #12203
closedError when editing hosts
Description
I get this error when editing hosts in either foreman 1.9 foreman-xen 0.1.4 or foreman 1.10 foreman-xen 0.2.0
Trace:
TypeError
can't convert String into Integer
/opt/theforeman/tfm/root/usr/share/gems/gems/foreman_xen-0.1.3/app/helpers/xen_compute_helper.rb:56:in `[]'
/opt/theforeman/tfm/root/usr/share/gems/gems/foreman_xen-0.1.3/app/helpers/xen_compute_helper.rb:56:in `hosts_controller_compute_attribute_map'
/opt/theforeman/tfm/root/usr/share/gems/gems/foreman_xen-0.1.3/app/helpers/xen_compute_helper.rb:4:in `compute_attribute_map'
/opt/theforeman/tfm/root/usr/share/gems/gems/foreman_xen-0.1.3/app/views/compute_resources_vms/form/xenserver/_base.html.erb:2:in `_b235499ae0f6c21fd4c7d435d20fb6c0'
Updated by Boris Kreitchman about 9 years ago
Could you please check this PR https://github.com/theforeman/foreman-xen/pull/29?
Updated by Alejandro Falcon about 9 years ago
Worked perfectly editing, thanks a lot. Will try new hosts in a moment to make sure...
Updated by Alejandro Falcon about 9 years ago
Note: worked in 1.10 but in 1.9:
NoMethodError
undefined method `sr' for nil:NilClass
/opt/rh/ruby193/root/usr/share/gems/gems/foreman_xen-0.1.2/app/helpers/xen_compute_helper.rb:49:in `hosts_controller_compute_attribute_map'
/opt/rh/ruby193/root/usr/share/gems/gems/foreman_xen-0.1.2/app/helpers/xen_compute_helper.rb:4:in `compute_attribute_map'
/opt/rh/ruby193/root/usr/share/gems/gems/foreman_xen-0.1.2/app/views/compute_resources_vms/form/xenserver/_base.html.erb:2:in `__opt_rh_ruby____root_usr_share_gems_gems_foreman_xen_______app_views_compute_resources_vms_form_xenserver__base_html_erb__2229982193861734816_97923200'
Updated by Boris Kreitchman about 9 years ago
Which 1.9 and fog do you have - foreman-1.9.2 and fog-1.32.0?
Updated by Alejandro Falcon about 9 years ago
Creating hosts works good on both 1.9.2 and 1.10
Updated by Anonymous about 9 years ago
- Status changed from New to Ready For Testing
- Pull request https://github.com/theforeman/foreman-xen/pull/29 added
- Pull request deleted (
)
Updated by Boris Kreitchman about 9 years ago
I've added a check to PR, please try again.
Btw, is it the same VM you're editing on 1.9 or 1.10 or there are different ones? Anything unusual with its' disk configuration?
Updated by Boris Kreitchman about 9 years ago
- Status changed from Ready For Testing to Closed
- % Done changed from 0 to 100
Applied in changeset foreman-xen|9e059b28eb338f5193f181d610a0b90380429c6d.