fbgeobit commented on issue #26130: URL: https://github.com/apache/superset/issues/26130#issuecomment-2022225865
Hi All, Finally I discovered the problem and how to fix it, getting help from a developer colleague (thanks mate!). Below I summarize the problem found and the solution in case others find it useful: - Even though a dashboard is working correctly in your previous installation, when trying to import it from one installation to a new one, many times an error that prevents such importation appears. But that error doesn't provide much details of possible causes. - To get more info about this problem: - In the Internet browser, open the debugging console (in Firefox: press F12 key). - In the 'Network' tab, search for and select the error in fuchsia (possibly a 422). - In the right panel, select the 'Response' tab. - Expand all the fields of the HTTP response JSON to see in which files and fields that build the dashboard structure the error is occurring.  - A common case is that the error is related to incorrect values that are assigned to the `template_params` parameter during the export. When exporting the dashboard, this field acquires the value `template_params: ''` . I think this parameter is related to _jinja SQL templating_ (https://superset.apache.org/docs/installation/sql-templating/). - To fix it, unzip the exported zip file containing the dashboard structure. - Search in the YAML files for the problematic field, based on the file paths and errors described in the JSON file obtained from the browser.  - In the case described, the value `''` should be replaced with `null`: `template_params: null`.  - Compress the directory with the dashboard structure back into the zip file. - Import again the zipped dashboard into your new Superset installation. - Error should not appear. Maybe your error when importing a dashboard is not the same that the one described, but at least, you know how to start debugging it! Hope it helps. Thanks again for your support. -- 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]
