github-cli icon indicating copy to clipboard operation
github-cli copied to clipboard

HATES ascii

Open esacteksab opened this issue 12 years ago • 4 comments

✗ gh gist 2995997    
https://gist.github.com/2995997: Sublime Text 2 - Useful Shortcuts
Traceback (most recent call last):
  File "/home/bmorriso/.virtualenvs/github-cli/bin/gh", line 8, in <module>
    load_entry_point('gh-cli==0.1.b', 'console_scripts', 'gh')()
  File "/home/bmorriso/.virtualenvs/github-cli/local/lib/python2.7/site-packages/gh_cli-0.1.b-py2.7.egg/gh/main.py", line 29, in main
    status = commands[command].run(opts, args[1:])
  File "/home/bmorriso/.virtualenvs/github-cli/local/lib/python2.7/site-packages/gh_cli-0.1.b-py2.7.egg/gh/commands/gist/__init__.py", line 27, in run
    print('{0.filename}\n{0.content}\n'.format(f))
UnicodeEncodeError: 'ascii' codec can't encode character u'\u21e7' in position 305: ordinal not in range(128)

esacteksab avatar Oct 03 '13 01:10 esacteksab

Yep. Strings basically suck in Python. ;)

In a side-note we can totally figure out a good way of working around this.

sigmavirus24 avatar Oct 03 '13 01:10 sigmavirus24

well my puppy self has sort of figured this much out https://gist.github.com/esacteksab/1602f7cd5162a3161c03

On Wed, Oct 2, 2013 at 6:39 PM, Ian Cordasco [email protected]:

Yep. Strings basically suck in Python. ;)

In a side-note we can totally figure out a good way of working around this.

— Reply to this email directly or view it on GitHubhttps://github.com/sigmavirus24/github-cli/issues/14#issuecomment-25591390 .

esacteksab avatar Oct 03 '13 01:10 esacteksab

https://twitter.com/KCombinator/status/385580686742020096 https://twitter.com/KCombinator/status/385580826492030976

esacteksab avatar Oct 03 '13 01:10 esacteksab

https://twitter.com/nriley/status/385583740832841729

Link from above Tweet -- just in case https://wiki.python.org/moin/PrintFails

esacteksab avatar Oct 03 '13 01:10 esacteksab