You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Found this issue today when trying out fog-vsphere. It appears the recent changes to get_folder has introduced an error whenever get_raw_vmfolder is called from other resources such as clone_vm or list_folders.
The specific problem is get_raw_vmfolder calls get_folder and sets the type param to 'vm':
raiseArgumentError,"#{type} is unknown"iftype.blank?
Problem is string in ruby doesn't have that method available so it fails accordingly:
NoMethodError: undefined method `blank?' for "vm":String
The previous version of get_folder, in 2.4.0, didn't have this issue as it specifically converted the type param to a symbol if it was detected as the string 'vm':
The text was updated successfully, but these errors were encountered:
Ryuzavi
changed the title
get_raw_vmfolder method now fails due to 'blank?' method being attempted against strings for type param
get_raw_vmfolder method now fails due to blank? method being attempted against strings for type param
Nov 26, 2018
Ryuzavi
changed the title
get_raw_vmfolder method now fails due to blank? method being attempted against strings for type param
get_raw_vmfolder now fails due to blank? method being attempted against strings for type param
Nov 26, 2018
Hey
Found this issue today when trying out fog-vsphere. It appears the recent changes to
get_folder
has introduced an error wheneverget_raw_vmfolder
is called from other resources such asclone_vm
orlist_folders
.The specific problem is
get_raw_vmfolder
callsget_folder
and sets thetype
param to'vm'
:fog-vsphere/lib/fog/vsphere/requests/compute/get_folder.rb
Lines 48 to 50 in 443aa7b
Passing in a string for the
type
param now fails as a call to theblank?
method is performed as an argument check:fog-vsphere/lib/fog/vsphere/requests/compute/get_folder.rb
Line 26 in 443aa7b
Problem is string in ruby doesn't have that method available so it fails accordingly:
The previous version of
get_folder
, in 2.4.0, didn't have this issue as it specifically converted the type param to a symbol if it was detected as the string 'vm':fog-vsphere/lib/fog/vsphere/requests/compute/get_folder.rb
Lines 10 to 14 in df58b90
Cheers,
R.
The text was updated successfully, but these errors were encountered: