Performance Chat Summary: 11 July 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

  • Welcome to our new members of #core-performance
  • WP 6.3 BetaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. 4 is today
  • Working on a WordPress 6.3 performance highlights post – please add suggestions to the document by July 21
  • Work continues on dev notesdev note Each important change in WordPress Core is documented in a developers note, (usually called dev note). Good dev notes generally include a description of the change, the decision that led to this change, and a description of how developers are supposed to work with that change. Dev notes are published on Make/Core blog during the beta phase of WordPress release cycle. Publishing dev notes is particularly important when plugin/theme authors and WordPress developers need to be aware of those changes.In general, all dev notes are compiled into a Field Guide at the beginning of the release candidate phase. for 6.3

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein @westonruter

  • @10upsimon Enhancing the WP Scripts APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. with a loading strategy:
    • A draft Dev Notedev note Each important change in WordPress Core is documented in a developers note, (usually called dev note). Good dev notes generally include a description of the change, the decision that led to this change, and a description of how developers are supposed to work with that change. Dev notes are published on Make/Core blog during the beta phase of WordPress release cycle. Publishing dev notes is particularly important when plugin/theme authors and WordPress developers need to be aware of those changes.In general, all dev notes are compiled into a Field Guide at the beginning of the release candidate phase. is in progress and I believe almost ready to be published, huge shout out to @flixos90 @joemcgill and @westonruter for their invaluable contributions thus far
    • I’ve reached out to the documentation team around how to submit changes to Dev Hub pages, and have begun drafting potential documentation updates that will need to happen that are exclusive of the automated updates, with the goal of having those ready for review by latest mid week next week. Thanks @stevenlinx for pointing me in the right direction.
    • Worth noting that auxiliary documentation efforts (docs not auto generated from code) have reduced somewhat following removal of deferred inline scripts
  • @spacedmonkey Created this ticket, for remove hardcoded style tags https://core.trac.wordpress.org/ticket/58775
  • @westonruter I’ve started exploring where script strategies can be used in coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. and GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/. I don’t have a further update just yet but hope to have either a doc or set of tickets by next week.
    • @joemcgill We should take a look at default themes too. Let me know how I can best support
    • @westonruter Yes, I mean to include that in core
    • @spacedmonkey I wonder if it could be used in the performance lab and pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party checker plugins as well.
    • @westonruter Some of the changes may make sense as a module in PL first
  • @10upsimon Although, I did do a performance comparison on a draft PR that @thekt12 had added based on this slack discussion  and followed up in the thread, we agreed to pause on this for now and re visit it shortly with a broader script tree.

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27 @swissspidy

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger @mukesh27

  • @mukesh27 We are working on the last issue for Milestone 2 for the Plugin Checker. Once complete we’ll be moving onto further QA/Testing and remediating over this week and next. Progress can be seen on the GitHub repo here. Feel free to take a look and leave any thoughts/ideas you may have in the repo. Thanks!

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

  • No updates this week

Open Floor

  • @adamsilverstein I opened a new ticket to consider adding lazy loading to oEmbed iframes: https://core.trac.wordpress.org/ticket/58773 – although iframes are lazy loaded by default now, oEmbeds are not included in that
    • @spacedmonkey Could lazily loading iframes have issues around tracking? Some embeds, like say a video provide, like iframeiframe iFrame is an acronym for an inline frame. An iFrame is used inside a webpage to load another HTML document and render it. This HTML document may also contain JavaScript and/or CSS which is loaded at the time when iframe tag is parsed by the user’s browser. to load, so they can have view counts.
    • @westonruter Embed iframes wouldn’t be used for tracking, I wouldn’t think. If the video is never played then the view count shouldn’t increase, right? So same as if it wasn’t loaded.
    • @adamsilverstein possibly, they would no longer load if they are off screen and never scrolled near the viewport
    • @spacedmonkey What if a video is auto playing? You could build your website for your youtube channel to have a post blogblog (versus network, site) for each video. In that case you would want it to autoload play
    • @westonruter Note that autoplay with audio doesn’t work on mobile
    • @spacedmonkey Autoload is only really a problem for ads. Autoload for a site where the user wants to see the video is differnet. On youtube, I would want to a video to autoload when I click on the video.
    • @westonruter There may need to be a filterFilter Filters are one of the two types of Hooks https://codex.wordpress.org/Plugin_API/Hooks. They provide a way for functions to modify data of other functions. They are the counterpart to Actions. Unlike Actions, filters are meant to work in an isolated manner, and should never have side effects such as affecting global variables and output. or documented way to turn off lazy load. However, if the video intends to autoplay then it should be in the first viewport, and thus it shouldn’t get loading=lazy anyway or it would load right away anyway. I don’t think we should worry about the case of an autoplay video being lazy-loaded that isn’t in the first viewport.
    • @spacedmonkey The embed code from youtube doesnt have lazy load attribute. Why is that the case?
    • @adamsilverstein there is an existing filter that can be used wp_iframe_tag_add_loading_attr 
    • @westonruter That’s a good question. I have been looking into that but haven’t found a reason yet.
    • @spacedmonkey Vimeo also doesn’t have lazy loading attributes. I feel like the embed provider wants to have them lazy load, they would.
    • @adamsilverstein we’ll need to test every embed type of course. i’d love if that were true, but providers aren’t doing that
    • @westonruter These video providers predate the introduction of loading=lazy. Could be they just haven’t added it yet. Better for core to add anyway, because then we can omit from videos in the first viewport.
    • @spacedmonkey I think this functionality should have a merge prospal and get feedback from the community. I know for a fact, I have using video providers that use iframe and needed the video to load to mark as an impression. Having a filter is all good. But that means that video provide X needs to create a plugin to use the video to opt out.
    • @westonruter Why should an impression be given if the video is never in the viewport?
    • @adamsilverstein we already announced and discussed oEmbeds would be lazy loaded in this post – https://make.wordpress.org/core/2021/02/19/lazy-loading-iframes-in-5-7/ we later reverted the change due to technical issues. lets start by discussing the tracking concerns on the tracTrac An open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress. ticket
    • @spacedmonkey Can we explore this idea as a module in the performance lab? That way we can have people test this functionality.
    • @adamsilverstein Absolutely, great idea! Here is the code needed to add the same functionality in a plugin – https://gist.github.com/adamsilverstein/e280062004c38629fc029b6d267bff91
    • @spacedmonkey Being able to test things like this is the point of the performance lab plugin. We can get feedback from the community that was as well.

Our next chat will be held on Tuesday, July 18, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Performance Chat Summary: 4 July 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

  • Welcome to our new members of #core-performance
  • Many folks out today due to US 4 July holiday
  • Reminder of bugbug A bug is an error or unexpected result. Performance improvements, code optimization, and are considered enhancements, not defects. After feature freeze, only bugs are dealt with, with regressions (adverse changes from the previous version) being the highest priority. scrub tomorrow for a check on 6.3 issues
  • Early performance numbers on WP 6.3 betaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. is out: overall load time performance (represented by the “LCP” metric) sees a boost of a whopping ~26% for blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. themes and ~19% for classic themes  [see Slack post]
  • For those that missed it, we have a special Performance Improvements for WordPress 6.3 Hallway Hangout scheduled on Thursday July 27 at 3:00pm UTC
  • Reminder that Beta 4 is next week on July 11 for the 6.3 release cycle

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

  • @spacedmonkey Mostly been supporting the beta release. I have also validated the number that Felix got, we are massively in the green for performance improves in WP 6.3
    • While profiling, I did find this, https://core.trac.wordpress.org/ticket/58682 wp_trim_excerpt parses and renders blocks twice
    • TLDR, excerpts are parsing blocks twice, which is really bad. I will look into that ticketticket Created for both bug reports and feature development on the bug tracker. in WP 6.4, as it has been a problem since 5.0. Only noticed now other performance has improved.

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones

  • @spacedmonkey working on dev notesdev note Each important change in WordPress Core is documented in a developers note, (usually called dev note). Good dev notes generally include a description of the change, the decision that led to this change, and a description of how developers are supposed to work with that change. Dev notes are published on Make/Core blog during the beta phase of WordPress release cycle. Publishing dev notes is particularly important when plugin/theme authors and WordPress developers need to be aware of those changes.In general, all dev notes are compiled into a Field Guide at the beginning of the release candidate phase., here are some early drafts:

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein @westonruter

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

  • @spacedmonkey I did some testing on the lazy loading / fetchpriority changes. I found some places where these were not working:
    • https://core.trac.wordpress.org/ticket/58680 HeaderHeader The header of your site is typically the first thing people will experience. The masthead or header art located across the top of your page is part of the look and feel of your website. It can influence a visitor’s opinion about your content and you/ your organization’s brand. It may also look different on different screen sizes. image does not add fetch priority attribute
    • https://core.trac.wordpress.org/ticket/58681 No lazy loading attribute on images in gallery
    • https://core.trac.wordpress.org/ticket/58704 Image widgetWidget A WordPress Widget is a small block that performs a specific function. You can add these widgets in sidebars also known as widget-ready areas on your web page. WordPress widgets were originally created to provide a simple and easy-to-use way of giving design and structure control of the WordPress theme to the user. images do not support fetch priority or async
    • I would say that header images (used by many coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. themes) and gallery shortcodes are pretty big issues that I would love to see fix in the WP 6.3 release cycle

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27 @swissspidy

  • @swissspidy I started looking into making the performance testing environment reusable. Nothing concrete to share yet though

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger @mukesh27

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

  • @clarkeemily we have received a response from the PluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party Review team on the Dominant Color Images plugin and have some feedback to review. They found an issue that we are unable to replicate, so we are in the process of liaising with the Plugin Review team on this

Open Floor

  • @spacedmonkey Do we have a list of all the tickets that we want to have dev notes for?
  • @mukesh27 For the performance aspect, do we have only one developer note or are there multiple developer notes related to it?
    • @clarkeemily My understanding is multiple, and there will be blogblog (versus network, site) posts about a holistic review of 6.3 performance
    • @spacedmonkey noted that @flixos90 is looking into a retro for WP 6.3. That will cover some of the other ticket that do not need dev notes but had an impact. We don’t normally write a dev notedev note Each important change in WordPress Core is documented in a developers note, (usually called dev note). Good dev notes generally include a description of the change, the decision that led to this change, and a description of how developers are supposed to work with that change. Dev notes are published on Make/Core blog during the beta phase of WordPress release cycle. Publishing dev notes is particularly important when plugin/theme authors and WordPress developers need to be aware of those changes.In general, all dev notes are compiled into a Field Guide at the beginning of the release candidate phase. for things we just made faster under the hood.
    • @spacedmonkey If anyone else has anything they think we should call out in docs or write dev notes, please reach out on this channel.

Our next chat will be held on Tuesday, July 11, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Performance Chat Summary: 27 June 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

  • Welcome to our new members of #core-performance
  • BetaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. 1 for the 6.3 release is today!

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein @westonruter

  • @joemcgill I’m happy to be able to report that I committed the PR for https://core.trac.wordpress.org/ticket/12009 yesterday, closing a 13 year old ticketticket Created for both bug reports and feature development on the bug tracker.. This is a big milestone for the team, thank you to everyone who contributed to get this across the line. I know that there is still a desire to extend support to inline scripts, so I’ve opened a new ticket (https://core.trac.wordpress.org/ticket/58632) for that discussion.
  • @10upsimon is drafting a dev-note for this change, which we can hopefully post in the next few weeks.
  • @spacedmonkey I had people asking me questions about module support. – https://core.trac.wordpress.org/ticket/56313 I wonder if this should be something we look into for WP 6.4
    • @joemcgill Seems like the logical next step. Would be nice to do in coordination with packages from GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ that want to make use of it.
    • @flixos90 Yeah I know the folks working on the new interactivity APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. were quite interested in this one
    • @clarkeemily let’s look at adding this to our roadmap in a future chat
    • @spacedmonkey The important thing about this functionality is the developer communication. We need a great dev notedev note Each important change in WordPress Core is documented in a developers note, (usually called dev note). Good dev notes generally include a description of the change, the decision that led to this change, and a description of how developers are supposed to work with that change. Dev notes are published on Make/Core blog during the beta phase of WordPress release cycle. Publishing dev notes is particularly important when plugin/theme authors and WordPress developers need to be aware of those changes.In general, all dev notes are compiled into a Field Guide at the beginning of the release candidate phase., with easy to understand and copy and paste implementations. We will also have to show developers how we can make the change and be backwards compatible.

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

  • @flixos90 Excited to share that yesterday we landed fetchpriority="high" support: https://core.trac.wordpress.org/changeset/56037
    • That commit includes notable refactoring to make the logic that was previously scoped to only lazy-loading more broadly available, as it is also required for fetchpriority
    • So with that refactoring it also unblocks a fix to another issue that still needs to be addressed with lazy-loading: https://core.trac.wordpress.org/ticket/58635
    • I’m planning to work on dev notesdev note Each important change in WordPress Core is documented in a developers note, (usually called dev note). Good dev notes generally include a description of the change, the decision that led to this change, and a description of how developers are supposed to work with that change. Dev notes are published on Make/Core blog during the beta phase of WordPress release cycle. Publishing dev notes is particularly important when plugin/theme authors and WordPress developers need to be aware of those changes.In general, all dev notes are compiled into a Field Guide at the beginning of the release candidate phase. for these changes. Still thinking through whether it should be two individual dev notes or a single one. While they are separate topics, they are deeply intertwined, and especially with the refactoring it may be a lot of repetition to have two separate posts

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27

  • @joemcgill Nothing here either. Though, once the dust settles on beta release day, I’d like to revisit improvements we can make to the automated testing tools during this release cycle, to better support the RCrelease candidate One of the final stages in the version release cycle, this version signals the potential to be a final release to the public. Also see alpha (beta). cycle.

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger @mukesh27

  • @mukesh27 and @joegrainger are currently prioritizing tasks for Milestone 2 of the Plugin Checker. Progress can be seen on the GitHub repo here. Feel free to take a look and leave any thoughts/ideas you may have in the repo. Thanks!

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

  • @flixos90 Still awaiting approval of the Dominant Color Images pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party in the plugin repo

Open Floor

  • @clarkeemily our next chat is on July 4 Independence Day in the US, so I suspect a large portion of folks will be out. I still plan to run the chat, but a heads up that it will likely be much shorter as many folks will be out
  • @mukesh27 highlighted the message from @johnbillion
    • #21938 has been re-opened with the performance focus added, the e2e tests are indicating a potential performance regressionregression A software bug that breaks or degrades something that previously worked. Regressions are often treated as critical bugs or blockers. Recent regressions may be given higher priorities. A "3.6 regression" would be a bug in 3.6 that worked as intended in 3.5. that needs testing in different browsers and configurations
    • @johnbillion Ah yes ^ . Some of you might have seen the coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. and Gutenberg e2e tests are flakier than usual at the moment and it may be due to the no-store cache headerHeader The header of your site is typically the first thing people will experience. The masthead or header art located across the top of your page is part of the look and feel of your website. It can influence a visitor’s opinion about your content and you/ your organization’s brand. It may also look different on different screen sizes. directive that was added last week. I’ve reopened the ticket and added the performance focus, if anyone has time to do some testing that would be greatly appreciated.
    • @joemcgill I remember looking at this last week when I opened the bugbug A bug is an error or unexpected result. Performance improvements, code optimization, and are considered enhancements, not defects. After feature freeze, only bugs are dealt with, with regressions (adverse changes from the previous version) being the highest priority. ticket about the E2E tests, and I was not convinced that the failures were related to that change, so this might be a red herring. I recall seeing several instances of networknetwork (versus site, blog) timeouts showing up prior to that change.
    • @johnbillion I agree it could be a red herring, but git bisect does point to that commit, so I’m honestly not sure. Although the core e2e tests did start failing before that commit, so..
    • @joemcgill I think we can certainly try revering that change to see if the tests stop failing. Are there other steps to take to try and debug this issue?
    • @johnbillion I added some testing steps in a comment on the ticket, I don’t have much else at the moment
  • @westonruter On another front, I believe I’ve addressed the last code review for optimizing the emoji loader. Final reviews/testing appreciated so I can commit in the next hour: https://github.com/WordPress/wordpress-develop/pull/4562

Our next chat will be held on Tuesday, July 4, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Performance Chat Summary: 20 June 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

  • Welcome to our new members of #core-performance [Slack thread]
  • Release 2.4.0 scheduled for later today
    • Agreed to postpone this to Tuesday June 20 to support several team members being out for the US holiday
  • Upcoming BetaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. 1 for the 6.3 release on Tuesday June 27, 2023
  • Updates to our CoreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. Performance Handbook with the introduction of the Profiling PHP performance with XHProf article

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones

  • No updates this week

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein @westonruter

  • @joemcgill For Script Loading Strategy: https://core.trac.wordpress.org/ticket/12009
    • Most of the PR for adding support for `async` and `defer` has been approved for commit. Unfortunately, keeping in support for inline scripts is blocking the current PR, so we’re going to remove that part of the implementation this week and commit the rest. This just means that if anyone tries to add an `async` or `defer` strategy to a handle that has an inline script attached in an `after` position, the original script will be loaded with a blocking strategy instead.
    • @spacedmonkey I code reviewed the above and approved it for commit
    • @joemcgill we will likely ask for another review once we’ve implemented the changes
    • @10upsimon Nothing more from my side, I’ll be working with @joemcgill on the reversal of delayed after inline scripts, and further testing
    • @spacedmonkey Should we talk about the comment – https://github.com/WordPress/wordpress-develop/pull/4391#issuecomment-1598421109 . Or leave it open floor. I think this should be in core and I want to work out a path to unblock it
    • @10upsimon this is the same level of push back we’re receiving on the Trac ticket itself. It’s a long standing aversion to support delayed inline scripts. I’d like to see it in core as well, if possible.
    • @joemcgill I think we’ve exhausted this conversation for now. The focus this week should be to get the majority of this feature committed and we can advocate for extending support for inline scripts during the beta period.
    • @spacedmonkey Could it be commit before the beta and then if we can resolve the inline style stuff, then we can do a part revert?
    • @joemcgill Andrew has indicated in the PR thread that we could continue that conversation during the beta period, yes

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

  • @adamsilverstein Some recent developments on the modern image front: the new version of Safari includes JpegXL support which was a bit of a surprise and somewhat exciting. If other browsers follow suit, maybe the format will become useful for the web and WordPress?! In addition, Edge canary has apparently added AVIF support, so we will hopefully see all major browsers supporting AVIF soon.  I created a patchpatch A special text file that describes changes to code, by identifying the files and lines which are added, removed, and altered. It may also be referred to as a diff. A patch can be applied to a codebase for testing. to add AVIF support to core on the existing ticketticket Created for both bug reports and feature development on the bug tracker. that is ready for testing –  https://core.trac.wordpress.org/ticket/51228
  • @thekt12 and @flixos90 are also working on finalising https://github.com/WordPress/wordpress-develop/pull/4495 this week
    • @spacedmonkey I have been code review and profiling this. We are awaiting a new version that improves PHPPHP The web scripting language in which WordPress is primarily architected. WordPress requires PHP 5.6.20 or higher performance.

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27

  • @joemcgill Over the weekend, the Theme Unit Testunit test Code written to test a small piece of code or functionality within a larger application. Everything from themes to WordPress core have a series of unit tests. Also see regression. data that we rely on briefly went offline and broke the automated performance tests in Core. There is an open ticket about bringing that code directly into our repo, rather than relying on the Theme Unit Test data, but there is also conversation happening about moving all of that code into the WP organization. Original thread: https://wordpress.slack.com/archives/C02RQBWTW/p1687140431658569 For now, I don’t think we need to take immediate action, but is something to consider over the coming weeks.

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger @mukesh27

  • @joegrainger We are working on the last check for Milestone 2 for the Plugin Checker. Once complete we’ll be moving onto further QA/Testing and remediating over this week and next. Progress can be seen on the GitHub repo here. Feel free to take a look and leave any thoughts/ideas you may have in the repo. Thanks!

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

  • @flixos90 Still awaiting approval of the Dominant Color Images pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party in the plugin repo

Open Floor

  • @spacedmonkey This ticket has been very active – https://core.trac.wordpress.org/ticket/58368
    • TLDR, WP_Commey_Query does count queries using order by, resulting in bad performance. Comment type is not a database index.
    • @joemcgill That ticket needs an owner and and agreed upon patch in the next week. Seems like a stretch at the moment.
    • @spacedmonkey I am not sure we can add indexes easily to a table like comments. The person on the ticket has 5 million comments in this database. Adding an index normally locks a table on a high traffic like that, it could be a problem. I think we will have to puntpunt Contributors sometimes use the verb "punt" when talking about a ticket. This means it is being pushed out to a future release. This typically occurs for lower priority tickets near the end of the release cycle that don't "make the cut." In this is colloquial usage of the word, it means to delay or equivocate. (It also describes a play in American football where a team essentially passes up on an opportunity, hoping to put themselves in a better position later to try again.) to 6.4. I will update the ticket.
      • @rmccue I think we’ve added indexes on large tables before, seem to recall .com needing to orchestrate a slow rollout of them
  • @joemcgill Do we know who is ensuring the fix for https://core.trac.wordpress.org/ticket/58457 is getting synced from the GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ repo? This process still seems very manual and error prone to me.
  • @spacedmonkey Would useful to get eyes on – https://github.com/WordPress/gutenberg/pull/51116

Our next chat will be held on Tuesday, June 27, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Performance Chat Summary: 13 June 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones @rjasdfiii

  • No updates this week

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein @westonruter

  • @joemcgill For Script Loading Strategy: we’ve finished addressing most of the outstanding issues with the PR. Thanks to all who helped test it at Contributor Day last week. My goal right now is to get the last details wrapped up so we can get a final :+1: from the release team to get this merged. The main outstanding question that we still need to resolve is whether our approach for managing inline scripts attached to delayed script handles is acceptable. I’d like to get a second opinion from someone in #core-js but am not confident on who should weigh in https://github.com/WordPress/wordpress-develop/pull/4391
  • @spacedmonkey Created ticket –https://core.trac.wordpress.org/ticket/58519
    •  Somewhat unrelated, but I got a PR into jetpack that will inline blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. styles – https://github.com/Automattic/jetpack/pull/31214
  • @westonruter I’m working on fixing an issue with the timing for when the delayed inline script loader is added to the page. I found some cases when it is not printed at the right time (or at all). I have some refinements I’m making this morning before ready for review: https://github.com/10up/wordpress-develop/pull/75
  • @joemcgill I’d say the three issues in the “in progress” column here is what we’re trying to wrap up: https://github.com/orgs/10up/projects/14 is that correct?
  • @flixos90 Is there already a (draft) PR for the reduced implementation?
    • @joemcgill There is not. That will be the next thing to work on as soon as we’ve got the ideal version ready to go
    • @joemcgill Honestly, hoping we don’t even need it, but want to be ready to put that together in the next week so we have time for reviews before the beta 1 cutoff
    • @flixos90 I think the main question I’d like to sort out this week is how we will handle the fallback approach in case we don’t get any inline script handling in. I’m personally leaning towards:

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27

  • No updates this week

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger

  • @joegrainger We have been working on implementing the initial checks for the Plugin Checker. We have come across a strange issue with PHPUnit tests but myself, @mukesh27 and @joemcgill have synced on this and we have plan forward. We plan to have the checks completed over the coming days. You can follow the progress on the GitHub repo here. Thanks!

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

  • @flixos90 Still awaiting approval of the Dominant Color Images pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party in the plugin repo

Open Floor

  • @spacedmonkey PHPPHP The web scripting language in which WordPress is primarily architected. WordPress requires PHP 5.6.20 or higher 7.0 looks like it will be the min required version for WP 6.3. I wonder if there is anything we could take out of core, likely backward compatibility shim etc that might improve performance #57067 Example

Our next chat will be held on Tuesday, June 20, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Performance Chat Summary: 6 June 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones @rjasdfiii

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein

  • @spacedmonkey I would love some feedback on https://core.trac.wordpress.org/ticket/56990
  • @10upsimon Enhancing The WP Scripts APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. with Loading Strategy continues to progress nicely:
    • Continued work on better handling of deferred inline scripts to be strict CSP compliant (in final stages of review)
    • Ongoing work against core PR related to script strategies and the script dependency tree
    • Re-visitation of documentation updates required following recent changes to the body of work introduced via a handful merged PR’s
  • @joemcgill Re Script Loading API: The aim of the current approach is to fully support the Script Loader API, including attached inline styles, while maintaining loading order for backward compatibility so that current blocking scripts can more easily adopt one of the more performant loading strategies. Even though the PR now meets CSP best practices, there is still disagreement about whether this should be included. @westonruter is finishing up some improvements that should finalize the “full” approach. Meanwhile, I’m prepping a path to remove delayed inline handling in order to unblock the main functionality from being committed prior to BetaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. 1.
    • Latest delayed inline scripts approach is happening here
    • Issue to remove delayed inline support for a core merge (if needed) is here
    • I think the main question is whether we end up merging the full implementation or a reduced scope version while continuing to decide on the right approach for supporting inline scripts attached to async/defer scripts.

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

  • @flixos90 I have been reviewing the fetchpriority support PR https://github.com/WordPress/wordpress-develop/pull/4495 that @thekt12 has been working on. It’s getting close to the finish line in terms of core implementation. Once that is sorted out, we’ll have to make sure tests pass and add test coverage for the new functions
    • So that’s not quite ready for a full review yet (mostly due to tests), but feel free to take a look at the main code already

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27

  • @joemcgill No new updates on automated tests, but we’re hoping to add some documentation about how to perform measurements to the Performance Team handbook in the coming weeks (maybe even in time for contributor day at WCEU)

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger

  • @joegrainger For the Plugin Checker, we have completed Milestone 1 and started working on the second phase. This is implementing the initial checks that will be part of the plugins first release. You can follow the progress on the GitHub repo here. Thanks!

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

  • @flixos90 Still awaiting approval of the Dominant Color Images pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party in the plugin repo

Open Floor

  • @spacedmonkey One thing I want to look into after WCEU, is inlining styles. WordPress has ability to inline styles since 5.8. Functionality was added in 5.8 for block styles. But there are other small styles that use this improvement.
    • If you don’t know, in-line styles means outputting css inline in a style tagtag A directory in Subversion. WordPress uses tags to store a single snapshot of a version (3.6, 3.6.1, etc.), the common convention of tags in version control systems. (Not to be confused with post tags.) over a link tag with an external request. This saves a httpHTTP HTTP is an acronym for Hyper Text Transfer Protocol. HTTP is the underlying protocol used by the World Wide Web and this protocol defines how messages are formatted and transmitted, and what actions Web servers and browsers should take in response to various commands. request and faster because of none blocking requests.
    • I am going to create a ticketticket Created for both bug reports and feature development on the bug tracker. and I will share it on this channel if anyone is interested.
    • I also want to document this functionality better for plugin / theme developer are aware of it and start to use it.
    • @10upsimon Curious to hear your thoughts/opinion on potentially also supporting deferred styles @spacedmonkey I know this has come up once or twice in discussions relating to the script loading strategy work. Is this something you feel is worth exploring? Critical CSS is generally inlined, but I feel that non critical css could benefit from deferral in certain situations?
    • @spacedmonkey This is something the team at XWP was looking into a while back. There is a benefit, but you have to know what you are doing. For many plugins and themes, it hard to know when a style is needed. Adding this functionality into core makes sense to me and should works the same way as deferring scripts works.
    • @westonruter Perhaps only feasible to have an API for plugins and themes to register styles that should be delayed.
    • @spacedmonkey The developer api should be the same imo
    • @westonruter Doesn’t seem feasible to do it automatically
    • @10upsimon Certainly would have to be opt-in
    • @joemcgill Finding use cases to defer styles from core would be very helpful to justify a first-party API support
    • @spacedmonkey On a similar note, block themes have ability to load on block styles for blocks core knows are on the page. Would love somehow if that functionality came to classic themes as well. Maybe by parsing all blocks before headers are sent…
    • @westonruter Block themes could actually open up possibilities for automatic delayed styles, come to think of it. If we can determine the blocks that would be in the first viewport, then block styles identified for the page but below the first viewport could be delayed (basically ditto Jonny)
    • @spacedmonkey I haven’t pushed for defer styles as I wanted to see deferred scripts in first. Once scripts is in, we should work on style defer. Even if it is just for constancy
  • @joemcgill Want to make sure that we’re keeping an eye on the performance impact of the new Fonts API that is being worked on for 6.3 in the Gutenberg repo see: https://github.com/WordPress/gutenberg/issues/41479#issuecomment-1522427602

Our next chat will be held on Tuesday, June 13, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Performance Chat Summary: 30 May 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

  • Blogblog (versus network, site) post was published outlining the WordPress 6.2 server performance analysis summary to identify the biggest opportunities to target for future performance enhancements
  • All the lazy-loading PRs were committed last week
  • Notable inclusion in 6.3 #58394 resulting in ~7% faster blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. themes and 2% faster classic themes (full results)
    • FWIW, this was one of the issues identified in the server performance analysis, so it’s really nice to see it already being addressed.
  • @swissspidy committed two minor changes to i18ni18n Internationalization, or the act of writing and preparing code to be fully translatable into other languages. Also see localization. Often written with a lowercase i so it is not confused with a lowercase L or the numeral 1. Often an acquired skill. that slightly improve performance in some cases:

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

  • @joemcgill Other than the analysis already posted, I don’t have any further update, other than wanting to identify some epics out of that work that we can start to take action on.

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones @rjasdfiii

  • No updates this week

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein

  • @10upsimon Enhancing the Script APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. with a loading strategy update:
    • Most of the coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. PR feedback items that are unrelated to the topic of defer/async dependencies and inline scripts have been addressed.
    • Actioning of remaining points of feedback are largely pending the outcome of a final strategic decision around handling deferred and async dependencies, and inline scripts attached to defer/async scripts.
    • Discussions around how best to solve the above are ongoing, with POC’s currently being developed.
  • @joemcgill For the initial design for this feature, we intended to support all current use cases that the Script Loader supported, including support for inline scripts when added to a script handle. @westonruter and @10upsimon have been making good progress on improving that implementation, and it would be useful to have the proposed iteration completed, even if we decide to remove those enhancements for the initial commit.
    • However, I think we’re close to needing to make a decision about what belongs in the initial commit and what can be left for further iteration. Hopefully we can finalize those decisions this week.

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27

  • No updates this week

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger

  • @joegrainger For the Plugin Checker, we are working on the final iterations on the last issue for Milestone 1. Once complete, we will start work on the second phase which will be implementing the initial checks that will be included as part of the plugins first release. You can follow the progress on the GitHub repo here. Thanks!

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

  • @joemcgill Until we have all of the modules published as standalone plugins, we’re blocked on the eventual removal of those modules being bundled with the pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party, which is still the plan.
    • @mukesh27 We already release two plugins can we start removing those from PL?
    • @joemcgill We can start working on the process, but I think we’ll wait on a PL release that removes all of them until we’ve got the UIUI User interface and migrationMigration Moving the code, database and media files for a website site from one server to another. Most typically done when changing hosting companies. path really figured out.
    • @mukesh27 Is there any way to get approval for Dominant Colour Images as it blocks Milestone 2 work?
    • @joemcgill Nope. Just wait our turn in line, just like all the other plugins
    • @flixos90 I think the main priority beyond waiting for the approval is to scope out what we want the user experience for Milestone 2 to be like. We then have to implement that and ship it to allow users to migrate before we actually remove the modules
    • @joemcgill Agreed. And, admittedly, a lot of us have been focused on landing some priority features from our roadmap early this release cycle

Open Floor

  • A question was posted against the agenda this week asking if we can take a look at https://core.trac.wordpress.org/ticket/49278
    • @joemcgill From a quick read of that ticketticket Created for both bug reports and feature development on the bug tracker., it sounds like @peterwilsoncc and @costdev previously determined that the current patchpatch A special text file that describes changes to code, by identifying the files and lines which are added, removed, and altered. It may also be referred to as a diff. A patch can be applied to a codebase for testing. still needs some work before it’s ready to land in core.
    • Not sure if @markparnell is interested in picking this back up, or someone else, but it would need to be ready for another review pretty soon if we wanted to land it in 6.3.
    • @mukesh27
      • Query before (38 seconds)
      • Query after (0.0028 seconds)
      • The improvement is significant as per the ticket description
    • @joemcgill MetaMeta Meta is a term that refers to the inside workings of a group. For us, this is the team that works on internal WordPress sites like WordCamp Central and Make WordPress. queries are a complex part of the API and needs to be handled with care. There are times with meta queries that optimizations are proposed where really the design of a WP_Query needs to be reconsidered (not sure about this case).
    • There are many other proposals in  TracTrac An open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress. tickets that are focused at improving performance of meta queries as well, like adding an extra index to core, etc.
    • @spacedmonkey Any change would need a lot of unit tests. Unit tests for all query classes. So post, term, comment, site and user.

Our next chat will be held on Tuesday, June 6, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Performance Chat Summary: 23 May 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

  • The Performance Lab plugin reached 70k active installations this week
  • Decision on whether to hold the meeting June 6 ahead of travel around WordCampWordCamp WordCamps are casual, locally-organized conferences covering everything related to WordPress. They're one of the places where the WordPress community comes together to teach one another what they’ve learned throughout the year and share the joy. Learn more. Europe
    • Agreed to keep the June 6 meeting

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones @rjasdfiii

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein

  • @10upsimon Enhancing the Script APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. with a loading strategy:
    • Merged @westonruters PR which massively improves how we handle inline script loading
    • Hoping to merge @westonruters PR for removal of $args normalization and flattening of that data, hopefully today
    • Looking for review on adding @covers  in this PR@spacedmonkey if you have a min that would be great
    • Ongoing smaller iterations to the PR as we work through some comms around async handling
    • No further updates at this stage
  • @joemcgill That mostly covers it, I think. I’m seeing lots of progress on this effort over the last few weeks. We’ve got lots of great feedback and continue to discuss specifics about the proposal on the Trac ticketticket Created for both bug reports and feature development on the bug tracker.https://core.trac.wordpress.org/ticket/12009
    • As @10upsimon said, one of the last remaining issue that we’re trying resolve is making sure we’re all on the same page about how to best handle inline scripts, as there has been some disagreement about the best path forward there. Conversation about that topic is happening in this issue: https://github.com/10up/wordpress-develop/issues/63

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

  • @joemcgill Nothing from me either, though I know I’ve seen some updates to improving lazy loading landing over last week.
  • @flixos90 I committed the 4th out of 5 lazy-loading fixes for 6.3 yesterday, and the last PR https://github.com/WordPress/wordpress-develop/pull/4439 looks like it’s close as well. @Jonny Harris You previously requested changes, could you give it another look please?
    • Also anybody else’s feedback would be much appreciated!

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger

  • @joegrainger For the Plugin Checker, we are working on the final issue that came out of the Review/QA. Once done, we’ll be doing some testing to make sure everything is working as expected and start working towards an initial release. You can follow the progress on the GitHub repo here. Thanks!

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

  • No updates this week

Open Floor

  • @spacedmonkey Going to re-share from last week – This discussion has been very active – https://github.com/WordPress/performance/issues/403
    • Worth looking into as team ^
    • @joemcgill Is this something that could be handled in a performance lab module (or other pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party), or does this need to be a direct to coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. proposal?
    • @spacedmonkey I think this one would directly in core. If you want to do this, you can already do it in a plugin…
    • @joemcgill Got it. So, it seems we either need to decide if it’s worth us pursuing a “canonical” version of this plugin that is supported by this team. If not, I think it would be better for this conversation to move from the performance repo and directly to the related Trac ticket. (Also, this is just like, my opinion)
    • @spacedmonkey Personally I am not sure if we should do this in core.
    • This plugin will do the functionality they ask for https://github.com/stuttter/ludicrousdb It is a “canonical” plugin for a lot of advanced database functionality.
    • @johnbillion I can’t see any performance figures anywhere in that ticket, are there any? Lots of theoretical discussion but no numbers
    • @spacedmonkey good point
    • @joemcgill I don’t want to discourage the folks who want to work on this, but if it’s not something this team wants to commit to supporting, then we should politely close the proposal and redirect them to other channels, like Trac or a standalone plugin.
    • @spacedmonkey We need number to validate and an updated patchpatch A special text file that describes changes to code, by identifying the files and lines which are added, removed, and altered. It may also be referred to as a diff. A patch can be applied to a codebase for testing.. Without that, it will have to go to the backlog
  • @westonruter I know there is a problem of orphaned autoloaded options, where plugins add options but don’t clean up after themselves upon uninstall. I know we also have an Autoloaded options Site Health test.
    • Maybe this has already been discussed, but what if the test were extended to check for autoloaded options that aren’t being used anymore?
    • Granted, this wouldn’t need to be a Site Health test and could instead be a cron job.
    • Consider a job that runs once a week which hits the homepage and the most recently-published post, and when running pass a query arg to capture all calls to get_option()
    • @spacedmonkey I am currently writing a document, where I suggest this.
    • @spacedmonkey Have you read this – https://github.com/WordPress/performance/issues/526
    • TDLR, this hooksHooks In WordPress theme and development, hooks are functions that can be applied to an action or a Filter in WordPress. Actions are functions performed when a certain event occurs in WordPress. Filters allow you to modify certain functions. Arguments used to hook both filters and actions look the same. into get_option and tracks what is used on a page load. It when stores an array of used options and then can be used to reset options that are autoloaded but not used.
    • There is a possible of setting autoload no to options that are needed for other parts of WordPress, like sitemaps, rss feeds, rest apis, or the cms
    • There is a chance we could tank performance on some page types and improve it on others.
    • @westonruter Yeah, would need to hit the important endpoints and capture the used options for each
  • @joemcgill I wanted to note that the submission deadline for WCUS is later this week, and it would be great to have good representation from this team. Curious if anyone else is planning to submit anything and if so, I’d be happy to support folks with feedback or idea development this week.

Our next chat will be held on Tuesday, May 30, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Performance Chat Summary: 16 May 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

  • Yesterday saw version 2.3.0 of the Performance Lab pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party released

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

  • @aristath Autoloading PHP classes in WP: I’ve been doing some tests and it looks like this PR improves server response times a bit. More importantly though, it reduces memory usage so that’s a big win. The only “controversial” thing about that PR is that it allows users to override CoreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. classes if they load their own classes with the same name early enough.
    • Pros: No more user hacks in Core files! If users want to override a class in Core, it will be possible. There are many valid reasons and scenarios to do that, since not everything in Core is filterable. What that means is that users will no longer resort to editing Core files directly to do what they need to do – and therefore they will be able to update their sites normally. Responsibility to maintain their own personal overrides falls to them. Maintain your own hacks.
    • Cons: It’s going to be a tough sell.
    • @joemcgill Amazing work to see. Would be useful to know what support or feedback @aristath wants from us to keep this moving forward.
  • @spacedmonkey just created this ticketticket Created for both bug reports and feature development on the bug tracker. #58327
  • @spacedmonkey PRs in need of review
  • @joemcgill For our goal, Identifying and addressing the largest server response time bottlenecks in WordPress core – I’ve drafted a blogblog (versus network, site) post summarizing the performance analysis I did of WP 6.2 and plan to post it this week after getting a few eyes on it. @spacedmonkey who has been an early reviewer and contributor to this work has already been busy spinning up tickets for some of what was discovered.
    • @spacedmonkey The PRs listed above are the “flow hanging fruit” from the review

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones @rjasdfiii

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein

  • @joemcgill We’re continuing to track and respond to feedback on the Trac ticket for adding support for script loading strategies to core. I’ve been focused on trying to get consensus with @azaozz about the open question about how to best support async, and in the meantime, @10upsimon has been reviewing and responding to other feedback, @10upsimon anything to add?
  • @10upsimon I am addressing lower hanging fruit regarding test cases, adding @covers  to tests, and adding failure messages. Regarding @covers it is generally unclear which methods and functions I should be adding, as even though we may test something as simple as an inline script in the after position attached to a deferred script, there are many functions in the logic chain that are affected, such as WP_Scripts::do_item, WP_Scripts::get_eligible_loading_strategy etc. Do we add all, some, mose affected etc? @spacedmonkey this is probably more a discussion with you.
    • @joemcgill Right. I know the WP Core Handbook now has a recommendation to include @covers, but I’m not aware of any specific best practices that have been documented, so some discussion here would be helpful.
    • @westonruter AFAIK the gist of it is if a given test touches a given function/method, you can add @covers to explicitly state those are being tested. (Not clear to me why this can’t be automatically detected though)
    • @spacedmonkey Covers is to note what the test covers. What method or function are you testing in this test.
    • @10upsimon So it should include no methods or functions not explicitly visible in the test function?
    • @joemcgill Official PHPUnit docs is here: https://docs.phpunit.de/en/8.5/annotations.html#appendixes-annotations-covers-tables-annotations
    • Note that the docs explicitly state: This will make sure that code is only marked as covered if there are dedicated tests for it, but not if it used indirectly by the tests for a different class, thus avoiding false positives for code coverage
    • @spacedmonkey Every new method or function should have a test covering it. That is the point of unit tests, to see what is / isnt covered.
    • @10upsimon Sure, and they do, but we have some tests that are so reliant on – for example – other methods in the chain that are critical to the outcome of the test, but not called directly in the test. A good example is WP_Scripts::do_item and  WP_Scripts::get_eligible_loading_strategy, but given that these have dedicated tests, it appears as though adding them via @covers is not needed at all, only against tests solely created for their coverage.
    • @spacedmonkey You can have multiple covers comments if you want. It is common to do this in core, as lots of wrapper functions call an class. It makes sense to mark the class / method and function as covers.
    • @10upsimon ^^ This is where the lines get blurred to me, this is what I have done in a recent PR that I will link to from your PR feedback, I’m just not sure where the buck should stop. Let’s pick this up in the PR itself.
  • @10upsimon I’m addressing @westonruter CSP feedback as next priority, which will also result in changes to the test suite

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27

  • No updates this week

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger

  • @mukesh27 I am currently working on some of the issues for Plugin Checker, and there are some PRs ready for review at https://github.com/10up/plugin-check/pulls/mukeshpanchal27, If anyone has capacity please review it. Thanks!
  • @joegrainer We are working on some of the final issues for the Plugin Checker that came out of the Review/QA. This brings in some bugbug A bug is an error or unexpected result. Performance improvements, code optimization, and are considered enhancements, not defects. After feature freeze, only bugs are dealt with, with regressions (adverse changes from the previous version) being the highest priority. fixes and other enhancements as we work towards an initial release. You can follow the progress on the GitHub repo here. Thanks!

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

  • No updates this week

Open Floor

Our next chat will be held on Tuesday, May 23, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Performance Chat Summary: 9 May 2023

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

  • n/a

Priority Projects

Server Response Time

Link to roadmap projects

Contributors: @joemcgill @spacedmonkey @aristath

Database Optimization

Link to roadmap projects

Contributors: @aristath @spacedmonkey @olliejones @rjasdfiii

  • @spacedmonkey updates above
  • @olliejones I’ve been working on object cache instrumentation, no big results to report
  • @spacedmonkey There a project afoot to add a spec for getting object cache information https://github.com/rhubarbgroup/wp-object-cache-info-spec
    • @olliejones A new revision of this is coming soon, from me
    • @spacedmonkey Basically add a wp_cache_info function to coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. and allow WP CLICLI Command Line Interface. Terminal (Bash) in Mac, Command Prompt in Windows, or WP-CLI for WordPress., query monitor and other tools to understand the cache implementation

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

Link to roadmap project

Contributors: @mukesh27 @10upsimon @adamsilverstein

  • One agenda item here today Discussion this week on CSP/async concerns in https://github.com/WordPress/wordpress-develop/pull/4391
  • @westonruter I left some more feedback related to compatibility with Content-Security-Policy and the deferred inline scripts: the current implementation has a vulnerability related to CSP nonces, and it also blocks Strict CSP by requiring ’unsafe-hashes’ due to the onload attribute. I provided recommendations for how to address these issues and have been discussing with @joemcgill
  • @joemcgill One of my questions about the CSP concerns you raised, @westonruter is whether this whole class of problem would be eliminated if we were to change the way we are approaching async dependencies, or if the problem exists with defer as well? For example, if we weren’t concerned about maintaining loading order (because with async it shouldn’t matter if the scripts are well constructed) then we wouldn’t need to control loading inline scripts so they run after their dependencies.
  • @westonruter Yes, the problem with CSP nonces exists for deferred inline scripts for defer scripts as well
  • @joemcgill Ok, so I’ll need to double check whether it still makes sense for us to control the loading order there, and if so, then work on implementing one of your suggestions. Your explanation and research here has been really valuable, so thank you!
  • @westonruter If we eliminate special support for deferred inline after scripts for async scripts, then we can get rid of the onload attribute and just use addEventListener('load') in an after script.
  • @flixos90 Being unfamiliar with “it also blocks Strict CSP by requiring ’unsafe-hashes’ due to the onload attribute” can you elaborate or share a link with how the onload attribute causes a problem there?”
  • @westonruter sure, CSP’s security model relies on nonces and hashes. For nonces, all script elements on a page should have a nonce attribute which matches a nonce value passed in the Content-Security-Policy response headerHeader The header of your site is typically the first thing people will experience. The masthead or header art located across the top of your page is part of the look and feel of your website. It can influence a visitor’s opinion about your content and you/ your organization’s brand. It may also look different on different screen sizes.. However, such nonces are not possible to be attached to event handler attributes, like onload
  • @flixos90 Your suggestion with addEventListener('load') is problematic if it is wrapped around the inline script because it changes the scope of the code within. This was ruled out as an option early on in the design of this APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. because of that
  • @westonruter Actually not quite because the callback passed to addEventListener('load') still just calls wpLoadAfterScripts(handle) In the same way that onload="wpLoadAfterScripts(handle)" is now
  • @flixos90 Ah, so you mean WP core would handle that event listener on its own?
  • @westonruter It’s just that this change is not compatible with async scripts, but it does work for defer scripts
  • @flixos90 That is the part I don’t understand, why wouldn’t that work for async whereas onload would?
  • @westonruter Because async scripts can load immediately before the rest of the document loads. Example: https://async-script-load-event-listener-test.glitch.me/?delay=500
  • @flixos90 I think the approach of the event listener is definitely preferable, as defer is more important to holistically support at this point, as it works in a simpler way with the current way core handles dependencies
    • That would mean we keep defer functioning like it does now, but will have to (continue to) rethink async support, which I think is okay. I’d also like to throw out there a consideration of potentially only launching with defer in the first version of this
    • That would give us time to decouple the async exploration
  • @joemcgill Apart from getting into the weeds about how to best address the CSP issue, I do think it’s worth a broader discussion about whether our current approach to async scripts is too conservative (mostly to try and help developers avoid loading errors with dependencies).
  • @joemcgill I think the concerns we based the current implementation from are valid, but maybe a bit heavy handed, so I’m open to us being less concerned with load order concerns if everyone is agreed.
  • @westonruter
  • My impression is that async scripts are currently quite rare compared to defer scripts. It’s even rarer that async scripts would depend on each other. But in the cases where they do have dependencies (e.g. AMP) then the loading order is handled in the scripts themselves, and not by source order in the page. Other cases of async scripts having dependencies, e.g. Google Analytics, it’s also handled by the library and loading order doesn’t matter
  • @flixos90 My concern with loosening that is around developer education. We would need to be very clear on what applying async to a script implies. Core would handle defer to always work (make it blocking if needed), but for async it would indeed be on the pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party / theme developer if we loosen the current limits
  • @joemcgill I think that it would be a reasonable position to take, that if you are registering a script that is async or depends on an async script, then it is your responsibility to manage the load order concerns. But agree that dev ed would be important
  • @spacedmonkey FYI, gutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ will likely needed deferred scripts for Interactivity API runtime ( I guess is part of co-op editting ). See https://github.com/WordPress/gutenberg/pull/49994
  • @westonruter Fortunately, there are ample educational materials out there for how async behaves. And devs should only use it if they know what they are doing.
  • @joemcgill Yep! But as this would be somewhat new for WP script enqueueing, we should support that with some WP-focused documentation as well.
  • @joemcgill Unless someone feel strongly that we should NOT make this the responsibility of the developer, @10upsimon and I can work on updating the current approach to allow for a less strict implementation.
  • @flixos90 I think this still deserves more discussion, also with the other now additional consideration that inline scripts would also be responsibility of the developer
  • @westonruter What’s certain is that while we would promote defer, we would need to be very clear in the docs that async order is not predictable. So while defer can often be applied to all scripts, this is definitely not the case for async.
  • @joemcgill Happy to make it a future agenda item here. We’ll also be looking for feedback when we post on make core about the feature and can address it there as well.
  • @flixos90 But more importantly, what about decoupling this discussion? I suggested that above: I think we’re all pretty clear what should happen with defer, but we need to discuss async more
  • @flixos90 Why not remove all async support from the current PR and keep that for an iteration? This allows us to iterate on what is already clear, and gives us time to approach the other problem separately
  • @joemcgill I think we should save that option for if we can’t come to resolution in the next few weeks.
  • @flixos90 That’s fair, though I want to make sure we don’t come to early conclusions and eagerly update the PR with something that is then still being discussed
  • @flixos90 It’s clear that we’re basically “going back to the drawing board” with async. So one could argue that topic is not yet ready for engineering. Having that discussion and providing related comments on the PR makes it more difficult for the folks working on the code to focus on the improvements to the PR that are clear
    • @joemcgill I disagree that we’re going back to the drawing board, but am happy to pick this up async so we can move on with this conversation
    • @flixos90 We are changing the design of how async support works from how it was designed, that’s what I mean by that. Which of course is not a bad thing, but we’re not ready to write code for that because of it still being discussed
    • @joemcgill Yeah, but it seems like a rather small change that will result in reducing the logic we’ve implemented, not adding a lot more, so I’m not all that concerned as long as we get consensus on the correct approach.
  • @clarkeemily I’d like to suggest picking this up async, perhaps on the GitHubGitHub GitHub is a website that offers online implementation of git repositories that can easily be shared, copied and modified by other developers. Public repositories are free to host, private repositories require a paid subscription. GitHub introduced the concept of the ‘pull request’ where code changes done in branches by contributors can be reviewed and discussed before being merged be the repository owner. https://github.com/ issue? We can also add an agenda item to revisit this time next week too if no conclusion is drawn on the GH issue? We have a few more project updates to go through, so we can circle back async

Images

Link to roadmap projects

Contributors: @flixos90 @thekt12 @adamsilverstein @joemcgill

  • @flixos90 Just a quick reminder that the Fetchpriority standalone plugin was published on Friday, the Fetchpriority standalone plugin was approved for wordpress.org. Since we already have the infrastructure for it set up in WordPress/performance, and since we’ve already established that it works with the WebP Uploads standalone plugin, I’m going to go ahead and publish a first version now. Will share progress here

Measurement

Link to roadmap projects

Contributors: @adamsilverstein @olliejones @joemcgill @mukesh27

  • @joemcgill I plan to open a few tickets for some enhancements we’d like to make to the automated performance tooling we added to core during the 6.2 milestone, but no immediate work happening there.

Ecosystem Tools

Link to roadmap projects

Contributors: @joegrainger

  • @joegrainer I have been away the past week so not much to update here from me but I will be working through the issues raised in the Plugin Checker Milestone 1 Review/QA. We have made some progress and closed a few of these out already. You can follow all progress on the GitHub repo here. Thanks!

Creating Standalone Plugins

Link to GitHub overview issue

Contributors: @flixos90 @mukesh27 @10upsimon

Open Floor

  • @thelovekesh Since the performance plugin is expanding in terms of the number of classes, functions, and hooksHooks In WordPress theme and development, hooks are functions that can be applied to an action or a Filter in WordPress. Actions are functions performed when a certain event occurs in WordPress. Filters allow you to modify certain functions. Arguments used to hook both filters and actions look the same. it contains, I believe it would be great to start documenting things so that plugin and theme developers may use them. We can start using the phpdocPHPDoc (docblock, inline docs)-parser to automatically create the necessary documentation from code comments when a release is made and the same can be deployedDeploy Launching code from a local development environment to the production web server, so that it's available to visitors. to the GitHub pages site(https://wordpress.github.io/performance/) or to WordPress.org.

Our next chat will be held on Tuesday, May 16, 2023 at 15:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary