Dev Chat Summary: August 9th (4.9 week 2)

This post summarizes the dev chat meeting from August 9th (agendaSlack archive).

4.8.1 release feedback

  • Forums team hasn’t had to update the “4.8 Master List” post with any problems, a relatively smooth release altogether
  • No concerns identified that would require a subsequent immediate minor release

4.9 goals

  • @melchoyce and @westonruter have assembled a list 4.9 goals
  • @kadamwhite would like to see movement on REST API backlog tickets, specifically meta registration for object subtypes (#38323) and media permissions (#41445)
  • REST API roadmap document still being assembled, but not yet published
  • “Updating a plugin or theme via a ZIP file” and “drag and drop uploading of themes and plugins” are going to need support from contributors to the Upgrade/Install component
  • If you have interest in helping maintain the Upgrade/Install component (or any others) please reach out to @drewapicture

General announcements

#4-8, #4-8-1, #4-9, #dev-chat, #summary, #translation

Dev Chat Agenda for August 9th (4.9 week 2)

This is the agenda for the weekly dev meeting on August 9, 2017 at 20:00 UTC / August 9, 2017 at 20:00 UTC:

  • 4.8.1 release feedback
  • 4.9 goals
  • General announcements

If you have anything to propose to add to the agenda or specific items related to the above, please leave a comment below. See you there!

#4-8, #4-8-1, #4-9, #agenda, #dev-chat

Dev Chat Summary: August 2nd (4.9 week 1)

This post summarizes the dev chat meeting from August 2nd (agendaSlack archive).

4.8.1 RC2 feedback & planned release post-devchat

  • 4.8.1 includes fixes for the text widget, delayed yesterday due to performance issues identified
  • 4.8.1RC2 on WordPress.com stable, no longer experiencing the performance issues
  • No noticeable feedback in the forums regarding the text widget changes, Trac has been quiet in the widgets component
  • #41373 reported against 4.8, doesn’t seem to be a new regression introduced by 4.8.1 or a blocker
  • No concerns with the plan to release 4.8.1 after devchat

4.9 kickoff

  • 4.9 release schedule page is available, with particular highlights:
    • WordPress 4.9 will be the second “major” release of 2017 with the theme of editing code, managing plugins and themes, a user-centric way to customize a site, and polishing some recently added features over this last year.
    • October 4, 2017 is Beta 1 and feature project merge deadline.
    • October 30, 2017 is Release candidate and soft string freeze.
    • November 14, 2017 is 🎶 Target date for release of WordPress 4.9. 🎶
    • @melchoyce and @westonruter are co-Release Leads. 🎉
  • Updated set of goals for the 4.9 release and updates to the stale Customize component page coming soon (but first, release 4.8.1)

Editor / Gutenberg updates

Call for Component Maintainers

  • @drewapicture completed annual audit of Component Maintainers, some areas where new maintainers could be useful
  • The list on Make/Core reflects the most current list of maintainers
  • Please reach out if you’re interested in becoming a component maintainer

General announcements

  • @jorbin: submissions open for Kim Parsell Memorial Scholarship for WordCamp US
    • WordPress Foundation gives out a scholarship that covers the cost of hotel, transportation and a ticket for WordCamp US
    • Must be: person who self-identifies as female, active contributor to WordPress via a contributor team or a local meetup or WordCamp organizer, has financial need, and has never attended WordCamp US
    • No age limit on this scholarship, though older women are especially encouraged to apply
    • If you fit the requirements, please apply. If you know someone that qualifies, please encourage them to apply.

#4-8, #4-8-1, #4-9, #components, #core-editor, #core-restapi, #dev-chat, #gutenberg, #maintainership, #summary, #wordcamp

Dev Chat Agenda for August 2nd (4.9 week 1)

This is the agenda for the weekly dev meeting on August 2, 2017 at 20:00 UTC / August 2, 2017 at 20:00 UTC:

  • 4.8.1 RC2 feedback & planned release post-devchat
  • 4.9 kickoff
  • Call for Component Maintainers
  • General announcements

If you have anything to propose to add to the agenda or specific items related to the above, please leave a comment below. See you there!

#4-8, #4-8-1, #4-9, #agenda, #dev-chat

WordPress 4.8.1 release delayed by one day

The 4.8.1 release was due out today (August 1st), however a performance problem was raised during release preparations. Specifically, the ticket in question is #35293 and its problematic commit on the 4.8 branch has now been reverted, while the changes remain on trunk. A performance fix is pending in #41501, and it may be part of a subsequent 4.8.2 minor release.

We’ve re-scheduled the 4.8.1 release to occur after the core dev chat tomorrow, at August 2nd, 21:00 UTC.

In the mean time, please continue testing the release. A new 4.8.1-RC2 package (ZIP) has been published for you to triple check on your test environments. For more information on testing, see Beta Testing. The 4.8.1-RC2 release contains 29 maintenance fixes and enhancements since 4.8.0, chief among them are fixes to the rich Text widget and the introduction of the Custom HTML widget. For a full list of changes in the release, consult the tickets closed and the changesets committed.

#4-8-1

Fixes to Text widget and introduction of Custom HTML widget in 4.8.1

The 4.8 release caused issues for many sites that had custom HTML in Text widgets, which until now had been common practice. So we’ve been working hard on fixes in the 4.8.1 release which aim to simultaneously serve the needs of novice users and advanced users alike: the rich Text widget (introduced in 4.8), a legacy mode for the Text widget, and a Custom HTML widget.

For more background on the changes in 4.8, see Addition of TinyMCE to the Text Widget. To review, the Text widget in 4.8 includes TinyMCE—the same visual editor used for writing post content—and it looks like:

Text Widget Legacy Mode

The issues with the introduction of TinyMCE to the Text widget revolve around the ways that TinyMCE attempts to clean up HTML code by deleting empty elements (such as those for dashicons) and dropping attributes it may not recognize (such as HTML5 Microdata attributes). Also with the 4.8’s removal of the “automatically add paragraphs” checkbox, there were also issues related to paragraphs and line breaks being added incorrectly.

Note that the Text widget was already designed to preserve the old behavior of the widget until it was modified and thus upgraded, so there are many instances of Text widgets in the wild today that could very well begin to break upon being modified. For this reason the issues were not reported right away and instead started to trickle in steadily after the release.

There were various solutions that were considered, but the one that had the consensus among contributors was:

[Check if the Text widget] was previously saved from an older version of WordPress before TinyMCE was added to the Text widget. If it is such a pre-existing Text widget instance, then use heuristics to detect if TinyMCE would negatively impact the contents of the widget, including the auto-p checkbox being unchecked, whether there are empty tags, and whether there are spandivscript, or style tags. When the Text widget is in this legacy mode, it can have a notice that informs users of the new HTML Code widget and that it should be used going forward. Likewise, in the new mode when TinyMCE is present, when the Text (HTML) tab is selected, there can be a note (perhaps an admin pointer) that encourages users to use the HTML Code widget instead. By implementing this, novice users with basic content in their widgets win, and advanced users with custom HTML content in their widgets will cease from being negatively impacted.

The Text widget in legacy mode looks the same as the Text widget before 4.8, but with the addition of a new notice:

The legacy mode will only be presented for widgets created prior to 4.8.0 that have instance data which match the logic in the WP_Widget_Text::is_legacy_instance() method. The legacy mode will not be presented to newly created Text widgets. Once a Text widget is opened and saved in legacy mode, it will permanently stay in legacy mode. There is a new instance property called “visual” which will be set to false when a widget is saved in legacy mode. When a new Text widget is created, it is opened in the default visual mode and the new instance will get saved with visual=true.

Text Widget Filters

There is a change in how the filter instance property was used in 4.8.0: in that release, when a Text widget was modified, the fact that it had been upgraded was stored by overloading the filter boolean property to also have the value of "content", indicating that the widget gets content filters applied like a post does. Since this string is a truthy value, I reasoned it would normally work the same in filters that check ! empty( $instance['filter'] ), but it would fail in cases where a plugin tried true === $instance['filter']. So 4.8.1 reverts the overloading of the filter property to again be a boolean, and this should improve compatibility for widget_text filters. Whenever a Text widget is modified with the default visual mode (with TinyMCE) it will get both visual=true and filter=true saved in its instance. When a Text widget is modified in the legacy mode, it will always get visual=false and its filter property will reflect the checked state of the auto-paragraph checkbox.

Another note on filters: special consideration was made for shortcodes in the Text widget given the frequency of plugins and themes adding shortcode support (since the widget does not recognized them by default in core). Plugins and themes have done add_filter( 'widget_text', 'do_shortcode' ) to add support. Since the widget_text filter applies before the new widget_text_content filter (as of 4.8), it will apply before wpautop will have applied, resulting in the possibility of extra line breaks being added undesirably if the shortcode output has new line characters. So to help prevent that from happening, the Text widget will temporarily move the do_shortcode handler from widget_text to widget_text_content just in time while the filters are being applied. See the relevant logic.

Help Pointers

For users who are accustomed to pasting HTML into the Text widget, when an attempt is made to paste markup into the visual editor a pointer will be displayed informing them that they should paste it into the Text tab instead, or to alternatively use the new Custom HTML widget (see section below):

Likewise, when a user opens the Text tab, it will also open a pointer to inform them of the Custom HTML widget:

While pointers are normally displayed on upgrades, these pointers will be displayed even on new installs since they reflect changes to long-standing behavior for the Text widget that users have become accustomed to. Any tutorials that instruct users to use the Text widget for pasting in arbitrary HTML should be updated to instruct the users to select the Custom HTML widget instead.

Custom HTML Widget

For advanced users or for any use case where arbitrary HTML needs to be displayed in a widget (such as a signup form or a 3rd party JavaScript widget), there is now a dedicated “Custom HTML” widget that is specifically for this purpose. It looks very similar to the classic Text widget, except it has a monospace font and it lacks the auto-paragraph checkbox:

Since users are prompted (per the pointers above) to try using the Custom HTML widget instead of the Text widget for some use cases, it is important that the widget content be able to be freely copied between the Text widget and the Custom HTML widget. For this reason, the Custom HTML widget retains the application of the widget_text filters like the Text widget does. The type of widget for which the filter is applying can be determined by looking at the type of the WP_Widget instance being passed as the last filter argument. When the widget_text filter is applied, it will pass the second $instance parameter in the same format as the Text widget, with title, text (instead of content), and filter and visual properties that are always both set to false (as if the instance was in legacy non-visual mode). In addition to re-applying the widget_text filter, the Custom HTML widget has a dedicated widget_custom_html_content filter whereas the the Text widget has a dedicated widget_text_content filter.

In addition to filter compatibility, the Custom HTML widget also tries to retain theme styling compatibility by using the same widget_text CSS class name on the outer widget wrapper and textwidget on the inner wrapper around the content itself. For any themes that wish to style the Custom HTML widget alone, there are the widget_custom_html and custom-html-widget class names used on the outer and inner wrapper elements respectively. For themes that wish to style the Text widget alone and exclude the Custom HTML widget, the :not() pseudo selector can be used, for example .widget_text:not(.widget_custom_html) and .textwidget:not(.custom-html-widget) for the outer and inner wrappers, respectively.

The markup generated by a Custom HTML widget on the frontend will look like:

<section id="custom_html-6" class="widget_text widget widget_custom_html">
  <h2 class="widget-title">My Title</h2>
  <div class="textwidget custom-html-widget">My Content</div>
</section>

This same Custom HTML widget’s instance data will look like:

{
  "title": "My Title",
  "content": "My Content"
}

For more specifics on the Custom HTML widget, refer to the subclass: WP_Widget_Custom_HTML.

Here is a list of tickets related to the Text widget and Custom HTML widget which are closed in the 4.8.1 release:

  • #40907: Introduce widget dedicated for HTML code
  • #40951: New Text Widget – Switching Between Visual/Text Editor Strips Out Code
  • #40960: Set `’filter’ => ‘content’` on starter content “business info” widget
  • #40960: Widgets: The Text widget should respect the “Disable the visual editor when writing” setting
  • #40972: TinyMCE editor in Text widget does not have RTL contents
  • #40974: Updated text widget do not save text (when using paste)
  • #40986: Widgets: text widget and media widgets cannot be edited in accessibility mode
  • #41021: Text widget does not show Title field or TinyMCE editor
  • #41158:  Increase tinymce panel z-index
  • #41361: Text widget can raise JS error if customize-base is enqueued on widgets admin screen
  • #41386: Text Widget – Wording – Legacy Mode 4.8.1 beta
  • #41392: Theme styles for Text widget do not apply to Custom HTML widget
  • #41394: Text widget: Rename legacy mode to visual mode and improve back-compat for widget_text filters

 

#4-8-1, #dev-notes, #tinymce, #widgets

Dev Chat Summary: July 26th (4.8.1 week 6)

This post summarizes the dev chat meeting from July 26th (agendaSlack archive).

4.8.1 RC feedback & release timing

  • No issues on the widgets front
  • Those who reported breakage from 4.8 widget changes and have tested RC have said the fixes work
  • @westonruter to write a dev note
  • @westonruter and @obenland to work on 4.8.1 release on Tuesday, August 1st as per previous plan
  • @obenland to work with @pento or @azaozz on walk thru for releasing a minor version
  • Post-4.8.1 release action item: get more committers access & training on releasing / Mission Control

Editor / Gutenberg media intricacies

  • Last Fridays’ release of 0.6 slipped due to vacations, working to push it out as soon as feasible
  • Several media intricacies that could use help / discussion, especially Issue#1986
  • 100 PRs open that could use help in reviewing/testing
  • Gutenberg part of weekly agenda of #core-media meeting (Thursdays at 18:00 UTC)

General announcements

#4-8, #4-8-1, #core-editor, #dev-chat, #gutenberg, #summary

Dev Chat Agenda for July 26th (4.8.1 week 6)

This is the agenda for the weekly dev meeting on July 26, 2017 at 20:00 UTC / July 26, 2017 at 20:00 UTC:

  • 4.8.1 RC feedback & release timing
  • Editor / Gutenberg media intricacies
  • General announcements

If you have anything to propose to add to the agenda or specific items related to the above, please leave a comment below. See you there!

#4-8, #4-8-1, #agenda, #dev-chat

Dev Chat Summary: July 19th (4.8.1 week 5)

This post summarizes the dev chat meeting from July 19th (agendaSlack archive).

4.8.1 schedule

  • Access to Mission Control was lacking and delayed 4.8.1 beta release
  • Working to commit #40974, #38964, #40794 for 4.8.1 beta
  • Final planned bug scrub is Thursday, July 20th 16:00 UTC / Thursday, July 20th 16:00 UTC
  • Bug scrub will be focused on punting anything not headed towards a commit by Friday
  • If tickets in milestone drops to zero, we will continue with the planned 4.8.1 schedule:
    • RC – Monday, July 24th (hard string freeze)
    • Launch – Tuesday, August 1st

General announcements

#4-8, #4-8-1, #dev-chat, #summary

Dev Chat Agenda for July 19th (4.8.1 week 5)

This is the agenda for the weekly dev meeting on July 19, 2017 at 20:00 UTC / July 19, 2017 at 20:00 UTC:

  • 4.8.1 timing
  • 4.8.1 Beta help needed (support with Mission Control)
  • General announcements

If you have anything to propose to add to the agenda or specific items related to the above, please leave a comment below. See you there!

#4-8, #4-8-1, #agenda, #dev-chat