Bug #27458
openHost association broken in v1.0.0
Description
Associating hosts is now broken in foreman-xen v1.0.0. | /opt/theforeman/tfm/root/usr/share/gems/gems/fog-core-1.45.0/lib/fog/core/collection.rb:18:in `+' | /opt/theforeman/tfm/root/usr/share/gems/gems/fog-core-1.45.0/lib/fog/core/collection.rb:18:in `+' | /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_xen-0.7.1/app/models/concerns/fog_extensions/xenserver/server.rb:64:in `interfaces' | /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_xen-0.7.1/app/models/foreman_xen/xenserver.rb:231:in `associated_host' | /usr/share/foreman/app/services/compute_resource_host_associator.rb:21:in `associate_vm' | /usr/share/foreman/app/services/compute_resource_host_associator.rb:13:in `block in associate_hosts' | /opt/theforeman/tfm/root/usr/share/gems/gems/fog-core-1.45.0/lib/fog/core/collection.rb:18:in `each' | /opt/theforeman/tfm/root/usr/share/gems/gems/fog-core-1.45.0/lib/fog/core/collection.rb:18:in `each' | /usr/share/foreman/app/services/compute_resource_host_associator.rb:11:in `associate_hosts'
Updated by Alejandro Falcon about 5 years ago
Same as the other ticket. its just the folder but the files are the latest cloned from github.
Updated by Alejandro Falcon about 5 years ago
Missed the actual error line:
| TypeError: no implicit conversion of nil into Array
Alejandro Falcon wrote:
Associating hosts is now broken in foreman-xen v1.0.0. | /opt/theforeman/tfm/root/usr/share/gems/gems/fog-core-1.45.0/lib/fog/core/collection.rb:18:in `+' | /opt/theforeman/tfm/root/usr/share/gems/gems/fog-core-1.45.0/lib/fog/core/collection.rb:18:in `+' | /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_xen-0.7.1/app/models/concerns/fog_extensions/xenserver/server.rb:64:in `interfaces' | /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_xen-0.7.1/app/models/foreman_xen/xenserver.rb:231:in `associated_host' | /usr/share/foreman/app/services/compute_resource_host_associator.rb:21:in `associate_vm' | /usr/share/foreman/app/services/compute_resource_host_associator.rb:13:in `block in associate_hosts' | /opt/theforeman/tfm/root/usr/share/gems/gems/fog-core-1.45.0/lib/fog/core/collection.rb:18:in `each' | /opt/theforeman/tfm/root/usr/share/gems/gems/fog-core-1.45.0/lib/fog/core/collection.rb:18:in `each' | /usr/share/foreman/app/services/compute_resource_host_associator.rb:11:in `associate_hosts'
Updated by Alejandro Falcon about 5 years ago
This issue was introduced with this change:
https://github.com/theforeman/foreman-xen/commit/5ed96188624962c5745d0ded6fdbe8fdc8dcb0d3
Rolling it back makes the association work again.