fix(dashboards): Change widget legend series name delimiter#79760
Conversation
Codecov ReportAttention: Patch coverage is ✅ All tests successful. No failed tests found.
Additional details and impacted files@@ Coverage Diff @@
## master #79760 +/- ##
==========================================
+ Coverage 73.30% 78.44% +5.13%
==========================================
Files 7143 7143
Lines 315972 315983 +11
Branches 43487 43493 +6
==========================================
+ Hits 231635 247875 +16240
+ Misses 77862 61774 -16088
+ Partials 6475 6334 -141 |
| const decodedSeriesName = seriesName | ||
| ? WidgetLegendNameEncoderDecoder.decodeSeriesNameForLegend(seriesName) | ||
| : seriesName; | ||
| const aggregateName = decodedSeriesName?.split(':').pop()?.trim(); |
There was a problem hiding this comment.
Not entirely sure if this line is related to your change or not, but does the ':' also have to get replaced with your delimiter here?
Also, are we using , in any special way? I saw something about a series list delimiter. If you group by multiple values those groupings (e.g. group by organization_slug and project) and you get a legend item like org_slug,project iirc.
There was a problem hiding this comment.
this : is not related to the change, that has to do with other legend names :)
also , is fine because we're encoding all the series names before using that delimiter so it doesn't get messed up.
Two things (kind of related)
:however apparently there are series names that have:in the name 🤩 so the widget legend was not working. I changed it to;. Also set this as a constant in the code so changing it requires a couple of line changes instead of searching through the file.Sidenote: if there's any other bugs you notice let me know. Planning to EA on Monday