You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "SBIN2010 (via GitHub)" <gi...@apache.org> on 2025/09/05 19:53:15 UTC
[I] import error where template_params is empty string [superset]
SBIN2010 opened a new issue, #35037:
URL: https://github.com/apache/superset/issues/35037
### Bug description
how to reproduce the error:
1) In the dataset settings, go to the Settings tab
2)In the Template parameters, enter any parameter
3)save dataset settings
4)Reopen the dataset settings for editing and delete the previously entered Template parameters
5)save dataset settings
6)Export an object (dashboard, chart or the dataset itself) that contains this dataset
7) Execute import
### Screenshots/recordings
<img width="759" height="398" alt="Image" src="https://github.com/user-attachments/assets/d7e5b7e2-991c-4cae-a534-cdfa00d1c313" />
<img width="904" height="249" alt="Image" src="https://github.com/user-attachments/assets/8dbe31dc-3c4e-4f32-9d41-aa03f206bb6d" />
### Superset version
master / latest-dev
### Python version
3.9
### Node version
16
### Browser
Chrome
### Additional context
_No response_
### Checklist
- [ ] I have searched Superset docs and Slack and didn't find a solution to my problem.
- [ ] I have searched the GitHub issue tracker and didn't find a similar bug report.
- [ ] I have checked Superset's logs for errors and if I found a relevant Python stacktrace, I included it here as text in the "additional context" section.
--
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: notifications-unsubscribe@superset.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] import error where template_params is empty string [superset]
Posted by "mistercrunch (via GitHub)" <gi...@apache.org>.
mistercrunch closed issue #35037: import error where template_params is empty string
URL: https://github.com/apache/superset/issues/35037
--
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: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] import error where template_params is empty string [superset]
Posted by "dosubot[bot] (via GitHub)" <gi...@apache.org>.
dosubot[bot] commented on issue #35037:
URL: https://github.com/apache/superset/issues/35037#issuecomment-3259587054
<!-- Answer -->
This error happens because Superset exports `template_params` as a string (which can be an empty string), but the import process expects it to be a dictionary or null. If you clear the template parameters and save, the exported YAML will have `template_params: ""`, which causes a validation error on import since it's not a valid mapping type [reference](https://github.com/apache/superset/blob/829e4d92d91ceae4b43b1ed3b063ffe45377799c/superset/datasets/schemas.py).
To work around this, before importing, open the exported YAML and change any line like `template_params: ""` to either `template_params: {}` or remove the line entirely. This will let the import succeed.
Recent code changes have improved error handling for template processing, but this specific normalization for `template_params` is not yet handled automatically [reference](https://github.com/apache/superset/pull/34803). Until that's addressed, manual YAML editing is the best workaround.
<!-- 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/01d39344-2073-4c0c-9d93-7c8dff711eb2?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/01d39344-2073-4c0c-9d93-7c8dff711eb2?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/01d39344-2073-4c0c-9d93-7c8dff711eb2?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/01d39344-2073-4c0c-9d93-7c8dff711eb2?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/01d39344-2073-4c0c-9d93-7c8dff711eb2?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/01d39344-2073-4c0c-9d93-7c8dff711eb2?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/01d39344-2073-4c0c-9d93-7c8dff711eb2?feedback_type=other)</sup> [](https://app.dosu.dev/a28d3c7e-a9d3-459e-9fb6-3a6f9ff4f357/ask?utm_source=githu
b) [](https://go.dosu.dev/discord-bot) [](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/issues/35037)
--
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: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org