apache-superset/superset-ui-plugins-deckgl

NaN in formatCategoryLabel() in deck.gl Scatterplot

Closed this issue · 5 comments

Describe the bug
The property Point Color using a string field as a Dimension results in a Legend with NaN values in deck.gl Scatterplot

To Reproduce
Steps to reproduce the behavior:

  1. Build a deck.gl Scatterplot chart
  2. Click on Point Color
  3. Select 'Original value' and choose a string as dimension
  4. See error NaN in Legend

Expected behavior
Selecting 'Original value' as Legend format must bypass D3 formatting and print the string Dimension categories as is.

Environment (please complete the following information):

  • superset-ui version: [Version: 0.999.0dev]

Additional context
When 'Original value' is selected, this.props.format = '~g'. In formatCategoryLabel() only checks if !this.props.format to return unformatted values.
A workaround, as suggestion, is to change

to
if (!this.props.format || this.props.format==='~g') {

Any hope to get this fixed soon? This is very annoying, I can't find any workarounds. It worked in previous versions, but now:
Screenshot 2021-07-01 at 15 54 15

S-eb commented

Same issue here. And I agree this is impacting

This is fixed, but not released yet :( apache/superset#15738

I just hit this.

The codebase on this repo has been moved to the main Apache Superset repo, and consequently the repo is in the process of being archived. See the Superset Improvement Proposal for details: apache/superset#13013 . While all currently open issues and PRs will be closed, we encourage you to reopen this issue on the main repo if it is still relevant.