Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

booksサブコマンドがCP932にエンコードできない文字があると落ちる #14

Open
mtsukamoto opened this issue Jul 31, 2016 · 1 comment

Comments

@mtsukamoto
Copy link

booksサブコマンドをWindows環境、引数なしで実行するとエラーが起きました。
エラーメッセージから、返ってきたデータ中にCP932にエンコードできない文字があって落ちたのかな、と思いました。

C:\Users\tsukamoto\temp\aozora-cli>python ./bin/aozora books
Traceback (most recent call last):
(略)
 File "C:\Users\ap745667\temp\aozora-cli\aozoracli\cli.py", line 19, in books
   'title': title,
 File "C:\Users\ap745667\temp\aozora-cli\aozoracli\books.py", line 21, in main
   print(books)
UnicodeEncodeError: 'cp932' codec can't encode character '\xd6' in position 88210: illegal multibyte sequence

Windows固有(CLIがCP932)の気もするので、後回しでいいかも。

@yasuhiroki
Copy link
Collaborator

おおお.....(汗
試せていませんが、デフォルトエンコーディングをutf8にすれば解決できないでしょうか...

http://yukihir0.hatenablog.jp/entry/20110131/1296478348

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants