apache / superset

Apache Superset is a Data Visualization and Data Exploration Platform
https://superset.apache.org/
Apache License 2.0
61.86k stars 13.55k forks source link

Bangladesh is missing in country map dropdown selection for Country Map Chart #30223

Closed hsnbd closed 1 week ago

hsnbd commented 1 week ago

Bug description

Bangladesh Missing from Country Map Chart

Apache Superset Version: 4.0.2 (installed via pip in a virtual environment)

Issue: Bangladesh is missing from the Country Map Chart in my installation, despite an update being committed in this github repo 4 months ago that added several countries, including Bangladesh.

Commit reference

Could this be an issue with the 4.0.2 release, or do I need to take additional steps to ensure the Country Map Chart includes Bangladesh?

How to reproduce the bug

  1. Goto charts
  2. Select Country Map and Dataset
  3. Create a new chart
  4. Find Bangladesh in Country list dropdown

Screenshots/recordings

No response

Superset version

4.0.2

Python version

3.10

Node version

18 or greater

Browser

Chrome

Additional context

No response

Checklist

dosubot[bot] commented 1 week ago

Hello @hsnbd! I'm here to help you with any bugs, questions, or contributions you have for Apache Superset. Let's work together to solve this issue.

I found a similar issue regarding the inclusion of countries in the Country Map Chart. The issue of Bangladesh missing from the Country Map Chart in Apache Superset version 4.0.2 is not related to the release itself. The GeoJSON data for Bangladesh is present in the source files, so additional steps are required to ensure its inclusion in the chart.

You need to verify that the GeoJSON data for Bangladesh is correctly referenced and loaded in your Superset configuration. Ensure that the data source for the Country Map Chart includes the path to the Bangladesh GeoJSON file and that the chart configuration correctly references this data.

Here is an example of how you might include the GeoJSON data in your Superset configuration:

import bangladeshGeoJson from 'path/to/bangladesh.geojson';

// Example configuration for the Country Map Chart
const countryMapChartConfig = {
  geoJson: bangladeshGeoJson,
  // other configuration options
};

// Ensure the chart is using the correct configuration
SupersetChart.registerChart('country_map', countryMapChartConfig);

Make sure the path to the bangladesh.geojson file is correct and that the file is accessible by your Superset instance [1].

Additionally, you might want to check the configuration and implementation of the Country Map Chart component in the Superset codebase. The component is defined and configured in the file superset-frontend/plugins/legacy-plugin-chart-country-map/src/index.js and implemented in superset-frontend/plugins/legacy-plugin-chart-country-map/src/ReactCountryMap.jsx [2][3].

To continue talking to Dosu, mention @dosu.

rusackas commented 1 week ago

Features don't get cherried into patch releases. It'll be part of 4.1, which you can test now.