Closed Bug 1526033 Opened 5 years ago Closed 5 years ago

Remove server side coalescing of HTML document sources

Categories

(DevTools :: Debugger, enhancement)

enhancement
Not set
normal

Tracking

(firefox67 fixed)

RESOLVED FIXED
Firefox 67
Tracking Status
firefox67 --- fixed

People

(Reporter: bhackett1024, Assigned: bhackett1024)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

Attached patch patchSplinter Review

The server has a fair amount of logic to consolidate Debugger.Sources for multiple HTML inline sources into a single source actor. This is pretty complex, muddies the definition of what a source actor is, and isn't necessary anymore after the changes in bug 1518884 and bug 1524374. The server can send multiple actors for inline sources in the same URL to the client, and those actors will all be associated with the Source for that URL in the client. When the client sets a breakpoint, it does so by specifying just the URL, and the server figures out which Debugger.Source objects might need to apply the breakpoint.

Attachment #9042268 - Flags: review?(lsmyth)
Comment on attachment 9042268 [details] [diff] [review]
patch

Review of attachment 9042268 [details] [diff] [review]:
-----------------------------------------------------------------

::: devtools/server/actors/object.js
@@ +837,4 @@
>  
>      // Catch any errors if the source actor cannot be found
>      try {
> +      source = this.hooks.sources().getSourceActorsByURL(stack.source)[0];

Too bad this is a string and not a Debugger.Object :(
Attachment #9042268 - Flags: review?(lsmyth) → review+

(In reply to Logan Smyth [:loganfsmyth] from comment #1)

Comment on attachment 9042268 [details] [diff] [review]
patch

Review of attachment 9042268 [details] [diff] [review]:

::: devtools/server/actors/object.js
@@ +837,4 @@

 // Catch any errors if the source actor cannot be found
 try {
  •  source = this.hooks.sources().getSourceActorsByURL(stack.source)[0];
    

Too bad this is a string and not a Debugger.Object :(

I don't know this code, but it looks like |stack| is a SavedFrame in which case it could predate the debugger attach. Once bug 1447244 lands we'll be able to get a source ID off of the saved frame and can map it back to the actual Debugger.Source (unless the underlying source was been GC'ed). (Bug 1447244 doesn't actually make this change though.)

Pushed by bhackett@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/bbbb61aaec5f
Remove server side coalescing of HTML document sources, r=lsmyth.
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 67
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: