Actions
Bug #24651
closedCannot remove packages from content host web UI
Difficulty:
easy
Triaged:
Yes
Bugzilla link:
Pull request:
Description
An error is raised such as this:
2018-08-17T13:21:24 [I|app|] Started PUT "/api/v2/hosts/3/packages/remove" for ::1 at 2018-08-17 13:21:24 +0000 2018-08-17T13:21:24 [I|app|e3f5e] Processing by Katello::Api::V2::HostPackagesController#remove as JSON 2018-08-17T13:21:24 [I|app|e3f5e] Parameters: {"id"=>3, "packages"=>[{"id"=>2790, "name"=>"walrus", "nvrea"=>"walrus-0.71-1.noarch", "nvra"=>"walrus-0.71-1.noarch", "selec ted"=>true}], "api_version"=>"v2", "host_id"=>"3", "host_package"=>{"id"=>3, "packages"=>[{"id"=>2790, "name"=>"walrus", "nvrea"=>"walrus-0.71-1.noarch", "nvra"=>"walrus-0.7 1-1.noarch", "selected"=>true}]}} 2018-08-17T13:21:24 [I|app|e3f5e] Current user set to admin (admin) 2018-08-17T13:21:24 [D|app|e3f5e] Current location set to none 2018-08-17T13:21:24 [D|app|e3f5e] Current organization set to Default Organization 2018-08-17T13:21:24 [E|app|e3f5e] Katello::HttpErrors::BadRequest: {"id"=>2790, "name"=>"walrus", "nvrea"=>"walrus-0.71-1.noarch", "nvra"=>"walrus-0.71-1.noarch", "selected" =>true} is not a valid package name
We should be sending an array of package names and not an array of hashes with misc. package data from the table
Actions