Selective refresh very slow or fails when JS Widgets active on 4.7-RC1
westonruter opened this issue · 2 comments
westonruter commented
For some reason when the JS Widgets plugin is active, selective refresh of post fields is 5x slower.
- Active JS Widgets.
- Make a change to a post title.
- Notice that it response slowly compared when JS Widgets it not active.
Short circuiting WP_Customize_Post_Field_Partial::render_callback()
causes the slowness to go away, but naturally none of the code runs. Seems like a problem in setup_postdata()
or in the filters that apply in WP_Customize_Post_Field_Partial::render_post_title()
.
westonruter commented
With the JS Widgets plugin activated, hooks that take longer than 0.1s accumulatively:
tag: the_title
duration sum: 0.746872s
count: 61
tag: wp_insert_post_data
duration sum: 2.182451s
count: 14
tag: the_post
duration sum: 1.321027s
count: 4
And with the JS Widgets plugin deactivated, hooks that take longer than 0.1s accumulatively:
tag: wp_insert_post_data
duration sum: 0.218897
count: 14
tag: the_post
duration sum: 0.117028
count: 4
Count is the number of callbacks that get invoked.
westonruter commented
It turns out to be an issue with Stream. PR opened to fix in that plugin: xwp/stream#898