[wp-trac] [WordPress Trac] #35667: Maximum execution time error in WP_Text_Diff_Renderer_Table

WordPress Trac noreply at wordpress.org
Sat Oct 20 08:35:44 UTC 2018


#35667: Maximum execution time error in WP_Text_Diff_Renderer_Table
--------------------------+-----------------------
 Reporter:  ocean90       |       Owner:  pento
     Type:  defect (bug)  |      Status:  assigned
 Priority:  normal        |   Milestone:  5.0
Component:  Revisions     |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:
--------------------------+-----------------------

Comment (by pento):

 In [changeset:"43775" 43775]:
 {{{
 #!CommitTicketReference repository="" revision="43775"
 Revisions: Improve performance of `WP_Text_Diff_Renderer_Table`.

 `WP_Text_Diff_Renderer_Table` is used to generate the diff view in
 revisions, but there were some cases that could cause it to take excessive
 amounts of time to run.

 Some noteable cases include:
 - When a large number of new lines were inserted in the middle of the post
 from one revision to the next.
 - When both revisions contain >100 lines.
 - When either revision contains a lot of long lines.

 In one extreme test case, the diff view took over a minute to generate.
 With this change, it now takes less than a second.

 See #35667.
 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/35667#comment:22>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list