Project

General

Profile

Actions

Bug #20580

closed

"hammer host-collection list --host" produce error 500 - undefined method `order'

Added by Brad Buckingham over 7 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Normal
Category:
Host Collections
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1479284

Description of problem:

When filtering `hammer host-collection list` by host (both --host-id and --host), it fails with 500 error and message 'undefined method `order' for #<Array:0x00000014c20740>'

  1. hammer -d -v -u admin -p changeme host-collection list --host-id="2"

[ INFO 2017-08-08 04:45:09 HammerCLI::MainCommand] Called with options: {"option_verbose"=>true, "option_debug"=>true, "option_username"=>"admin", "option_password"=>"***"}
[ INFO 2017-08-08 04:45:09 HammerCLIKatello::HostCollection] Called with options: {}
[ INFO 2017-08-08 04:45:09 HammerCLIKatello::HostCollection::ListCommand] Called with options: {"option_host_id"=>2}
[ INFO 2017-08-08 04:45:09 API] Server: https://intel-wildcatpass-05.khw.lab.eng.bos.redhat.com
[ INFO 2017-08-08 04:45:09 API] GET /katello/api/host_collections
[DEBUG 2017-08-08 04:45:09 API] Params: {
"page" => 1,
"per_page" => 1000,
"sort" => {},
"host_id" => 2
}
[DEBUG 2017-08-08 04:45:09 API] Headers: {
:params => {
"page" => 1,
"per_page" => 1000,
"sort" => {},
"host_id" => 2
}
}
[DEBUG 2017-08-08 04:45:09 API] Using authenticator: HammerCLIForeman::Api::InteractiveBasicAuth
[ERROR 2017-08-08 04:45:09 API] 500 Internal Server Error
[DEBUG 2017-08-08 04:45:09 API] {
"displayMessage" => "undefined method `order' for #<Array:0x007f10606de008>",
"errors" => [
[0] "undefined method `order' for #<Array:0x007f10606de008>"
]
}

Version-Release number of selected component (if applicable):
Satellite 6.3 Snap 10:
  • satellite-6.3.0-16.0.beta.el7sat.noarch
  • foreman-1.15.2-1.el7sat.noarch
  • katello-3.4.4-2.el7sat.noarch
  • tfm-rubygem-hammer_cli_foreman-0.10.2-1.el7sat.noarch
  • tfm-rubygem-hammer_cli_katello-0.10.0-1.el7sat.noarch

How reproducible:
Always

Steps to Reproduce:
1. Create host
2. Create host collection
3. Add host to that host collection
4. List host collections and filter by that host, like:
hammer -d -v host-collection list --host-id="2"

Actual results:
500 error

Expected results:
Host collections should be listed


Related issues 1 (0 open1 closed)

Has duplicate Katello - Bug #20586: Internal server error when viewing the activation-key host collectionsDuplicateBrad Buckingham08/14/2017Actions
Actions #1

Updated by Brad Buckingham over 7 years ago

  • Subject changed from "hammer host-collection list --host" produce error 500 - undefined method `order' to "hammer host-collection list --host" produce error 500 - undefined method `order'
  • Target version set to 208
Actions #2

Updated by The Foreman Bot over 7 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/Katello/katello/pull/6909 added
Actions #3

Updated by Brad Buckingham over 7 years ago

  • Has duplicate Bug #20586: Internal server error when viewing the activation-key host collections added
Actions #4

Updated by Eric Helms over 7 years ago

  • Translation missing: en.field_release set to 286
Actions #5

Updated by Brad Buckingham about 7 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF