Skip to Content
Technical Articles
Author's profile photo Marcello Urbani

Debugging ABAP in visual studio code

My visual studio code plugin just gained the ability of debugging ABAP code straight from the server, like Eclipse does

It’s still pretty basic for now, will probably add features in the future

Assigned Tags

      10 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Matthew Billingham
      Matthew Billingham

      Really good work. It's nice to have an alternative.

      Author's profile photo Shai Sinai
      Shai Sinai

      Amazing!

      Keep up the good work

      Author's profile photo Enno Wulff
      Enno Wulff

      That's really cool!

      Author's profile photo Song Zhi Chong
      Song Zhi Chong

      I press CTRL+Shift+F11 ,but I can't see debug console. which steps do I miss ?

      Author's profile photo Marcello Urbani
      Marcello Urbani
      Blog Post Author

      Ctrl+Shift+F11 runs the unit tests

      You will see the debug console if:

      1. you enabled the debug mode (F5)
      2. you have a breakpoint somewhere in the test or the code under test

      Debugging dialog application is not supported (yet?)

      Author's profile photo Tom Höpping
      Tom Höpping

      Amazing, keep up the good work!!

      Author's profile photo Prabhat Kumar
      Prabhat Kumar

      I have tried with F5, debugger is activated but all the controls are in display mode.In the problems section, one warning is displaying( Missing Property "root") at workspace.json file.

      Author's profile photo Marcello Urbani
      Marcello Urbani
      Blog Post Author

      can't debug SAPGUI stuff, only APIs/RFC fms, unit tests

      To debug a sapgui application I would have to control a slave sapgui, couldn't figure out how.

      If you write an unit test you can debug it, otherwise reports can't be debugged in vscode.

       

      Author's profile photo Prabhat Kumar
      Prabhat Kumar

      Thank you for reply!

      I have tried to debug the unit test of a class however stil the same result, debug session started and the debug toolbar has appeared on the top of the editor but no debug actions (like F10 or F11) are active to proceed further. There is an warning message also displaying with ( Missing Property "root") at workspace.json file.

      my workspace.json file is configured like:

      {
          "folders": [
              {
                  "name": "APL(ABAP)",
                  "uri": "adt://apl"
              }
          ],
          "launch": {
              "version": "0.2.0",
              "configurations": [
                  {
                      "type": "abap",
                      "request": "attach",
                      "name": "Attach to server",
                      "connId": "${command:abapfs.pickAdtRootConn}"
                  }
              ]
          }
      }
      Is something need to add in the configurations in workspace.json file for debugging?
      Author's profile photo Marcello Urbani
      Marcello Urbani
      Blog Post Author

      Configuration is fine.

      Once you're in debug mode set a breakpoint where you want to debug and then  either press ctrl+shift+f11 or run command "AbapFs run unit tests"