[wp-trac] [WordPress Trac] #62583: Ensure HTML Processor step adds to element_queue
WordPress Trac
noreply at wordpress.org
Wed Nov 27 11:08:40 UTC 2024
#62583: Ensure HTML Processor step adds to element_queue
-------------------------+-----------------------------
Reporter: jonsurrell | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: HTML API | Version: 6.6
Severity: normal | Keywords:
Focuses: |
-------------------------+-----------------------------
There are some cases where the `step` functions in the HTML processor
return `true`, but do not add anything to the element queue. When `step`
returns true, it should indicate the progress has been made progressing
the document and there are tokens to process.
[https://github.com/WordPress/wordpress-
develop/blob/9840f032815c0f427ae729a02d038cd5b0d2c919/src/wp-includes
/html-api/class-wp-html-processor.php#L756-L768 There is a todo in code
right now describing this situation]:
> In some cases, probably related to the adoption agency
> algorithm, this call to step() doesn't create any new
> events. Calling it again creates them. Figure out why
> this is and if it's inherent or if it's a bug. Looping
> until there are events or until there are no more
> tokens works in the meantime and isn't obviously wrong.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/62583>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list