Open topic with navigation

# get-stack-trace

Returns the call stack at the current position of a paused session. The call stack shows the name of the function that is currently running, the function that called the current function, and so on, back to the starting point of the script.

NOTE:

You can only use this command when Lua execution is paused, for example by a breakpoint or as a result of the `break` command. To set a breakpoint, use the `set-breakpoint` command.

`/action=luaDebug&command=get-stack-trace[&session=SessionID]`

Type: Synchronous

Parameter Name | Description | Required
--- | --- | ---
`Session` | To return the call stack for a single session, instead of every session, set this parameter to the session ID. You can retrieve a session ID by using the get-status command. | No

## Example

    http://localhost:7000/action=luadebug&command=get-stack-trace&session=246a7677d3433b798dc8246b5ebf7b23

## Response

    <autnresponse xmlns:autn="http://schemas.autonomy.com/aci/">
      <action>LUADEBUG</action>
      <response>SUCCESS</response>
      <responsedata>
        <data>
          <command>get-stack-trace</command>
          <session id="246a7677d3433b798dc8246b5ebf7b23">
            <frames>
              <function name="another_function" source="scripts/my_script.lua:30" />
              <function name="my_function" source="scripts/my_script.lua:25" />
              <function name="handler" source="scripts/my_script.lua:6" />
            </frames>
          </session>
        </data>
      </responsedata>
    </autnresponse>

© 2018 Micro Focus or one of its affiliates | Send documentation feedback to Micro Focus Close Send documentation feedback To open the configured email client on this computer, open an email window. Otherwise, copy the information below to a web mail client, and send this email to swpdl.idoldocsfeedback@microfocus.com. We appreciate your feedback! Product: Topic Title: Help Topic: Feedback:

_FT_HTML5_bannerTitle.htm