GitHub user dosubot[bot] added a comment to the discussion: Error while 
exporting datasources in superset version 2.1.0

<!-- Answer -->
The export-datasources command raises DatasetNotFoundError if any dataset ID in 
the metadata database can't be fully validated or referenced during export—even 
if those datasets appear in the UI. Both the CLI and UI use the same dataset 
model and query logic, so this usually points to a database integrity issue, 
like orphaned records or incomplete dataset entries. It's possible that at 
least one dataset is missing required data or relationships, causing the export 
to fail for all datasets. 

To troubleshoot, check your Superset logs for details about which dataset is 
causing the error. You can also query your metadata database directly to look 
for datasets with missing or invalid references (for example, missing 
database_id, table_name, or related objects). Fixing or removing any 
problematic entries should resolve the export issue. More details on the 
validation logic are here: [export command 
source](https://github.com/apache/superset/blob/829e4d92d91ceae4b43b1ed3b063ffe45377799c/superset/commands/export/models.py).


<!-- 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/8051b6b3-b09e-41df-8bbd-a59111f41330?feedback_type=great_response)
 | 
[Irrelevant](https://app.dosu.dev/response-feedback/8051b6b3-b09e-41df-8bbd-a59111f41330?feedback_type=irrelevant_answer)
 | 
[Incorrect](https://app.dosu.dev/response-feedback/8051b6b3-b09e-41df-8bbd-a59111f41330?feedback_type=incorrect_sources)
 | 
[Verbose](https://app.dosu.dev/response-feedback/8051b6b3-b09e-41df-8bbd-a59111f41330?feedback_type=too_verbose)
 | 
[Hallucination](https://app.dosu.dev/response-feedback/8051b6b3-b09e-41df-8bbd-a59111f41330?feedback_type=hallucination)
 | [Report 
🐛](https://app.dosu.dev/response-feedback/8051b6b3-b09e-41df-8bbd-a59111f41330?feedback_type=bug_report)
 | 
[Other](https://app.dosu.dev/response-feedback/8051b6b3-b09e-41df-8bbd-a59111f41330?feedback_type=other)</sup>&nbsp;&nbsp;[![Chat
 with 
Dosu](https://dosu.dev/dosu-chat-badge.svg)](https://app.dosu.dev/a28d3c7e-a9d3-459e-9fb6-3a6f9ff4f357/ask?utm_source=github)&
 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/discussions/35483)

GitHub link: 
https://github.com/apache/superset/discussions/35483#discussioncomment-14585010

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: 
[email protected]


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

Reply via email to