Bug 1027281 - [RHEVM-SHELL]: x-identifier auto-completion doesn't work in permissions context for vm object
Summary: [RHEVM-SHELL]: x-identifier auto-completion doesn't work in permissions cont...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine-cli
Version: 3.3.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: 3.3.0
Assignee: Ravi Nori
QA Contact: Ilia Meerovich
URL:
Whiteboard: infra
: 1033079 (view as bug list)
Depends On:
Blocks: 3.3snap3
TreeView+ depends on / blocked
 
Reported: 2013-11-06 13:23 UTC by Michael Pasternak
Modified: 2018-12-04 16:13 UTC (History)
7 users (show)

Fixed In Version: is25
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-01-21 22:14:56 UTC
oVirt Team: Infra
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 21046 0 None None None Never
oVirt gerrit 21142 0 None None None Never

Description Michael Pasternak 2013-11-06 13:23:22 UTC
Description of problem:

append of -identifier suffix for vm object at permission auto-completion doesn't
work for list/show/remove commands.

e.g

"list permissions vm" <TAB> produces "list permissions --vm" while should be
"list permissions --vm-identifier"

Comment 1 Ravi Nori 2013-11-06 21:43:09 UTC
There are two options for "list permissions vm". vm and vmpool

Should we autocomplete to --vm-identifier or show "vm" and "vmpool" as options

Comment 2 Michael Pasternak 2013-11-07 12:48:37 UTC
(In reply to Ravi Nori from comment #1)
> There are two options for "list permissions vm". vm and vmpool
> 
> Should we autocomplete to --vm-identifier or show "vm" and "vmpool" as
> options

you can't do that as you have ambiguity at /vm e.g
"list permissions vm" vm can stand for vm or for vmpool,

the right way to solve this use-case is to stop expending vm/vmpool to
--vm-identifier/--vmpool-identifier,

i.e we should append -identifier not at auto-completion time, but at options list
building time, this way you'll have [vm-identifier, vmpool-identifier] in
the options list and auto-completion will only add prefix '--' once
monovalent/definitive expression has been chosen,

this way, machine can easily distinguish between vm-<TAB> and vmpool-<TAB>

Comment 3 Michael Pasternak 2013-11-21 16:14:26 UTC
*** Bug 1033079 has been marked as a duplicate of this bug. ***

Comment 4 Michael Pasternak 2013-11-26 08:57:15 UTC
fixed in 3.3.0.11-1

Comment 5 Ilia Meerovich 2013-11-26 11:36:07 UTC
imeerovi@imeerovi ~/git/ART (master) $ sudo rpm -q rhevm-cli
rhevm-cli-3.3.0.11-1.el6ev.noarch
imeerovi@imeerovi ~/git/ART (master) $ rhevm-shell 


 ==========================================
 >>> connected to RHEVM manager 3.3.0.0 <<<
 ==========================================


        
 ++++++++++++++++++++++++++++++++++++++++++
 
           Welcome to RHEVM shell
 
 ++++++++++++++++++++++++++++++++++++++++++
        
    
[RHEVM shell (connected)]# list permissions v
vm-identifier            vmpool-identifier        vnicprofile-identifier   
[RHEVM shell (connected)]# list permissions vm
vm-identifier       vmpool-identifier   
[RHEVM shell (connected)]# list permissions vm
vm-identifier       vmpool-identifier   
[RHEVM shell (connected)]#

Comment 7 Itamar Heim 2014-01-21 22:14:56 UTC
Closing - RHEV 3.3 Released

Comment 8 Itamar Heim 2014-01-21 22:22:22 UTC
Closing - RHEV 3.3 Released


Note You need to log in before you can comment on or make changes to this bug.