IP Library › Granted Patent US 10,664,384
Granted Patent B2
US 10,664,384 · App. 13/831,801 · Granted May 26, 2020

Javascript debugging using just my code

Inventors: Robert Alan Paveza (Redmond, WA); Andrew Richard Sterland (Bellevue, WA); Timothy Scott Rice (Seattle, WA); Gregg Bernard Miskelly (Seattle, WA); Nikhil Khandelwal (Kirkland, WA)
Assignee: MICROSOFT TECHNOLOGY LICENSING, LLC
G06F11/362G06F11/3664
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 10,664,384
App. No.
13/831,801
Granted
May 26, 2020
Kind
B2
Abstract

The present invention extends to methods, systems, and computer program products for stepping through JavaScript code in a debugger without landing on errors in library or open source code. A debugger receives user inputs designating one or more segments of the JavaScript code as library code. The debugger then performs debugging operations on the JavaScript code. The debugging operations including a stepping operation for stepping through the JavaScript code to identify errors only in user-generated segments of the JavaScript code, wherein the user-generated segments correspond to code that was not designated as library code.

Claims (34)

1. A computer system, comprising:

a processor; and

a memory coupled to the processor, the memory having program instructions stored thereon that, upon execution by the processor, cause the computer system to:

step through a scripting language code document compiled from a plurality of source documents, wherein at least one source document comprises user-generated code and at least one different source document comprises library code only, to identify whether errors are present in the scripting language code document;

determine that an identified error was generated by a library code segment based on determining that particular code that generated the error is from the at least one different source document comprising the library code only;

based on determining the identified error was generated by the library code segment, scan an execution stack to identify a most recently executed user-generated code segment, wherein scanning the execution stack comprises locating a document boundary within the scripting language code document by identifying annotations within the scripting language code document that indicate a beginning and an end of at least one portion of the at least one source document comprising the user-generated code; and

identify, based upon the located document boundary, that a code statement provided after the located document boundary is user-generated code and presenting the code statement on a debugger user interface.

2. The computer system of claim 1 , wherein the document boundary is a code-level comment included in the scripting language code document.

3. The computer system of claim 1 , wherein an evaluation is performed to determine whether a user is interested in reviewing errors in the at least one different source document comprising the library code only.

4. The computer system of claim 1 , wherein user-generated code segments and library code segments are associated with separate documents identified by a source map.

5. The computer system of claim 1 , wherein a relationship between the debugger user interface and a script engine debugger is mediated by a process debug manager.

6. The computer system of claim 5 , wherein the process debug manager translates user inputs into a step behavior of the script engine debugger.

7. The computer system of claim 5 , wherein the process debug manager instructs the script engine when to run.

8. The computer system of claim 7 , wherein the process debug manager instructing the script engine when to run is transparent to a user.

9. The computer system of claim 5 , wherein the process debug manager instructs the script engine to step out of a function call.

10. A method for debugging code in a computer system, the method comprising:

stepping through a scripting language code document compiled from a plurality of source documents, wherein at least one source document comprises user-generated code and at least one different source document comprises library code only, to identify whether errors are present in the scripting language code document;

determining that an identified error was generated by a library code segment based on determining that particular code that generated the error is from the at least one different source document comprising the library code only;

based on determining the identified error was generated by the library code segment, scanning an execution stack to identify a most recently executed user-generated code segment, wherein scanning the execution stack comprises locating a document boundary within the scripting language code document by identifying annotations within the scripting language code document that indicate a beginning and an end of at least one portion of the at least one source document comprising the user-generated code; and

identifying, based upon the located document boundary, that a code statement provided after the located document boundary is user-generated code and presenting the code statement on a debugger user interface.

11. The method of claim 10 , wherein the document boundary is a code-level comment included in the scripting language code document.

12. The method of claim 10 , wherein an evaluation is performed to determine whether a user is interested in reviewing errors in the at least one different source document comprising the library code only.

13. The method of claim 10 , wherein user-generated code segments and library code segments are associated with separate documents identified by a source map.

14. The method of claim 10 , wherein the annotations indicate when a script is going to transition between documents.

15. One or more hardware storage devices having stored thereon computer-executable instructions that are executable by one or more processor(s) of a computing system to cause the computing system to at least:

step through a scripting language code document compiled from a plurality of source documents, wherein at least one source document comprises user-generated code and at least one different source document comprises library code only, to identify whether errors are present in the scripting language code document;

determine that an identified error was generated by a library code segment based on determining that particular code that generated the error is from the at least one different source document comprising the library code only;

based on determining the identified error was generated by the library code segment, scan an execution stack to identify a most recently executed user-generated code segment, wherein scanning the execution stack comprises locating a document boundary within the scripting language code document by identifying annotations within the scripting language code document that indicate a beginning and an end of at least one portion of the at least one source document comprising the user-generated code; and

identify, based upon the located document boundary, that a code statement provided after the located document boundary is user-generated code and presenting the code statement on a debugger user interface.

16. The one or more hardware storage devices of claim 15 , wherein the document boundary is a code-level comment included in the scripting language code document.

17. The one or more hardware storage devices of claim 15 , wherein an evaluation is performed to determine whether a user is interested in reviewing errors in the at least one different source document comprising the library code only.

18. The one or more hardware storage devices of claim 15 , wherein user-generated code segments and library code segments are associated with separate documents identified by a source map.

19. The one or more hardware storage devices of claim 18 , wherein the source map identifies document boundaries and content.

20. The one or more hardware storage devices of claim 18 , wherein a relationship between the debugger user interface and a script engine debugger is mediated by a process debug manager.

Assignments (3)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 9, 2015
From: MICROSOFT CORPORATION
To: MICROSOFT TECHNOLOGY LICENSING, LLC
Reel/Frame 039025/0454 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Feb 10, 2014
From: PAVEZA, ROBERT ALAN; STERLAND, ANDREW RICHARD; RICE, TIMOTHY SCOTT; MISKELLY, GREGG BERNARD; KHANDELWAL, NIKHIL
To: MICROSOFT CORPORATION
Reel/Frame 032186/0418 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Mar 16, 2013
From: PAVEZA, ROBERT ALAN; STERLAND, ANDREW RICHARD; RICE, TIMOTHY SCOTT; MISKELLY, GREGG BERNARD; KHANDELWAL, NIKHIL
To: MICROSOFT CORPORATION
Reel/Frame 030024/0304 →
Continuity (1)
Related Publication 20140282417A1 · Sep 18, 2014
Cited By (1)
US 12,591,498