Skip to content

GT Performance 1.3.2

Choose a tag to compare

@github-actions github-actions released this 15 Oct 13:41
· 9 commits to main since this release
e4b9195

Unused-CSS builds survive deploys, garbage collection works again, and WordPress.org becomes the only package.

  • WordPress.org is the only distribution channel. The self-hosted FluentCart package is retired: src/Licensing (license keys and its own update client) and src/SelfHosted (minified scripts published as static files) are removed, along with the fluentcart build. The plugin header drops Update URI: false and points Plugin URI at /gt-performance/, and the FluentCart product on gauravtiwari.org now links to the directory. Minified scripts are delivered through the signed /?gtperf_js= endpoint in every install, as directory review asked; an edge cache rule for gtperf_js keeps repeat requests off PHP.
  • Uninstall always removes generated script directories, on every site of a network, whether or not data removal is enabled. Pages, styles, and configuration still follow that choice. Seven orphaned .js files from builds before 1.0.11 were still on gauravtiwari.org, and sites that ran the self-hosted package hold a few more.
  • Garbage collection reclaims generated CSS, JavaScript, and font files again. It kept any file read in the last 14 days, and a nightly backup reads every file, which refreshes its access time under relatime, so nothing was ever reclaimed: those seven scripts, written on 2026-08-29, had been read at 03:22 on 2026-10-14. Collection now goes by modification time, which a backup never changes, and every render refreshes the files it links at most once a day: unused-CSS files when a build is reused or arrives at an existing file, and a localized Google Fonts stylesheet when a page links it. Script files no page links any more, such as those left by the retired self-hosted package, are reclaimed once the window passes. A font file stays while a kept stylesheet names it. The window is 14 days, or longer when the page store, stale-if-error, browser, and Cloudflare edge lifetimes add up to more. Files written before the update count from the first collection after it (gt_performance_artifact_keepalive_since, removed on uninstall), so nothing a cached page still links is reclaimed on upgrade.
  • Unused-CSS builds survive deploys that do not change what a build reads. The reuse key held the URL of every stylesheet on the page, including the ones a build never reads, so a deploy that renamed them (?ver= timestamps, content-hashed bundles) rebuilt every page. gatilab.com's theme stylesheets come from a CDN host the engine does not read: 3,775 builds for 1,353 URLs in three days, in waves that started at each theme or plugin deploy, and 1,923 of the latest 2,001 builds produced a CSS file that already existed. The key now keeps the URL only of stylesheets a build reads (StylesheetCollector::reads(), the same test collect() uses); the rest count for where they stand. The key also uses a CSS engine version (UnusedCssOptimizer::ENGINE) instead of the plugin version, so a release that leaves the engine alone no longer rebuilds every page.
  • A URL's reusable builds share one transient (gtperf_css_shapes_*) with its four most recent page shapes, kept for a week instead of a day. An unchanged page was rebuilt every day it was visited. A forced rebuild drops every shape of the URL, which replaces the per-URL revision transient. Uninstall removes the plugin's CSS transients. Each page is rebuilt once after the update.