Bug 134689

Summary: Web Inspector: Uncaught Exception debugging iOS 7 NetworkAgent.loadResource is unavailable
Product: WebKit Reporter: Joseph Pecoraro <joepeck>
Component: Web InspectorAssignee: Joseph Pecoraro <joepeck>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, graouts, joepeck, timothy, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
[PATCH] Proposed Fix none

Description Joseph Pecoraro 2014-07-07 13:07:56 PDT
undefined is not a function (evaluating 'NetworkAgent.loadResource(frameIdentifier,sourceMapURL,sourceMapLoaded.bind(this))')

We should feature check the existence of this function in the two places it is used.
Comment 1 Radar WebKit Bug Importer 2014-07-07 13:08:12 PDT
<rdar://problem/17578914>
Comment 2 Joseph Pecoraro 2014-07-07 14:03:44 PDT
I'll look into this.
Comment 3 Joseph Pecoraro 2014-07-07 14:34:22 PDT
Created attachment 234511 [details]
[PATCH] Proposed Fix
Comment 4 Darin Adler 2014-07-07 16:13:05 PDT
Comment on attachment 234511 [details]
[PATCH] Proposed Fix

Might be good to add a comment explaining this is needed to target older versions so it’s not just deleted later.
Comment 5 WebKit Commit Bot 2014-07-07 16:45:28 PDT
Comment on attachment 234511 [details]
[PATCH] Proposed Fix

Clearing flags on attachment: 234511

Committed r170863: <http://trac.webkit.org/changeset/170863>
Comment 6 WebKit Commit Bot 2014-07-07 16:45:30 PDT
All reviewed patches have been landed.  Closing bug.
Comment 7 Timothy Hatcher 2014-07-08 12:17:56 PDT
We do typically add // COMPATIBILITY (iOS 7): ... comments for things like this. However, we have other places where we feature check without a comment (mainly for JSContext protocol omissions).
Comment 8 Joseph Pecoraro 2014-07-08 14:15:00 PDT
(In reply to comment #7)
> We do typically add // COMPATIBILITY (iOS 7): ... comments for things like this. However, we have other places where we feature check without a comment (mainly for JSContext protocol omissions).

Yep, that is exactly why I left it off here. We will want to fix this eventually so we get SourceMap support debugging JSContext scripts.