Closed
Bug 1449304
Opened 7 years ago
Closed 5 years ago
Expose the node debugger while running macros on a local install
Categories
(developer.mozilla.org Graveyard :: KumaScript, enhancement, P3)
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: sheppy, Unassigned)
Details
(Keywords: in-triage, Whiteboard: [specification][type:feature][points:6+])
What problem would this feature solve?
======================================
Node.js has the ability to expose the V8 debugger on a port so that you can use the Chrome developer tools to debug Node code. By implementing support for this while running KumaScript macros, we could debug macros much more easily than we currently can (mostly by adding debug logging and trial and error).
Who has this problem?
=====================
Core contributors to MDN
How do you know that the users identified above have this problem?
==================================================================
We all talk about this regularly.
How are the users identified above solving this problem now?
============================================================
log.debug and a lot of test, experiment, repeat until it works, mostly.
Do you have any suggestions for solving the problem? Please explain in detail.
==============================================================================
When running node code, you can specify the --inpsect flag on the command line to enable remote debugging support; this exposes the debugger through the same port and protocol that Chrome uses for remote debugging.
Ideally, we would be able to toggle inspection on just for template code itself, but if that's not possible, there are options.
Or, if that's too complicated, we can get a "poor man's" implementation: sSince KumaScript macros run within workers on the KumaScript app, the entire KumaScript runtime would likely have to be run in debug mode. However, we can at least somewhat restrict things to macro code by adding code to macros-worker.js in KumaScript to set a breakpoint on the first line of the macro right before calling tmpl.execute() to run the macro's code, or within Templates.js before running the code in its Fiber. This wouldn't contain the debugging session within macros but would at least let us do some stepping around and inspection of variables.
Is there anything else we should know?
======================================
Updated•7 years ago
|
Keywords: in-triage
Priority: -- → P3
Whiteboard: [specification][type:feature] → [specification][type:feature][points:6+]
Comment 1•5 years ago
|
||
MDN Web Docs' bug reporting has now moved to GitHub. From now on, please file content bugs at https://github.com/mdn/sprints/issues/ and platform bugs at https://github.com/mdn/kuma/issues/.
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → WONTFIX
Updated•5 years ago
|
Product: developer.mozilla.org → developer.mozilla.org Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•