From da57fc7c6cdb0eb49bbae3d35148a0f6cb0e3290 Mon Sep 17 00:00:00 2001 From: Yoshihiro OKUMURA Date: Tue, 6 Jun 2023 17:04:32 +0900 Subject: [PATCH] use utf8 endoding for json output. --- mdrsclient/commands/file_metadata.py | 2 +- mdrsclient/commands/metadata.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mdrsclient/commands/file_metadata.py b/mdrsclient/commands/file_metadata.py index d419fd8..2bc7120 100644 --- a/mdrsclient/commands/file_metadata.py +++ b/mdrsclient/commands/file_metadata.py @@ -29,4 +29,4 @@ class FileMetadataCommand(BaseCommand): raise IllegalArgumentException(f"File `{r_basename}` not found.") file_api = FileApi(connection) metadata = file_api.metadata(file) - print(json.dumps(metadata)) + print(json.dumps(metadata, ensure_ascii=False)) diff --git a/mdrsclient/commands/metadata.py b/mdrsclient/commands/metadata.py index 5d21512..b141844 100644 --- a/mdrsclient/commands/metadata.py +++ b/mdrsclient/commands/metadata.py @@ -21,4 +21,4 @@ class MetadataCommand(BaseCommand): folder = self._find_folder(connection, laboratory, r_path, args.password) folder_api = FolderApi(connection) metadata = folder_api.metadata(folder.id) - print(json.dumps(metadata)) + print(json.dumps(metadata, ensure_ascii=False))