google / site-kit-wp

Site Kit is a one-stop solution for WordPress users to use everything Google has to offer to make them successful on the web.
https://sitekit.withgoogle.com
Apache License 2.0
1.23k stars 279 forks source link

Zero Data Notification Not Appearing consistently - on First Load in New Tab/Window #9227

Open mohitwp opened 3 weeks ago

mohitwp commented 3 weeks ago

Bug Description

If the zero data notification is not dismissed and the user opens the dashboard in a new tab or window, the zero data state notification does not appear on the first load. The user must refresh the page for the notification to appear. This behavior is observed on both the main and entity dashboards. However, this issue does not occur with the gathering data state notification.

Scenario 1

Steps to reproduce

  1. Set up Site Kit with Analytics.
  2. Make sure both Analytics and Search Console are in zero data state.
  3. Open main dashboard in new tab.
  4. Notification will not appear.
  5. Now refresh the page.
  6. Notification will appear after refresh.

Screenshots

https://github.com/user-attachments/assets/64238b26-4ac3-453a-8e06-d1f7509a93f8

Scenario 2

Steps to reproduce

  1. Set up site kit without Analytics connected.
  2. Ensure Search Console is in Zero Data state.
  3. Load the main dashboard.
  4. ZeroDataNotification does not appear consistently (appears sometimes).

Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

Implementation Brief

Test Coverage

QA Brief

Changelog entry

jimmymadon commented 1 week ago

@mohitwp I have added another Scenario 2 as well with the latest main branch here. You can add any other scenario here too for this notification.

mohitwp commented 1 week ago

@jimmymadon I’ve observed that the "zero data" notification appears upon reload if both Analytics and SC are connected. However, if only SC is connected and is in a zero data state, the notification appears only once. It does not reappear upon reload or if we log in from another browser or open the dashboard in a new tab. I will add this scenario under #9227. Same issue exist on latest environment also.

https://github.com/user-attachments/assets/64222246-a799-44e6-8d98-943f5003f4e8
eugene-manuilov commented 1 week ago

AC ✔️

tofumatt commented 3 days ago

IB ✅