Hi Surabh,

it was a known issue:

https://issues.apache.org/jira/browse/KARAF-1018

But I wasn't able to reproduce.

I will try to reproduce and reopen the Jira.

Regards
JB

On 04/06/2012 09:46 PM, Saurabh Garg wrote:
Hello,

I am getting the following error when extending karaf.shell.console. I
have an Action class which does not have any arguments but has couple
of options.
e.g.
cleanConfig
cleanConfig -force
cleanConfig -force -verbose

When I use tab completion after typing cleanConfig, I get the following error:

java.lang.ArrayIndexOutOfBoundsException: -1
         at java.util.ArrayList.get(ArrayList.java:324)
         at 
org.apache.karaf.shell.console.completer.ArgumentCompleter.complete(ArgumentCompleter.java:307)
         at 
org.apache.karaf.shell.console.completer.AggregateCompleter$Completion.complete(AggregateCompleter.java:86)
         at 
org.apache.karaf.shell.console.completer.AggregateCompleter.complete(AggregateCompleter.java:51)
         at 
org.apache.karaf.shell.console.completer.CommandsCompleter.complete(CommandsCompleter.java:56)
         at 
org.apache.karaf.shell.console.jline.CompleterAsCompletor.complete(CompleterAsCompletor.java:32)
         at jline.console.ConsoleReader.complete(ConsoleReader.java:1473)
         at jline.console.ConsoleReader.readLine(ConsoleReader.java:1231)
         at jline.console.ConsoleReader.readLine(ConsoleReader.java:1089)
         at org.apache.karaf.shell.console.jline.Console.run(Console.java:194)
         at org.apache.karaf.shell.console.Main.run(Main.java:191)
         at org.apache.karaf.shell.console.Main.run(Main.java:89)

Thanks in advance for any help,

Saurabh

--
Jean-Baptiste Onofré
[email protected]
http://blog.nanthrax.net
Talend - http://www.talend.com

Reply via email to