Adding encoding to `open` in`to_json`

pull/33/head
KOLANICH 2019-07-23 06:42:44 +00:00 committed by GitHub
parent d1db9bd443
commit d8c6d0eb77
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -599,7 +599,7 @@ class Table(object):
kw = {"orient": "records"} kw = {"orient": "records"}
kw.update(kwargs) kw.update(kwargs)
json_string = self.df.to_json(**kw) json_string = self.df.to_json(**kw)
with open(path, "w") as f: with open(path, "w", encoding="utf-8") as f:
f.write(json_string) f.write(json_string)
def to_excel(self, path, **kwargs): def to_excel(self, path, **kwargs):