Develop WooCommerce

The official WooCommerce development blog

February 27th: Dev chat #19 — February 21, 2018

February 27th: Dev chat #19

The next chat will be on February 27th at 17:00 UTC in the #core channel of the WooCommerce Community Slack. If you don’t already have access to the group, you can request an invite at the bottom of the WooCommerce developers page.

Here is the agenda for the chat:

If you have anything to propose for the agenda or related to the above, please leave a comment below.

See you there!

WooCommerce 3.3.2 fix release notes — February 20, 2018

WooCommerce 3.3.2 fix release notes

WooCommerce 3.3.2 is now available. ~85 commits made it into this release. The full changelog is below.

* Fix - Fixed admin product SKU searching and searching non-published products.
* Fix - PHP7.1 notice when image height is empty.
* Fix - Prevent repeated update_option calls on page load due to php type juggling.
* Fix - Only do unsupported template rendering in the loop to prevent conflicts with other shortcodes on the shop page.
* Fix - Don't prepend regular shortcodes with categories.
* Fix - If using get_catalog_ordering_args. remove the args when finished.
* Fix - Remove "Type" column on attributes table by default unless custom types are defined.
* Fix - Use verbose page rules when shop is in the URL, including shop base with category, to prevent 404s.
* Fix - Set woocommerce_hide_invisible_variations to true so disabled variation attributes are hidden on product pages.
* Fix - Help tip for webhook status.
* Fix - Shipping zone documentation help link was printing wrong.
* Fix - Stop background processing images when disabled via the filter.
* Fix - Only search when a search term is provided. Ignore empty strings.
* Fix - Fix check for external resources.
* Fix - Show full date for future orders.
* Fix - Prevent JS error is 'orders' row is disabled on order screen.
* Fix - Fix save of tax settings when no changes have been made.
* Fix - Add nonce to logout link on my account page so you do not need to confirm the action.
* Fix - API - Set status after order is created/updated so triggered emails are current.
* Fix - API - Fix single webhook endpoint.
* Tweak - Added help text for background image processing.
* Tweak - Added notice when background image processing is running, with cancel button.
* Tweak - Run background image processing less often by tracking changes.
* Tweak - Added system status tool to run background image processing manually.
* Tweak - If using Jetpack Photon, use that instead of background image processing.
* Tweak - Gallery thumbnail image size to handle small, square cropped images.
* Tweak - Helper function (and template version bump for image templates) to render gallery images.
* Tweak - Add help text for the default category to explain usage.
* Tweak - Allow changing the default product category.
* Tweak - Tweak mobile view of order preview to improve layout in non-english.
* Tweak - If selecting text, don't link to order on row click.
* Localization - Remove isle of man state.

Download the latest release of WooCommerce here or venture over to Dashboard → Updates to update your plugins from WordPress.

As usual, if you spot any other issues in WooCommerce core please log them in detail on Github, and to disclose a security issue to our team, please submit a report via HackerOne here. Comments on this post are closed.

Storefront 2.2.8 release notes — February 13, 2018

Storefront 2.2.8 release notes

Storefront 2.2.8 has been tagged for release and uploaded to WordPress.org.

Here’s what’s changed pulled directly from the changelog:

* Fix - Image bleed from next image in the gallery.
* Fix - H1 site title tag on Front page instead of Posts page.
* Fix - Number of columns and rows can now be changed in the Customizer.
* Fix - Logo image size in Internet Explorer.
* Fix - Prevent sidebar from overflowing the content at small sizes on cart page.
* Fix - 404 page responsive layout.
* Tweak - Updated development blog links.
* Feature - WooCommerce Memberships integration.

Download the latest release of Storefront here or venture over to Dashboard → Updates to update your theme from WordPress.

As usual, if you spot any other issues, please log them in detail on Github.

WooCommerce 3.3.1 fix release notes — February 6, 2018

WooCommerce 3.3.1 fix release notes

WooCommerce 3.3.1 is now available. This release fixes conflicts with a handful of themes running template files from 3.2.x that were thus incompatible with the 3.3.0 update.

You may have seen that 3.3.0 was removed from WordPress.org soon after release; this was to give the team time to look deeper into the conflicts being reported and avoid more users running into the same issues.

The issue affected themes with template overrides from 3.2.x that hadn’t been made compatible with 3.3. In general, we recommend that themes use hooks instead of template overrides. Themes such as Storefront (which does not use template overrides) were compatible at launch.

To resolve these issues, we selected a set of the most common themes running on WooCommerce stores and then tested for compatibility with the 3.3.1 release. In addition, some theme authors have tested and released updates to ensure compatibility as well.

Want to read about current best practices around templates and overrides? Read this wiki post.

This has been a learning experience for us, and has highlighted problems in the extensibility of the template system, and a disconnect between our team and theme authors operating on external marketplaces. We hope to find solutions to these problems in the near future.

We’re hopeful the majority of the problems are now resolved and we can push ahead. ~90 commits made it into this release. The full changelog is below.

* Fix - Added `woocommerce_output_product_categories` to replace `woocommerce_product_subcategories` function to prevent outdated theme template files from outputting categories on the shop and category pages in err.
* Fix - Prevented columns from being set to anything lower than 1.
* Fix - Added extra error checking in Webhooks API to prevent notices when deleting Webhooks.
* Fix - Prevented list table classes being loaded multiple times. This also fixes compatibility with Smart Coupons extension.
* Fix - Removed stray debug string from order email template and fixed some typos.
* Fix - Set up the loop when calling wc_get_loop_prop. Fixes compatibility with some themes.
* Fix - Remove multiple application of filter 'woocommerce_order_item_product'.
* Fix - Protect against theme support being defined too late. Fixes some issues with custom themes defining WooCommerce support incorrectly.
* Fix - Add fallback for themes that just get the pagination template.
* Fix - Made the on-the-fly image regen also regenerate missing sizes.
* Fix - Fixed missing user_id in webhook migration script.
* Fix - Allow uncategorized category to be sorted like the others.
* Fix - If theme support changes, we may need to flush permalinks since some are changed based on this flag.
* Fix - Fire hooks for pagination etc only when pagination is enabled.
* Fix - Default HTML in end wrapper template.
* Fix - Prevent regular pagination showing on archives for unsupported themes.
* Fix - Fix shop when shown as homepage in unsupported themes.
* Fix - Fix SKU mapping for placeholders during CSV import.
* Fix - Use CRUD search helper in admin products table so partial SKU search works.
* Fix - Fix bulk sale/regular price percentage handling.
* Fix - More specificity on smallscreen style override for columns.
* Tweak - Add notice for moved store notice setting.
* Tweak - Allow removing coupons on editable orders only.
* Tweak - Extended the background processing library to avoid changing methods in the library.
* Tweak - Do not show row settings if something is managing the number of products per page.
* Tweak - Allow devs to add 'no-link' class to elements to prevent order view link being triggered on row click.
* Tweak - Made woocommerce_resize_images filter more useful by calling it later.
* Tweak - Revert default columns back to 4 so it's consistent with 3.2.

Download the latest release of WooCommerce here or venture over to Dashboard → Updates to update your plugins from WordPress.

As usual, if you spot any other issues in WooCommerce core please log them in detail on Github, and to disclose a security issue to our team, please submit a report via HackerOne here.

WooCommerce 3.3.1 status update — February 1, 2018

WooCommerce 3.3.1 status update

As you may have seen, 3.3.0 was removed from WordPress.org soon after release on Wednesday; this was to give the team time to look deeper into some theme conflicts being reported and to avoid more users running into the same issues.

The severity of the issue was relatively low, however, the volume of users running the impacted themes was potentially high, so we chose to take this safer approach.

The issue affected themes with template overrides from 3.2.x which hadn’t been made compatible with 3.3. In general, we recommend that themes use hooks instead of template overrides. Themes such as Storefront (which does not use template overrides) were compatible at launch.

If you’re unsure if your theme was affected, users have shared their experiences with various themes on the WordPress.org forum around this issue.

Why does WordPress.org list 3.2.6 and not 3.3.0?

To prevent further users downloading 3.3.0 as an automated update from WordPress admin, we reverted the stable version back to 3.2.6.

When 3.3.1 is released, the auto update will be available again for all users.

What should I do if I updated to 3.3?

If you’re running 3.3 already and your theme is compatible, you don’t need to make any changes.

If you have upgraded and saw issues with your theme, check to see if a compatibility update was released – these updates will likely fix issues on your site. For example, Genesis Connect for WooCommerce was affected and has since released a fix.

If you have upgraded, are seeing issues, and no compatibility updates have been released, you have three options:

    1. Just wait for 3.3.1 to be released officially: This path makes sense if you’re not too concerned about the issues you’re seeing.
    2. Update to our pre-release version of 3.3.1 available here: We only recommend this route if you’re comfortable with pre-release versions. More below on what’s already gone into 3.3.1.
    3. Downgrade to 3.2.6 using the WP Rollback plugin: We only suggest going this route if you’re seeing issues you’re concerned about and don’t want to take the risk of a pre-release version.

Aside from the theme issues mentioned above, 3.3 is looking pretty stable. We are running it ourselves on WooCommerce.com without problems, so please only downgrade if absolutely neccessary.

How do I install the pre-release of 3.3.1?

3.3.1-rc.1 can be found on GitHub.

  1. Download the new zip file.
  2. Unzip of your computer.
  3. Upload the woocommerce plugin folder to your site manually following any of these instructions:

Using this pre-release or downgrading should not affect your WooCommerce data as long as you never ‘uninstall’ via admin.

What are you doing to resolve this issue?

To resolve the issues, we selected a set of the most common themes running on WooCommerce stores and then tested for compatibility with the 3.3.1 release. We’ve already tested with more than 40 themes, and we believe 3.3.1 is relatively stable, but are taking the extra time to test more thoroughly.

The fixes already made to 3.3.1 can be found here on GitHub.

When will 3.3.1 be out?

Subject to our continued testing, we’re aiming to have 3.3.1 out early next week (the week of the 5th Feb, 2018). Any further updates or deviations from this will be added to this post as needed.

Thanks for your support.