product.selling_plan_groups array (liquid) is sometimes empty

Topic summary

Core Issue:
The product.selling_plan_groups Liquid object intermittently returns empty arrays despite products having selling plan groups attached. This occurs on initial page load after cache clearing, even when requires_selling_plan: true is set.

Impact:

  • Broken add-to-cart functionality
  • Missing subscription/selling plan UI elements
  • Customer complaints across multiple merchants
  • Affects apps and themes relying on selling plan data

Timeline & Status:

  • Issue first reported with reproducible examples across Chrome, Firefox, and Safari
  • Occurred at least twice: ~August 10th (15:00 UK) and August 14th (~18:15 UK)
  • Fix deployed: August 15, 2023 at ~15:00 UTC
  • Post-fix reports: Multiple users (Ugurcan, Bhvavdip, olatief, MC_Elliot) continue experiencing the issue on their stores

Workaround Attempted:
Changing condition to check != blank instead of size > 0 passes the condition but doesn’t resolve the underlying empty data problem.

Current State:
Despite the reported fix, the issue appears ongoing for some merchants. LarryReid requested new reports be posted as separate topics to determine if these are regressions or distinct problems.

Summarized with AI on November 6. AI used: claude-sonnet-4-5-20250929.

In our liquid template, we check if product.selling_plan_groups.size > 0 (confirming a product has a selling plan group attached) and display some HTML if so. We recently started getting reports that the HTML was not being rendered. After further investigation, we found that if the cache was cleared then product.selling_plan_groups would be empty even if the product has a selling plan group attached. So a first-time visitor to a merchant’s store would not see the HTML since product.selling_plan_groups has a size of 0.

Etra_0-1691609241813.png

Etra_1-1691609280071.png

We have replicated the issue on Chrome, Firefox, and Safari for the Dawn and Debut themes.

4 Likes

Hi Etra,

If you change the condition to {% if product.selling_plan_groups.size != blank %} is the HTML rendering as you’d expect?

@Liam The condition passes but that does not change the fact that the data from the product liquid object still does not have the correct selling_plan_groups data. It is still empty. If I make some changes(even just adding a comment) to the template then the data is loaded correctly and it works. Again this issue happens(data is incorrect) upon the initial page load. On other page loads the data is there and correct.

This product definitely has a selling plan group attached. Here is the initial page load:

@Liam I mean you can even see above the product requires a selling plan. requires_selling_plan: true

So how can the array be empty if it requires a selling plan. I can give you example merchant links in private if you like where I am able to replicate it consistently.

This is a serious issue. I don’t know why this hasn’t been looked at. Many merchants are starting to reach out to our support about it. For years it has worked just fine. Nothing has changed on our end in terms of using liquid objects to display some selling plan groups. Other apps do this and even some themes as well. Everyone is affected, merchants, customers, app developers. This needs to be fixed…

Hi Etra - our dev teams are still working on a fix for this, will update when I learn more.

1 Like

@Liam We are also experiencing this issue on multiple stores too. It has lead to broken add to cart functionality and customer complaints. After having worked for months, without any code or product/selling plan changes {{ variant.selling_plan_allocations[0].selling_plan.id }} started outputting nothing for a period of time, before fixing itself. {{ variant.id }} continued to output as expected. This has happened at least two times that we are aware of ~15:00 UK time on August 10th, and again yesterday (August 14th) ~18:15 UK time.

1 Like

We shipped a fix for this 2023-08-15 15 h 00 UTC approximately. Please let us know if it’s still not working.

3 Likes

Will do, thank you.

@Liam this is still empty for me on a dev store. I can confirm Selling Plan is created and product is associated with the plan group but still empty.

Any ideas?

Thanks for letting us know. Please post your question in a new topic in this forum, with a complete description of how to reproduce it. The original problem was definitely fixed and has not regressed, so this is a new problem. Thanks in advance.

The same issue is occurring in my store.

Found this thread because it’s still an issue for us.

3 Likes

Hi,
Has the solution for this problem been found in the end?
I would like to display the discounted prices based on the selling_plan, but the arrays remain empty.