bito-code-review[bot] commented on PR #44347:
URL: https://github.com/apache/superset/pull/44347#issuecomment-5696992459

   <!-- Bito Reply -->
   The flagged issue is not correct. The test 
`test_export_chart_omits_dataset_uuid_when_dataset_is_gone` correctly handles 
hard-deleted datasets by verifying that the `dataset_uuid` is omitted from the 
chart export when the dataset no longer exists in the database. This is the 
expected behavior for a chart with a dangling `datasource_id` where the dataset 
cannot be resolved, ensuring the export command does not fail while correctly 
reflecting the absence of the related dataset.
   
   **tests/unit_tests/commands/chart/export_test.py**
   ```
   contents = _export(chart)
   
       chart_files = [name for name in contents if name.startswith("charts/")]
       assert len(chart_files) == 1
       assert not [name for name in contents if name.startswith("datasets/")]
       assert "dataset_uuid" not in yaml.safe_load(contents[chart_files[0]])
   ```


-- 
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]

Reply via email to