Wp-calypso: "Flash" of visitors/visits bars across Stats and Insights page

Created on 2 Mar 2020  Â·  12Comments  Â·  Source: Automattic/wp-calypso

Steps to reproduce

  1. Starting at URL: https://wordpress.com/stats/day/[anysite]
  2. If you do not see it upon loading the page, try refreshing.

What I expected

There should be no flash of these bars.

What happened instead

screenshot

Browser / OS version

Happening across Safari, Firefox and Chrome across Mac OS and PC
(Am on a team meetup and my team is able to recreate the issue as well)

Screenshot / Video

Example videos:
https://d.pr/v/1VTaVS
https://d.pr/i/sEFWaj

Stats [Type] Bug

All 12 comments

I was seeing this for some time, but can not reproduce at this time. @eamcgill90 Are you still able to reproduce this?

I've been seeing this multiple times a day — both Safari and Chrome desktop browsers, with different users.

Seems kind of bad... it looks clunky and broken for 1-2 seconds before correcting itself.

After some further testing I think something in stats must be cached locally so this only happens consistently the first time you view them until that's cleared.

I think I've been seeing it often when checking user's sites that I haven't loaded before, but couldn't reproduce on my main sites because I've viewed them all recently. Once I checked a site I check less frequently I was able to reproduce the issue.

I can still reproduce this as well, but only only the first stats load for any given site.

I can no longer reproduce the issue.

Heh, funny that a "welcome back" behavior would be to show the broken UI for a second. 😄

@eamcgill90 That's likely why you don't see it again, already cached from a recent visit.

What is likely the underlying fix is to preload or fetch the bars before rending the graph.

Shared this in Slack today to hopefully get a look from a @Automattic/team-calypso developer. In case it's something that might indicate a timing issue or performance change in recent refactoring. CC @griffbrad

This could depend on CSS bundles loading order, which depends on order you visit pages on Calypso.

I've been trying to reproduce, but unsuccessfully. Is it possible that this occurs only on certain sites? I've started clean multiple times, for different sites (with little and with a LOT of stats) and no luck. Can anyone reproduce consistently with a certain site/user?

Here's one way to reproduce, with a user that has more than 1 site — ideally 5 to 10 sites or more that you don't visit often.

Steps:

  1. Log in with Safari, and go to Stats (/stats/day/example.com
  2. Click "Switch Site" at top left of sidebar
  3. Choose another site from the list — one you haven't used in a while
  4. Watch the stats graph; it'll be all the lines for a second or two

Sorry about that, but I'm currently on a long leave, perhaps someone else could take a look?

Testing in Safari, Firefox, and Chrome today across 3 different WordPress.com users I was not able to repeat the behavior any more.

Closing for now as "works for me."

Was this page helpful?
0 / 5 - 0 ratings