Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions dataQuest/preprocessor/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,9 @@ def save_as_json_compressed(data: Dict[str, Union[Dict[str, str], Dict[int, Dict
output_file (str): Path to the output JSON file.
"""
try:
with gzip.open(output_file, 'wt') as json_file:
json.dump(data, json_file, indent=4)
with gzip.open(output_file, 'wt', encoding='utf-8') as json_file:
json.dump(data, json_file, indent=4, ensure_ascii=False)

except Exception as e:
logging.error(f"Error saving compressed JSON to {output_file}: {e}") # noqa: E501

Expand Down