superset icon indicating copy to clipboard operation
superset copied to clipboard

Mapbox API_KEY not recognized

Open clauslor opened this issue 7 years ago • 6 comments

Make sure these boxes are checked before submitting your issue - thank you!

  • [x] I have checked the superset logs for python stacktraces and included it here as text if there are any.
  • [x] I have reproduced the issue with at least the latest released version of superset.
  • [x] I have checked the issue tracker for the same issue and I haven't found one similar.

Superset version

0.28.1

Expected results

show the underlying map

Actual results

Notifies "A valid API access token is required to use Mapbox data"

Steps to reproduce

  1. followed https://superset.incubator.apache.org/installation.html installation instructions.
  2. setup PYTHONPATH
  3. obtained mapbox api key
  4. created superset_config.py as in https://superset.incubator.apache.org/installation.html#configuration
  5. started superset in virtualenv using superset runserver -d

I have also changed the default port to 8080 in the superset_config.py which worked fine but the api key was still not recognized. Edit: The API key works fine in other projects.

clauslor avatar Mar 29 '19 12:03 clauslor

do you console print some log like Loaded your LOCAL configuration at [superset/superset_config.py]? if not, try to set environment SUPERSET_CONFIG_PATH=/path/to/your/superset/superset_config.py to tell superset where config file it is

bllli avatar Apr 01 '19 12:04 bllli

do you console print some log like Loaded your LOCAL configuration at [superset/superset_config.py]?

Yes, it does.

clauslor avatar Apr 01 '19 22:04 clauslor

I guess your config file isn't successfully loaded. try to add print('configuration loaded') to the bottom of your superset_config.py , to make sure it loaded ok

bllli avatar Apr 02 '19 06:04 bllli

To test / debug, you can open an interpreter and run import superset_config, and see if it loads properly.

For more context, here's where it's auto-loaded: https://github.com/apache/incubator-superset/blob/master/superset/config.py#L621-L625

mistercrunch avatar Apr 05 '19 06:04 mistercrunch

I guess your config file isn't successfully loaded. try to add print('configuration loaded') to the bottom of your superset_config.py , to make sure it loaded ok

I did this as you suggested but it didn't help.

clauslor avatar Apr 12 '19 10:04 clauslor

how to obtain mapbox api key

garima301984 avatar Jul 22 '19 16:07 garima301984