NativeScript / NativeScript/android
The run-time takes 5+ seconds to respond to Debugger.enable
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 563
- Forks
- 144
- Avg merge
- 10h 46m
- Merged PRs (30d)
- 14
Description
Please, provide the details below:
Did you verify this is a real problem by searching Stack Overflow and the other open issues in this repo?
Yes
Tell us about the problem
The run-time takes 5+ seconds to respond to Debugger.enable
Please provide the following version numbers that your issue occurs with:
- CLI: 3.3.1
Please tell us how to recreate the issue in as much detail as possible.
This is reproducible with:
https://github.com/NativeScript/template-master-detail-ts
https://github.com/NativeScript/template-master-detail-ng
https://github.com/NativeScript/template-master-detail-kinvey
against an Android Pixel.
clone https://github.com/NativeScript/template-master-detail-ts
cd template-master-detail-ts
tns platform add android
tns debug android --start
After receiving the Debugger.enable request the run-time would trigger scriptParsed events for all sources in the project (500+ files) first and only then would respond to the Debugger.enable request.
Starting a debug session against any of the listed projects would time out as the JavaScript debugger (Microsoft implementation) in Visual Studio has a non-configurable 5 second timeout on all requests.
In {N} Sidekick the debug session would not timeout but it would still take more than 5 seconds to initialize.
Please note that after receiving a response to Debugger.enable the JavaScript debugger in Visual Studio would start sending Debugger.setBreakpointByUrl for all pre-set breakpoints (again 5s timeout) and if the run-time does not respond to a request the breakpoint would remain inactive.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the delay with the listed template-master-detail projects on an Android Pixel using tns debug android --start. Trace how the runtime handles Debugger.enable, scriptParsed, and Debugger.setBreakpointByUrl; done means debugger initialization and preset breakpoints complete without the five-second timeout.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, javascript
- Domain
- devtools, mobile-dev, performance
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 32/100