site-kit-wp icon indicating copy to clipboard operation
site-kit-wp copied to clipboard

2nd tile has no data

Open kelvinballoo opened this issue 1 year ago • 1 comments

Bug Description

While testing the audience segmentation epic, I noticed that the 2nd tile doesn't come with value at all. It is always 0, even if it actually should have data. Refer to the screenshots further down where I swapped the positions of an audience where there was a tile with numbers.

Steps to reproduce

  1. Set up 2 tiles under audience segmentation
  2. The 2nd tile will be 0 for the first 4 parameters (even if they should have data)
  3. You can swap the tile order to verify this. To swap, it's just a matter of unselecting the one you want second, save and reselect again.

Screenshots

When 'All Visitors' is in position 1, there is data for the first 4 lines with 5.9K visitors, etc... : Screenshot 2024-06-20 at 19 18 23

When the same tile is swapped in position 2, there is no data. It's worth noting that the analytics figures at the bottom are showing accordingly. Screenshot 2024-06-20 at 19 23 34

Additional Context

  • PHP Version:
  • OS: [e.g. iOS]
  • Browser: [e.g. chrome, safari]
  • Plugin Version: [e.g. 22]
  • Device: [e.g. iPhone6]

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

Acceptance criteria

  • The Audience Tiles should show the correct data for the audiences.
  • Specifically, the tile in the second position should not show zero data when there is in fact data.

Implementation Brief

  • [ ]

Test Coverage

QA Brief

Changelog entry

kelvinballoo avatar Jun 24 '24 10:06 kelvinballoo

Note: I tested this out, with intermittent results. In my initial testing the bug only occurred when the first tile was in the zero data state. However, I tried it again while reviewing Question 3 in this comment, and found the bug occurred while the first tile did have data.

techanvil avatar Jun 27 '24 10:06 techanvil

Hi @kelvinballoo ,

Thank you for reporting this issue.

  1. This seems to be a special case. We are trying to compare the data for last 28 days, but as we can see that New Visitors and Returning Visitors audiences are created only on 20th June, 2024.
  2. So essentially Google Analytics 4 does not have data for last 28 days to compare. If I change it to 14 days, we have the data to compare which is expected.
  3. Specifically for New Visitors and Returning Visitors, this issue will get addressed in #8144 for which we already have the ticket.

@techanvil Please let me know if we should handle this edge case for user created audiences. I think this should get addressed because user created audience can be created at later point and may get added in audience tile, so instead of showing the zero data in rows, we can display the current metrics value and partial data badge (which is already there).

@kelvinballoo Please look at this screencast which shows the above mentioned scenario in SK dashboard.

ankitrox avatar Jul 10 '24 13:07 ankitrox

Hi @ankitrox, as you've pointed out this issue can also occur with user-created audiences that we don't have the special-case handling for. So we do need a general fix for this issue.

techanvil avatar Jul 10 '24 14:07 techanvil

IB :white_check_mark:

techanvil avatar Jul 11 '24 15:07 techanvil

QA Update ✅

  • Tested on main environment.
  • Verified that the Audience Tiles showing the correct data for the audiences.
  • Verified the tile in the second position are not showing zero data when there is in fact data.

Latest environment

image

main environment

image

image

image

image

mohitwp avatar Aug 07 '24 09:08 mohitwp