A week with us: Safe updates, plugin dependencies, themes, PHP 8.1, and more!
During what might have seemed like another quiet summer week for the WordPress project in general, our team continued working on some long-requested projects. That included: safe plugin/theme updates, plugin dependencies, web fonts API, simplifying theme requirements for the WordPress.org Themes Directory, modernizing WordPress PHP unit test suite, and preparing for PHP 8.1. Read on to learn more!
Our weekly team updates
Ari
Update the updater
The past two weeks, I mostly focused on the “Update the Updater” project and, more specifically, on two of its tasks: plugin dependencies and improving the stability of updates.
Plugin Dependencies
This is one of the things that plugin developers have been asking for for a decade (not exaggerating), and I’m hoping we can make it happen this time. There are numerous tickets on WordPress trac, but if anyone wants to catch up, #22316 is a great ticket that sums up all others.
We started working on this one a while ago, but these past two weeks, we took significant steps. In #1547, I started exploring an implementation for plugin dependencies. After a very long discussion in the patch on GitHub, I switched the implementation from using a JSON file to using the plugin headers. The last piece missing from this puzzle was to take into account circular dependencies. A couple of days ago, I took care of that as well, so we are now one step closer to a final solution.
Safe unzip updated
One of the things that we wanted to improve was to make plugin updates safer. A few weeks ago, @francescamarano posted a “Request for feedback.” The pull-request on #1492 is no longer a draft but has been published and is now a patch for WordPress Core. I made a number of improvements to the initial patch, taking all feedback into account.
Webfonts API
WordPress has a way to enqueue styles, scripts, but not webfonts. Last year there was a proposal called “A font enqueue API for WP core.” Building on the principles of that proposal – as well as the tickets it links to, I started working on a proof-of-concept API for webfonts. It is still an early draft because most of my focus was on the “update the updater” project, but if you want to take a look and help out, you can find the code on #1573.
Education
I continued my education with the Yoast Academy and, this time, started learning about SEO Copywriting. It is far more interesting than I could imagine! It’s more time-consuming than something like technical-SEO, but that’s mostly because I can understand technical things a lot easier.
Carolina
Last week, the blog had a summer break, so here is a summary of what I have been working on for the past two weeks.
Themes
We passed the date for leaving feedback on the updated theme directory requirements, and I published a summary of the feedback.
The new requirements are in place and published on the requirements page. I have also updated the page with recommendations for theme developers.
The requirement changes include:
- Themes no longer have to support comments. This opens up for several types of new themes like one-page themes and niched e-commerce themes.
- Many requirements for using specific WordPress functions were reduced to recommendations or removed.
- Minimal requirements for block themes (themes with support for full site editing).
- New requirements disallow spamming and strengthen user privacy.
The development version of the Theme Check plugin has received several updates to match the new requirements. We still need to release the updated plugin to the WordPress.org plugin directory. You can learn more about the changes in the Theme Check GitHub repository. Here is a summary of some recent work:
- Improved error messages that displays line numbers and links to documentation.
- Bug fix: Fix PHP notice in one of the text domain checks.
- Removed a check for duplicate theme and author links.
- Removed a check related to emojis and updated the check for functions and hooks that are not allowed in themes.
- Continued work on checks for notifications and copyright statements ( no pull request ready yet), as well as a simplified readme validator.
QA
I have continued testing version 17.0 of Yoast SEO and add-ons, as well as Duplicate Post.
Francesca
Last week I was on holiday. I relaxed hard and ate a lot of cake. I also had time to exchange GIFs of excitement with the Bluehost team about the Yoast/Newfold news. It is exciting news!
I have known them for years now. We used to meet at several events around the world, and even though I worked for a competing hosting company at the time, they were always friendly, graceful, and, I might add, protective of me! I was even saved during a bar fight that erupted in a pub where WordCamp OC was holding the after-party (true story! The fight was not amongst WordCampers, I repeat, the fight was not amongst WordCampers!).
So I am thrilled to be able to call them colleagues. Mergers and acquisitions take time, so it will be a while until we are all under the same digital roof, but I am counting the days.
This week, on the other hand, feels like seventy days long! Everyone is coming back energized from their holidays. Before we start anything new, we are wrapping up something Ari and Sergey have been working on for a while: the unzip/rollback feature for the plugin and themes updater. So I have a request for our readers! Are any among you plugin or theme developers? Please help us test it. The instructions are in the PR.
Justin
Last week, I was on vacation. Funny enough, I was a little apprehensive about having a whole week of vacation without really planning anything. But Francesca reassured me that I should just let things go, and I wouldn’t even notice the time passing. That turned out to be true. I spent almost every day resting properly, and now I’m in great shape.
Now I’m continuing to work on testing for an internal Yoast project; this will last until the end of August before I return to full WordPress contribution.
Sergey
WordPress 5.9
Last week I continued looking into some early tickets for WordPress 5.9 as part of my duties as a Core Committer.
I made thirty commits to WordPress core, mostly various bug fixes and enhancements. I also triaged new tickets incoming into Trac (the bug tracking system that WordPress uses).
WordPress Unit Test Suite
As of last week, WordPress test suite is compatible with PHPUnit 8 & 9 and runs tests on PHP 8.1 beta (scheduled for release in November). See tickets #46149 and #53891 for more details.
As some of these test improvements were an unavoidable backward compatibility break for plugins/themes running tests on WP core framework, there is an ongoing discussion about backporting some of these changes to older branches. There are two main reasons for backporting:
- Make WP security releases easier by not having to rewrite the tests that accompany security backports for older PHPUnit versions.
- Help minimize the impact on the extender community who need to do cross-version testing against older versions of WordPress.
For more details, see ticket #53911. Feedback is welcome!
On a related note, a PR was opened to improve the messages shown when running the WP core test bootstrap file in a plugin/theme integration test situation, most notably when the plugin/theme test suite has not been adjusted yet for the changes in WP 5.9. See PR 1587 for more details. Feedback welcome!
PHP 8.1
I also continued looking into various compatibility fixes for PHP 8.1. See ticket #53635 for more details.
Last Friday, I was invited to a live streaming session with Tonya Mork and Juliette Reinders Folmer. We discussed some PHP 8.1 compatibility fixes for WordPress core.
If you’re interested in updating legacy codebases for modern PHP, I would highly recommend watching the session on YouTube: Preparing WP for PHP 8.1.