Cart and checkout validation Triggered by Logout – No BuyerJourneyStep for Login/Logout

Topic summary

Issue: A Shopify cart/checkout validation function (restricting purchases to customers with a specific tag) is being invoked during logout. After logout the customer loses the tag, the validation fails, and the logout process is blocked.

Context: The developer checked BuyerJourneyStep (a context indicator of where the buyer is in the flow) and only sees CART_INTERACTION, CHECKOUT_INTERACTION, and CHECKOUT_COMPLETION documented—no logout step. Despite this, the validation still triggers on logout, suggesting no straightforward way to detect and skip it.

Questions raised:

  • Has anyone else seen cart validation fire on logout?
  • Is there a reliable way within the cart/checkout validation function input to detect a logout-triggered call and bypass validation so logout completes?

Artifacts: A screen recording and a screenshot are provided and are central to understanding the behavior.

Status: No resolution or workaround identified yet. The poster seeks confirmation, detection strategies, or best practices to avoid blocking logout while preserving purchase restrictions.

Summarized with AI on December 17. AI used: gpt-5.

I’m encountering an issue with a Shopify function for cart and checkout validation, which checks if only customers with a specific tag are allowed to purchase certain products. During the logout process, it appears that the validation function is unexpectedly triggered. Since the customer is no longer tagged after logging out, this causes the validation to fail, which in turn completely blocks the logout process.

After reviewing the official documentation, I noticed that the available BuyerJourneyStep options are limited to CART_INTERACTION, CHECKOUT_COMPLETION, and CHECKOUT_INTERACTION (reference). There doesn’t seem to be a specific step associated with logout, yet the validation is still being triggered at this point.

My questions are:

  1. Has anyone else encountered issues with cart validation being triggered during logout?
  2. Is there a way to distinguish in the Shopify function for cart and checkout validation if the input is resulting from a logout action? This would allow me to bypass these triggers and ensure the logout process can complete normally.

For a clearer understanding, I’ve attached a screen recording of the issue: Video Link.

Any advice or suggestions on handling this would be greatly appreciated!

Thanks!