dosubot[bot] commented on issue #34024:
URL: https://github.com/apache/superset/issues/34024#issuecomment-3027112843

   <!-- Answer -->
   This is a known issue with the World Map chart: even if you select ISO 3166 
alpha-2 (cca2) codes for your dataset and chart, clicking a country in the map 
emits a filter using the alpha-3 (cca3) code. This happens because the frontend 
plugin logic does not consistently use the selected "country field type" when 
emitting filter values for dashboard filters, causing a mismatch if your other 
charts expect cca2 codes. There is currently no user-facing configuration or 
documented workaround to force the World Map chart to emit filter values in the 
same code format as your dataset, and this behavior is not documented in the 
official docs or tracked in existing issues or pull requests. The relevant code 
is in the frontend plugin for the World Map chart, specifically in how it 
constructs the filter value for cross-filtering based on the country field type 
you select, but it does not always honor your selection for emitted filter 
values, leading to this bug.  
   You can review the relevant implementation details in the chart plugin code 
[here](https://github.com/apache/superset/blob/308007f909b5a3c1cdd6fc5632ef27ca7eb97ce0/superset-frontend/plugins/legacy-plugin-chart-world-map/src/WorldMap.js).
   
   
   <!-- Dosu Comment Footer -->
   *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).*
   
   ---
   <sup>How did I do? 
[Good](https://app.dosu.dev/response-feedback/ede21287-6d58-444d-bd02-4dd53cb429f0?feedback_type=great_response)
 | 
[Irrelevant](https://app.dosu.dev/response-feedback/ede21287-6d58-444d-bd02-4dd53cb429f0?feedback_type=irrelevant_answer)
 | 
[Incorrect](https://app.dosu.dev/response-feedback/ede21287-6d58-444d-bd02-4dd53cb429f0?feedback_type=incorrect_sources)
 | 
[Verbose](https://app.dosu.dev/response-feedback/ede21287-6d58-444d-bd02-4dd53cb429f0?feedback_type=too_verbose)
 | 
[Hallucination](https://app.dosu.dev/response-feedback/ede21287-6d58-444d-bd02-4dd53cb429f0?feedback_type=hallucination)
 | [Report 
🐛](https://app.dosu.dev/response-feedback/ede21287-6d58-444d-bd02-4dd53cb429f0?feedback_type=bug_report)
 | 
[Other](https://app.dosu.dev/response-feedback/ede21287-6d58-444d-bd02-4dd53cb429f0?feedback_type=other)</sup>&nbsp;&nbsp;[![Join
 
Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[!
 [Share on 
X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/issues/34024)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to