This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 10519 - Parser-inserted script must lose its parser-insertedness if the 'already started' flag does not get set when the parser tries to run the script
Summary: Parser-inserted script must lose its parser-insertedness if the 'already star...
Status: CLOSED FIXED
Alias: None
Product: HTML WG
Classification: Unclassified
Component: pre-LC1 HTML5 spec (editor: Ian Hickson) (show other bugs)
Version: unspecified
Hardware: All All
: P1 critical
Target Milestone: ---
Assignee: Ian 'Hixie' Hickson
QA Contact: HTML WG Bugzilla archive list
URL: http://hsivonen.iki.fi/test/moz/scrip...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-09-01 09:27 UTC by Henri Sivonen
Modified: 2010-10-04 14:49 UTC (History)
4 users (show)

See Also:


Attachments

Description Henri Sivonen 2010-09-01 09:27:13 UTC
See http://hsivonen.iki.fi/test/moz/script-setting-src-on-parser-inserted-script.html
(All 4 engines let scripts cause the parser-inserted empty scripts to be executed.)

The spec says "When a script element that is neither marked as having "already started" nor marked as being "parser-inserted" experiences one of the events listed in the following list, the user agent must synchronously run the script  element:"

However, the steps also need to be run if a script experience one of the events if the script was originally inserted by the parser but the script didn't get its "already started" flag set when the parser tried to run the script.

The simple solution is to unset the parser-inserted flag if the parser's attempt to run the script fails to cause "already started" to be set.
Comment 1 Ian 'Hixie' Hickson 2010-09-25 19:25:52 UTC
EDITOR'S RESPONSE: This is an Editor's Response to your comment. If you are satisfied with this response, please change the state of this bug to CLOSED. If you have additional information and would like the editor to reconsider, please reopen this bug. If you would like to escalate the issue to the full HTML Working Group, please add the TrackerRequest keyword to this bug, and suggest title and text for the tracker issue; or you may create a tracker issue yourself, if you are able to do so. For more details, see this document:
   http://dev.w3.org/html5/decision-policy/decision-policy.html

Status: Accepted
Change Description: see diff given below
Rationale: Concurred with reporter's comments.
Comment 2 contributor 2010-09-25 19:26:35 UTC
Checked in as WHATWG revision r5496.
Check-in comment: Allow parser-inserted scripts to rerun if they failed to be run by the parser.
http://html5.org/tools/web-apps-tracker?from=5495&to=5496
Comment 3 Henri Sivonen 2010-09-28 11:00:15 UTC
The way this was specced is more awkward than what I was looking for, but the result is the same.

FWIW, what I was looking for was the steps where the parser invokes the "run" algorithm to check for "already started" after the "run" algorithm terminates and setting parser-inserted to false if already started is false.