Dev Chat Agenda, April 15, 2015

Here’s the agenda for Wednesday’s Dev Chat in the #core channel on Slack.

  • RC1 was tagged just a little while ago, putting us back on trac for an April 22nd release.
  • We also entered hard string freeze today. All core and About string changes a frozen.
  • know!

Time/Date: Wednesday 21:00 UTC 2015:


  1. Branching at RC1 – To do, or not to do it
  2. Since we just tagged RC1, Report 6 is pretty empty. What are any outstanding issues?
  3. Test test test!
  4. 4.2 Release Progress
  • Beta 1
    • Punt/convert all non-essential enhancements to tasks
  • Beta 2 (120 tickets on Report 6)
    • Get first run of FTP credentials modal in trunk
  • Beta 3 (90 tickets on Report 6)
    • Start finishing up tickets with string changes
    • Start About page
  • Beta 4 (50 tickets on Report 6)
    • Soft string freeze (all string changes completed save for the About page)
    • Start finishing up the About page
  • RC 1 (0 tickets on Report 6)
    • About page string finished
    • Hard string freeze
  • Release (0 tickets on Report 6)
    • About page finished
    • Remaining issues resolved

#4-2, #agenda

Letting WordPress Speak: New accessibility feature in 4.2

One new accessibility feature in WordPress 4.2 is the new JavaScript method wp.a11y.speak(). The essence of this feature is to provide a consistent methodology for announcing dynamic JavaScript updates to assistive technology. For more information about how this works, why it exists, and how to use it, read the complete post at Make/Accessibility.

#4-2, #accessibility, #dev-notes

This Week in 4.2: April 13 – 19

This is the jump-start post for the thirteenth week of the WordPress 4.2 release cycle.

Last week, we missed tagging RC1 after losing momentum on our ticket goals toward the end of the week. We also missed hitting the “hard” string freeze.

Core Meetings this week:

Priorities this week:

Committers: please follow up on any tickets you own. We’re running out of time to hit our release date goal. We need to freeze strings and actually tag RC1, in that order, as soon as possible

Remaining tickets on Report 6 that must be closed or punted to tag RC1 are as follows:

  • #26111wp_localize_script array from callback for performance
    The recommendation is for @wonderboymusic to revert [31030] and [31033] and regroup in 4.3.
  • #31793Theme Switcher: Lazy load theme screenshots
    Waiting for a followup from @westonruter on the latest patch
  • #30725Add media modal – different select width
    Looking for direction from @helen on what an MVP fix would look like
  • #31794Theme Switcher: Improve mobile experience
    Latest patch needs to be reviewed and committed, and we should decide if the rest is worth tackling in 4.2.
  • #31908Insert into post button runs off the side of the screen on small devices
    The recommendation is to commit the latest patch and handle #30725 following that
  • #31912Media splitting: don’t copy the media folder to the build directory
    The latest patch from @ocean90 needs to be reviewed and committed by either @wonderboymusic or @jorbin
  • #319294.2 About Page
    The initial patch needs to be committed so we can keep design separate from content. The About page strings need to be finalized in order to institute “hard” string freeze. @melchoyce and @ryelle are in the process of engineering and designing around the content

Recent notable updates:

#4-2, #jump-starts

Dev Chat Agenda, April 8, 2015

Here’s the agenda for Wednesday’s Dev Chat in the #core channel on Slack.

  • Beta 4 was tagged last week as scheduled and we’re heading toward tagging Release Candidate 1 this week.
  • The hard string freeze is targeted to coincide with tagging RC1 this week, so we need to wrap any remaining tickets with strings, including the About page ticket (#31929).

Time/Date: Wednesday 21:00 UTC 2015:


  1. Task/Enhancements Review [List]
  2. RC1 Scrub – About 15 tickets remain on Report 6

No Open Floor this week – Due to time constraints, we won’t be holding an open floor period during the regularly-scheduled dev chat this week. If you have a ticket on the 4.2 milestone you’d like to get dev feedback on, leave a note in the comments.

4.2 Release Progress
  • Beta 1
    • Punt/convert all non-essential enhancements to tasks
  • Beta 2 (120 tickets on Report 6)
    • Get first run of FTP credentials modal in trunk
  • Beta 3 (90 tickets on Report 6)
    • Start finishing up tickets with string changes
    • Start About page
  • Beta 4 (50 tickets on Report 6)
    • Soft string freeze (all string changes completed save for the About page)
    • Start finishing up the About page
  • RC 1 (0 tickets on Report 6)
    • About page finished
    • Hard string freeze

#4-2, #agenda

This Week in 4.2: April 6 – 12

This is the jump-start post for the twelfth week of the WordPress 4.2 release cycle.

We entered the Beta 4 stage of development last week. This week we’ll transition to Release Candidate 1.

Weekly scrubs will continue this week on Tuesday and Wednesday using Report 6. The usual Friday scrub will be skipped this week.

Core Meetings this week:

Priorities this week:

Committers: please take a look at the list of tickets you own. This week we’ll be largely focused on getting high priority issues pushed in and low priority issues punted in preparation for tagging RC1.


  • #28820 – Focus isn’t clear when previewing an oEmbed from Add Media Panel
  • #31233 – Dismissable admin notices


  • #31793 – Theme Switcher: Lazy load theme screenshots
  • #31889 – Customizer Theme Switcher: Section will be deactivated if search result is empty
  • #31896 – Customizer Theme Switcher: Live previewing a theme breaks on subfolder installs
  • #28784 – Improve the Customize experience on mobile


  • #30422 – Visual Editor Shortcuts for Headings Don’t Work in Safari 8.0 on OS X
  • #29558 – Alt+Shift shortcuts override character input

Make Flow:

  • #31611 – Scroll bleed in the attachment details modal on iOS
  • #31609 – Scroll bleed through and scroll position loss in the view plugin details modal on iOS


  • #31903 – Changes to register_sidebar() May Lead to Data Loss
  • #31776 – I18n optimizations for 4.2

Recent posts seeking feedback

Notable updates from the last week:

#4-2, #jump-starts

Updates to the default admin color scheme

Over on Make/Design, @hugobaeta has posted about some subtle updates to the blues and grays of the default admin color scheme. Work on updating the admin has been completed in #31234. For those who are using those colors in their development, particularly any large areas of colors such as backgrounds, you may want to take a moment to update those values. There’s a handy guide to the changes on the post.

While we haven’t yet settled on a sensible and semantic way to provide helpers or utilities for these kinds of CSS changes, thoughts and eyes are welcome on #26691 for that.

#4-2, #bikeshed, #css, #dev-notes

WordPress Core Weekly

Here we go again! It’s time to look at what’s going on in WordPress core. This edition of WordPress Core Weekly covers March 28, 2015 [31916] through April 4, 2015 [32002].

Note: If you want to write the next WordPress Core Weekly summary, check out the schedule over at make/docs and get in touch in the #core-weekly-update Slack channel.

Highlights from this week

This week WordPress 4.2 Beta 4 got released. This hopefully last beta saw lots of accessibility improvements and added the ability to make admin notices dismissible. Emoji support in core is now pretty stable – maybe the next weekly post is written in emojis only? Also, there were some notes posted on utf8mb4 and the term splitting in WordPress 4.2.

Last but not least, @obenland and @wonderboymusic were announced as release leads for WordPress 4.3 and 4.4, respectively. Congrats! 🎉

Code Updates

Posts, Post Types

  • After [31114] and [31323], ‘View Post’ generated in get_sample_permalink_html() should go to pretty permalink. [32002] #30910
  • Avoid duplicate classes for different terms with UTF–8 slugs in post_class() and body_class(). [31979] #30883
  • In WP_Posts_List_Table::get_views(), don’t add the current class to the all status link if ->user_posts_count has a value, which triggers the additional mine status. [31959] #24869


  • WP_User_Query: When querying users with fields=all, ensure that caps and roles are filled for the current site. [32001] #31878
  • When updating the email address for an existing user, make sure the email address is not already in use. [31963] #30647



  • WordPress 4.2-beta4 [31997][31998]
  • Respect numerical keys in add_query_arg(). Avoid the use of array_replace() in add_query_arg(). [31966][31967] #31306
  • TinyMCE: always focus the editor after using the floated toolbar. [31972] #30619


  • Enhance twemoji.js to support passing of additional attributes for the replacement images. [31948] #31627
  • When encoding emoji into HTML entities, 0 was being incorrectly trimmed from the right side of the hex string, causing some characters to be encoded incorrectly. [31926]
  • When staticizing emoji into <img> tags, include an alt attribute of the original Emoji, to match both Smiley and Twemoji <img> tags. [31924]
  • Change the emoji CDN to, from [31938][31977] #31651


  • Accessibility improvements for Themes screen: fix keyboard events and callbacks for the Search field, increase trigger timeout a bit, improve Esc. key handling. [31994] #26600
  • Improve focus styling of add-new-theme link. [31952] #31203
  • Add a filter to short-circuit wp_prepare_themes_for_js(). [31943] #31789


  • Accessibility improvements for Options general screen: add missing labels and aria attributes. [31993] #31144
  • Accessibility: Add landmark roles to WordPress admin areas. [31955] #31450
  • Make sure the update button in “At a Glance” dashboard widget does not overlap with long strings. [31928] #30766

Press This

  • Prevent pasting of HTML in the title H2. Insert the clipboard text instead. [31987] #31768
  • Use more accurate wording on Tools screen. [31980] #31836
  • Use the error message returned by wp_update_post() instead of a generic one. [31930] #31808
  • Fix accessibility for the post options “sidebar”. Fix size of the Add Category button. [31925] #31575


  • Introduce a string representing bulk plugin update success, ready for string freeze. Not used yet. [31991] #31770
  • Plugins Browser: Replace the download count with the number of Active installs of the plugin. [31990] #31865
  • Add beforeunload string for shiny updates. [31989] #31769
  • Update aria-label when doing a shiny plugin update [31982] #31722
  • Add some logic into wp_tempnam to prevent it creating ‘falsey’ directory names that might get used elsewhere within WordPress. [31936] #31811


  • Merge title strings on Edit Site screens. [31962] #31844
  • Remove unused printf() on network setup screen. [31961] #31841
  • Decouple strings where the singular and plural form are not just the same string with different numbers, but essentially two different strings. [31941][31951] #28502


  • Theme Switcher: Navigation streamlining. [31975] #31289
  • Theme Switcher: Remove “Add New” references. [31968] #31837
  • Theme Switcher: Switch the details/live preview buttons. [31954] #31791
  • Theme Switcher: Use the global panel back button instead of adding a new one. [31918] #31794
  • Theme Switcher: Fix invalid HTML markup when New Theme control is added. [31950] #31203
  • Make the available widgets overlay closable on narrow screens. [31974] #28784
  • Defer rendering theme controls until the section is displayed. [31944] #31793
  • Revert [31911]. We want to preserve url and return URL parameters to make the experience smoother. [31933] #31782
  • Increase size of search field and disable text size adjustment to prevent auto zooming. [31917] #31794
  • Increase initial-scale viewport specification to 1.0. [31921] #31794, #28784
  • Fix selector for container which includes the controls. Broken since [30102]. [31916] #31794, #31014


  • Correctly set the post author in wp_xmlrpc_server::mw_editPost() when the current user is not the author of the post. [31983] #24916

Networks and Sites


  • Admin notices: Make (most) core notices dismissible. These no longer return upon refreshing the page when JS is on and working, so users should be able to dismiss them. [31973] #31233, #23367

Bundled Theme

  • Twenty Eleven: add postMessage support for header_textcolor to improve the user experience in the Customizer. [31971] #24128
  • Twenty Fifteen: adjust scroll behavior to make sure sidebar height is calculated during scroll events, not just resize events. [31934] #31734
  • Twenty Thirteen: make sure submenu links work correctly on small screens with touch events. [31932] #31762


  • Alter the regex in wptexturize() to properly handle input like: <> "Hello world" <>. [31965] #30344


  • When shifting WP_Rewrite::flush_rules() to a later action if it was called too early, make sure to do a hard flush if requested. [31964] #30501


  • When editing an image from the editor, and the image has a value for alignment (but not for width or caption), don’t bail without first checking that the alignment’s value is not alignnone. If so, add the class to the <a> before bailing. [31958] #21848
  • Media Library: Add a label for attachment type select in list mode. [31942] #31795



  • When we check the character set of a column, and find that it’s utf8mb4, we should also check that the current connection supports utf8mb4. It’s possible that the environment may have changed since upgrading the DB, so we can fall back to utf8 when that happens. [31947] #31771
  • When we’re checking to see if the MySQL client library supports utf8mb4, we need a separate check for mysqlnd versions, which using different version numbering to libmysqlclient. [31939] #31644

Login and Registration

  • Disable body scrolling when session expired log in modal is open. [31945] #31610


  • Revert using require for JS modules because that made them read-only for the public. [31935] #31684, #28510


  • Fix duplicate ID for Save Menu button on Menus screen. [31927] #31803

Thanks to @A5hleyRich, @adamsilverstein, @afercia, @azaozz, @boonebgorges, @cdog, @celloexpressions, @davideugenepratt, @dd32, @deconf, @Denis-de-Bernardy, @designsimply @dllh, @DrewAPictur, @DrewAPicture, @ericlewis, @evansolomon, @folletto, @helen, @iseulde, @jeremyfelt, @joedolson, @johnbillion, @jorbin, @jorbin, @kraftbj, @lancewillett, @markoheijnen, @mattheu, @mattwiebe, @MattyRob, @mehulkaklotar, @MikeHansenMe, @miqrogroove, @mordauk, @mrahmadawais, @ocean90, @paulwilde, @pento, @ramiy, @redsweater, @rittesh.patel, @sagarjadhav, @SergeyBiryukov, @sgrant, @stephdau, @swissspidy, @tyxla, @valendesigns, @westonruter, and @wonderboymusic for their contributions!

#4-2, #week-in-core


One of the fun bits of the utf8mb4 upgrade is that we can now store emoji! Once your site is upgraded to utf8mb4, it can natively store any emoji character. There were a couple of problems with that, though:

  • Some browsers don’t know how to render emoji 👎, or they have bugs in their implementation 😢. Notably, Chrome either doesn’t work or has bugs, older versions of IE don’t work, and Firefox has bugs.
  • Not all sites will be able to upgrade to utf8mb4, which means they’ll be unable to save emoji characters that they enter.

Not being able to use emoji makes everyone a sad panda (😭🐼), so we need to fix this. There are a few moving parts of our emoji support, so lets go through them.

utf8 backwards compatibility

If a site can’t be upgraded to utf8mb4, we convert emoji to their HTML-encoded equivalent, and store that, instead. From a UI perspective, post editing works as expected 🎉. Because fields need to be white listed to support this, we don’t allow it everywhere – just post_title, post_content and post_excerpt. We also allow it in the site title and the site description.

Browser support

There’s a small compatibility check included on every page, both on the front end, and in the Dashboard. For those interested, this adds 1-4ms (⚡️-fast!) to the page render time – the aim was to keep this as low as possible, to avoid affecting your UX. If you notice a little chunk of compressed JS at the top your HTML, that’s probably it. If you’d like to check out how it works in a more readable format, have a look through wp-emoji-loader.js.

Email ✉️ and RSS 📯 (There’s no RSS emoji, give me a break.)

Of course, the JS shim won’t work in email and RSS. So, we replace all emoji with a static PNG version in those cases.

TinyMCE 📝

In addition to the browser support JS, there’s a TinyMCE plugin that handles keeping emoji looking good, while you type. It’s pretty magical.

Taxonomies and URL slugs

You can totally make taxonomies and URL slugs with emoji in them. Because we love you, and want you to be happy. 😀

So, that’s about it. If you have any questions about the implementation, drop them in the comments below.


#4-2, #dev-notes, #%f0%9f%91%bb, #emoji

Reminder: Term splitting in 4.2

Here’s a quick reminder to plugin authors. Beginning in WordPress 4.2, shared taxonomy terms will get split into separate terms when one of the terms gets updated.

What does this mean for you? If your plugin is independently storing term IDs in post meta, user meta, or options, then it’s likely you’ll need to update your plugin to prevent problems when a shared term gets split.

Boone Gorges has posted a complete guide to preparing for term taxonomy splitting. Take a read if you’re a plugin author and you think a plugin of yours may be affected.

#4-2, #dev-notes

The utf8mb4 Upgrade

In WordPress 4.2, we’re upgrading tables to utf8mb4, when we can. Your site will only upgrade when the following conditions are met:

  • You’re currently using the utf8 character set.
  • Your MySQL server is version 5.5.3 or higher (including all 10.x versions of MariaDB).
  • Your MySQL client libraries are version 5.5.3 or higher. If you’re using mysqlnd, 5.0.9 or higher.

The difference between utf8 and utf8mb4 is that the former can only store 3 byte characters, while the latter can store 4 byte characters. In Unicode terms, utf8 can only store characters in the Basic Multilingual Plane, while utf8mb4 can store any Unicode character. This greatly expands the language usability of WordPress, especially in countries that use Han character sets. Unicode isn’t without its problems, but it’s the best option available.

utf8mb4 is 100% backwards compatible with utf8.

Due to index size restrictions in MySQL, this does mean we need to re-create a handful of indexes to fit within MySQL’s rules. Using a standard configuration, MySQL allows 767 bytes per index, which for utf8 means 767 bytes / 3 bytes = 255 characters. For utf8mb4, that means 767 bytes / 4 bytes = 191 characters. The indexes that will be resized are:


And from Multisite:


Of course, the Multisite (and wp_usermeta) keys obey the DO_NOT_UPGRADE_GLOBAL_TABLES setting. The upgrade will only be attempted once, though we’ll probably add a check in a future WordPress version to see if we can upgrade now (say, if you’ve upgraded your MySQL server since upgrading to WordPress 4.2).

If you’re a plugin developer and your plugin includes custom tables, please test that your indexes fit within MySQL’s limits. MySQL won’t always produce an error when the index is too big, so you’ll need to manually check the size of each index, instead of relying on automated testing.

EDIT: One more thing…

If you’d like to upgrade your custom tables to utf8mb4 (and your indexes are all in order), you can do it really easily with the shiny new maybe_convert_table_to_utf8mb4( $tablename ) function. It’s available in `wp-admin/includes/upgrade.php`, and will sanity check that your tables are entirely utf8 before upgrading.

#4-2, #dev-notes, #utf8mb4, #wpdb