@Krisseck opened this Issue on January 11th 2023

When viewing the chart for Acquisition Overview, for example the text "Search Engines" is translated to "Search%20Engines" in the chart, and the data is not shown.

Expected Behavior

The chart should show correct labels for the records, and it should actually show the related data.

Current Behavior

Records with spaces (%20) in them are not shown in chart, and the label is wrong.

image

image

Possible Solution

Convert space characters correctly in the chart.

Also, if you manually click on the relevant checkboxes on "Records to plot", it will show them correctly.

Steps to Reproduce (for Bugs)

  1. Go To "Acquisition"
  2. Go To "Overview"
  3. The chart should have labels with "%20" in them.

Note: I cannot reproduce this bug in the demo, since records with spaces in them (like "Search Engines") is not pre-selected. This bug only seems to occur if they are pre-selected on page load.

Context

It's just bad UX :) to show labels with "%20" in them and no data.

Your Environment

  • Matomo Version: 4.13.0
  • PHP Version: 8.0.26
  • Server Operating System: Ubuntu (running official docker image)
  • Additionally installed plugins:
  • Browser: Firefox 108
  • Operating System: Arch Linux
@bx80 commented on January 12th 2023 Contributor

Thanks for spotting this @Krisseck, I can confirm this is an issue when metrics are pre-selected :+1:

The steps I used for recreation were:

  1. Go To "Acquisition > Overview"
  2. In the "Evolution over period" chart choose a metric with spaces in the name, eg. "Search Engines", it will be displayed properly at this point.
  3. Navigate away to another page, eg. the Dashboard
  4. Return to "Acquisition > Overview", the pre-selected metrics which should have spaces will have %20 instead.
@sgiehl commented on January 12th 2023 Member

This might be a regression from https://github.com/matomo-org/matomo/pull/13935
as it added a url encode to the parameters:
https://github.com/matomo-org/matomo/blob/56efd4c7d06aef3435cf531ab6264529eb7fc9b3/plugins/CoreVisualizations/javascripts/seriesPicker.js#L108-L119

Guess we can't simply remove it again, as it was added for some reason. Guess we might need to decode it somewhere to get that fixed.

Powered by GitHub Issue Mirror