Bug 127629

Summary: Web Inspector: Move InspectorDebuggerAgent into JavaScriptCore
Product: WebKit Reporter: Joseph Pecoraro <joepeck>
Component: Web InspectorAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: bunhere, commit-queue, ggaren, graouts, gyuyoung.kim, joepeck, mark.lam, mkwst, rakuco, timothy, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
[PATCH] Proposed Fix
none
[PATCH] Proposed Fix sam: review+

Description Joseph Pecoraro 2014-01-25 13:29:55 PST
Now that we have all the pieces for DebuggerAgent (InjectedScript, ScriptDebugServer) move DebuggerAgent into JavaScriptCore.

I also just realized that because JSContext inspection only happens through the remote interface, other ports don't need to compile the JSGlobalObject{InspectorController,ScriptDebugServer,RuntimeAgent,DebuggerAgent} and the new EventLoop class. So leaving these files out of those port's builds. They can add them when enabling REMOTE_INSPECTOR or providing a way to access this without REMOTE_INSPECTOR.

After this lands, with one patch to WebInspectorUI to feature check for all missing agents we should have a working remote inspector for a JSContext!
Comment 1 Radar WebKit Bug Importer 2014-01-25 13:30:19 PST
<rdar://problem/15909749>
Comment 2 Joseph Pecoraro 2014-01-25 13:39:26 PST
Created attachment 222231 [details]
[PATCH] Proposed Fix

- Adds JSGlobalObject ScriptDebugServer, DebuggerAgent, and hooks it up in InspectorController
- Adds JSC EventLoop implementation when paused debugging a JSGlobalObject, separate from WebCore's EventLoop impl
- Adds test for console.assert pausing, which was untested before and had a slight path change
Comment 3 WebKit Commit Bot 2014-01-25 13:40:57 PST
Attachment 222231 [details] did not pass style-queue:


ERROR: Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp:39:  Alphabetical sorting problem.  [build/include_order] [4]
ERROR: Source/JavaScriptCore/inspector/agents/JSGlobalObjectDebuggerAgent.cpp:31:  Alphabetical sorting problem.  [build/include_order] [4]
Total errors found: 2 in 38 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 4 Joseph Pecoraro 2014-01-25 13:50:00 PST
Comment on attachment 222231 [details]
[PATCH] Proposed Fix

View in context: https://bugs.webkit.org/attachment.cgi?id=222231&action=review

> Source/JavaScriptCore/JavaScriptCore.vcxproj/JavaScriptCore.vcxproj.filters:-308
> -    <ClCompile Include="..\inspector\agents\JSGlobalObjectRuntimeAgent.cpp">
> -      <Filter>inspector</Filter>
> -    </ClCompile>

Oop, I'll also add the InspectorDebuggerAgent.* to the JSC.vcxproj.filters file. Not needed for compile, just for Visual Studio's UI.

> Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj:4634
> +				A503FA1C188E0FB000110F14 /* JSJavaScriptCallFrame.h in Headers */,

This looks unnecessary. From and old old version. I'll remove.
Comment 5 Joseph Pecoraro 2014-01-25 16:25:36 PST
Created attachment 222239 [details]
[PATCH] Proposed Fix

- Fixed style
- Added to more non-critical build files
- EFL build fix attempt with includes
Comment 6 Sam Weinig 2014-01-25 16:33:05 PST
Comment on attachment 222239 [details]
[PATCH] Proposed Fix

rs=me
Comment 7 Joseph Pecoraro 2014-01-26 00:35:13 PST
Landed <http://trac.webkit.org/changeset/162799>.