plotly.JSONDataset not saved as utf-8 #741
Labels
good first issue
Good for newcomers
Hacktoberfest
help wanted
Contribution task, outside help would be appreciated!
Description
It can happen that the saved plotly.JSONDataset is not encoded as utf-8. Supplying the file system args as follows fixes the issue:
However, that should be the default behaviour. The question is why there is a problem when the encoding is not explicitly set here.
Context
I had an issue with the encoding of saved plotly plots (as json) via the kedro data catalog. After saving the plots I could not read the plots anymore via the catalog. It failed with the error
'utf-8' codec can't decode byte 0xe8 in position 6570: invalid continuation byte
. Investigating that further, I managed to read those files with a different encoding (e.g. latin-1). I did not understand though why the files are not valid utf-8 in the first place. Adding that fs_args mentioned above solved the issues.Steps to Reproduce
Expected Result
There should not be any encoding issues happening, because it is expected that files are saved as utf-8.
Actual Result
The file was not saved in utf-8.
Your Environment
Include as many relevant details about the environment in which you experienced the bug:
pip show kedro
orkedro -V
): 0.19.5pip show kedro-airflow
): 3.0.0python -V
): 3.11.7The text was updated successfully, but these errors were encountered: