cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Mobile Development Kit: Problem Debugging on VSCODE

fapurcino
Explorer
0 Likes
895

Hi,

Currently I'm working on an extension for SAP Asset Manager. Most of time I use WebIDE, but now I need to debug some rules. I'm using VSCode Plugin.

I've set the breakpoint and when running on the IOS Simulator it stops correctly, but I can't inspect the newly created variables. As can be seen in following screenshot.

It seems that the sourcemap is outdated, but I tried the following workflows:

- Run Build Task and restart application. Same issue

- Run Build Task, Create Client again, restart the app. Same issue

- Run build task, create client again, run build task, restart the app. Same issue.

In my launch json:

request: "launch"

type: "MDK"

platform: "ios"

sourceMaps: "true"

watch: "true"

tnsArgs: ["--timeout"]

Has someone had the same issue? Any tip about solving this issue?

In the past it worked in other rules, but the "tns watch" were taking too much time to rebuild changes in webpack and relaunch the app, something about 5 minutes.

Best regards,

Fabio Purcino

Accepted Solutions (1)

Accepted Solutions (1)

fapurcino
Explorer
0 Likes

Hi Hong-wu Luo,

Thanks for your help. The AppRoot was already set but after you told me about large projects I set incrementalBundle to speed up the process.

I guess maybe it is related to my old laptop. I`ve just changed my old Core I5 Macbook for a new Core I9 one, and most of Vscode glitches disappeared.

Thank you so much

Answers (1)

Answers (1)

0 Likes

I think that you should add an argument "appRoot" to point to a folder of SAP Asset Manager in your launch.json. For example: "appRoot": "/Users/i062707/Example". After that, the latest sourcemap should be copied to SAP Asset Manager.

By the way, you may try to add another argument "incrementalBundle": true if your project is too large to rebuild changes in webpack.