Open Bug 1930594 Opened 9 months ago Updated 2 months ago

Don't emit load events when creating new top-level browsing contexts (tabs) when "about:blank" is loaded and emit contextCreated event at the end

Categories

(Remote Protocol :: WebDriver BiDi, task, P2)

task
Points:
5

Tracking

(Not tracked)

People

(Reporter: Sasha, Unassigned)

References

(Depends on 1 open bug, Blocks 1 open bug)

Details

(Whiteboard: [webdriver:backlog])

After reading the html spec on the topic of creating a top-level browsing context with about:blank, I've noticed that in the browsing context creation algorithm we’re supposed to create and load a document, but it looks like it skips all the post parsing steps, where we’re supposed to send browsingContext.domContentLoaded and browsingContext.load events, and just jumps to the end of it (to the step 11). So it looks like per spec we shouldn’t send the load events. At the same time, it seems like we should send the browsingContext.contextCreated event almost at the end (see step 12) before we return.
According to Alex, if we don't send load events but send the contextCreated event when a tab is fully loaded, that should be enough for Puppeteer. But at the moment of this bug creation, Chrome sends the load events for such case and send browsingContext.contextCreated events very early (before load events).

Blocks: 1756597, 1756617

Moving it already to M14 as discussed yesterday in the meeting.

Whiteboard: [webdriver:m14]
Points: --- → 5
Priority: -- → P3

Test updates will be synced soon via bug 1932829.

Depends on: 1932829
Whiteboard: [webdriver:m14] → [webdriver:m15]
Priority: P3 → P2
Whiteboard: [webdriver:m15] → [webdriver:m16]
Whiteboard: [webdriver:m16] → [webdriver:m17]
Whiteboard: [webdriver:m17] → [webdriver:backlog]

Looks like since I've created this bug, Chrome updated their implementation, and they do not emit load events for "about:blank" anymore. But since there are no really requests to fix it now, I think it still makes sense to wait for bug 543435 to land before working on this bug.

Depends on: sync-about-blank
You need to log in before you can comment on or make changes to this bug.