Skip to content

Breaks trying to write to a file rather than stdout #1

@kergoth

Description

@kergoth
› gr user:books --user_id [my id] >books.xml
Traceback (most recent call last):
  File "/Users/kergoth/.local/bin/gr", line 9, in <module>
    load_entry_point('gr==0.1.0', 'console_scripts', 'gr')()
  File "/Users/kergoth/.local/share/virtualenvs/goodreads_api/lib/python2.7/site-packages/gr.py", line 522, in main
    _dispatch_cmd(method, args)
  File "/Users/kergoth/.local/share/virtualenvs/goodreads_api/lib/python2.7/site-packages/gr.py", line 80, in _dispatch_cmd
    method(args)
  File "/Users/kergoth/.local/share/virtualenvs/goodreads_api/lib/python2.7/site-packages/gr.py", line 307, in user_books
    print(r.text)
UnicodeEncodeError: 'ascii' codec can't encode character u'\u201c' in position 11344: ordinal not in range(128)

Tested on both osx and linux, both configured for en_US.UTF-8 across the board.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions