All Apps and Add-ons

App Packager - Exception: , Value: list index out of range

MikeElliott
Communicator

Hi Team,

I'm attempting to package an app for an internal deployment.

I run the below command:

./splunk package app /Applications/Splunk/etc/apps/<my_app_name>/

I am then met with the below error:

An unforeseen error occurred:

    Exception: <type 'exceptions.IndexError'>, Value: list index out of range

Traceback (most recent call last):
  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/clilib/cli.py", line 1145, in main
    parseAndRun(argsList)
  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/clilib/cli.py", line 943, in parseAndRun
    retVal = makeRestCall(cmd=command, obj=subCmd, restArgList=objUnicode(argList), sessionKey=authInfo, timeout=timeout)
  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/rcUtils.py", line 666, in makeRestCall
    DISPLAY_CHARS[endpoint](cmd=cmd, obj=obj, type=etype, serverResponse=serverResponse, serverContent=serverContent, sessionKey=sessionKey, eaiArgsList=eaiArgsList)
  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/rcDisplay.py", line 187, in wrapper
    return f(**kwargs)
  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/rcDisplay.py", line 165, in wrapper
    return f(**kwargs)
  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/rcDisplay.py", line 706, in displayApp
    d = nodeToPrimitive(atomFeed[0].rawcontents)
  File "/Applications/Splunk/lib/python2.7/site-packages/splunk/rest/format.py", line 382, in __getitem__
    return self.entries.__getitem__(idx)
IndexError: list index out of range


Please file a case online at http://www.splunk.com/page/submit_issue

This is a particularly enraging issue, as this worked perfectly fine yesterday, stopped working today and still does not work after a fresh install of Splunk Enterprise in my Dev environment.

Any suggestions?

1 Solution

MikeElliott
Communicator

I got this to work by doing the following:

/Applications/Splunk/bin/splunk package app <my_app_name>/

I would, however, still like to invite comment. I'd like to know what I was doing wrong so that I can avoid it in the future and not come up with solutions by rage-bashing XD

View solution in original post

0 Karma

MikeElliott
Communicator

I got this to work by doing the following:

/Applications/Splunk/bin/splunk package app <my_app_name>/

I would, however, still like to invite comment. I'd like to know what I was doing wrong so that I can avoid it in the future and not come up with solutions by rage-bashing XD

0 Karma

cduffey_splunk
Splunk Employee
Splunk Employee

This didn't work for me, but I was able to get the following to work:

cd to SPLUNK_HOME/etc/apps

SPLUNK_HOME/bin/splunk package app

0 Karma
Get Updates on the Splunk Community!

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

Splunk is officially part of Cisco

Revolutionizing how our customers build resilience across their entire digital footprint.   Splunk ...

Splunk APM & RUM | Planned Maintenance March 26 - March 28, 2024

There will be planned maintenance for Splunk APM and RUM between March 26, 2024 and March 28, 2024 as ...