Bug #4271

cvs output for gpg subcommand doesn't work

Added by Og Maciel almost 8 years ago. Updated over 3 years ago.

Target version:
Bugzilla link:
Pull request:
Fixed in Releases:
Found in Releases:


[root@qetello03 ~]# hammer gpg info --id 5
ID:              5
Name:            yj8266h
Organization:    ACME_Corporation
interning empty string
Content:         [root@qetello03 ~]# hammer -v --output csv gpg info --id 5
[ERROR 2014-02-05 14:37:50 Exception] interning empty string
interning empty string
[ERROR 2014-02-05 14:37:50 Exception]

ArgumentError (interning empty string):
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/fields.rb:43:in `to_sym'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/fields.rb:43:in `follow_path'
    /usr/lib/ruby/gems/1.8/gems/logging-1.8.1/lib/logging/logger.rb:435:in `inject'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/fields.rb:42:in `each'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/fields.rb:42:in `inject'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/fields.rb:42:in `follow_path'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/fields.rb:34:in `get_value'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/adapter/csv.rb:31:in `print_collection'
    /usr/lib/ruby/gems/1.8/gems/logging-1.8.1/lib/logging/logger.rb:435:in `inject'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/adapter/csv.rb:29:in `each'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/adapter/csv.rb:29:in `inject'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/adapter/csv.rb:29:in `print_collection'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/adapter/csv.rb:28:in `each'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/adapter/csv.rb:28:in `print_collection'
    /usr/lib/ruby/gems/1.8/gems/fastercsv-1.5.4/lib/faster_csv.rb:1077:in `generate'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/adapter/csv.rb:73:in `generate'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/adapter/csv.rb:24:in `print_collection'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/adapter/csv.rb:20:in `print_record'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/output/output.rb:20:in `print_record'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/./apipie/../abstract.rb:150:in `print_record'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli_foreman-0.0.18/lib/hammer_cli_foreman/commands.rb:127:in `print_data'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/./apipie/read_command.rb:10:in `execute'
    /usr/lib/ruby/gems/1.8/gems/clamp-0.6.2/lib/clamp/command.rb:67:in `run'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/./apipie/../abstract.rb:22:in `run'
    /usr/lib/ruby/gems/1.8/gems/clamp-0.6.2/lib/clamp/subcommand/execution.rb:11:in `execute'
    /usr/lib/ruby/gems/1.8/gems/clamp-0.6.2/lib/clamp/command.rb:67:in `run'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/./apipie/../abstract.rb:22:in `run'
    /usr/lib/ruby/gems/1.8/gems/clamp-0.6.2/lib/clamp/subcommand/execution.rb:11:in `execute'
    /usr/lib/ruby/gems/1.8/gems/clamp-0.6.2/lib/clamp/command.rb:67:in `run'
    /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.18/lib/hammer_cli/./apipie/../abstract.rb:22:in `run'
    /usr/lib/ruby/gems/1.8/gems/clamp-0.6.2/lib/clamp/command.rb:125:in `run'
    /usr/bin/hammer:19:in `load'

Related issues

Related to Katello - Bug #4272: gpg info Closed2014-02-05


#1 Updated by Og Maciel almost 8 years ago

We should probably do the same thing that was done for partition_table:

root@qetello03 ~]# hammer partition_table list
ID | NAME                         | OS FAMILY
3  | AutoYaST LVM                 | Suse
1  | AutoYaST entire SCSI disk    | Suse
2  | AutoYaST entire virtual disk | Suse
4  | Jumpstart default            | Solaris
5  | Jumpstart mirrored           | Solaris
9  | Junos default fake           | Junos
6  | Kickstart default            | Redhat
8  | Preseed custom LVM           | Debian
7  | Preseed default              | Debian
[root@qetello03 ~]# hammer partition_table info --id 6
Id:          6
Name:        Kickstart default
OS Family:   Redhat
Created at:  2014/02/04 20:27:28
Updated at:  2014/02/04 20:27:28

[root@qetello03 ~]# hammer partition_table dump --id 6
kind: ptable
name: Community Kickstart Disklayout
- CentOS 5
- CentOS 6
- Fedora 16
- Fedora 17
- Fedora 18
- Fedora 19
- RedHat 5
- RedHat 6
clearpart --all --initlabel

#2 Updated by Og Maciel almost 8 years ago

3:01 PM mccun934 ElGuapo: not sure what dump has todo with --csv output
3:01 PM mccun934 re: your comment
3:02 PM ElGuapo mccun934: display the content of the key only when using dump
3:02 PM ElGuapo otherwise don't bother
3:02 PM mccun934 but that is an entirely different output format
3:02 PM mccun934 ElGuapo: seems apples vs oranges
3:02 PM jsherrill ElGuapo: i'm not sure there'd be any point to an info command if we didn't print the key itself
3:03 PM ElGuapo mccun934: it is. partha asked what he should do with displaying the content... I said, don't display unless you use dump
3:03 PM ElGuapo jsherrill: partition_table does it...
3:03 PM ElGuapo info tells me which orgs, repos
3:03 PM ElGuapo that is useful
3:04 PM jsherrill ah yeah, i guess it does show repos

#3 Updated by Tomáš Strachota almost 8 years ago

  • Status changed from New to Closed
  • Assignee set to Tomáš Strachota

#4 Updated by Tomáš Strachota almost 8 years ago

#5 Updated by Tomáš Strachota over 5 years ago

  • Project changed from Hammer CLI to Katello
  • Category changed from 74 to Hammer

#6 Updated by Justin Sherrill over 5 years ago

  • Legacy Backlogs Release (now unused) set to 166

Also available in: Atom PDF