diff options
author | W. Trevor King <wking@drexel.edu> | 2008-11-24 22:03:20 -0500 |
---|---|---|
committer | W. Trevor King <wking@drexel.edu> | 2008-11-24 22:03:20 -0500 |
commit | 0f3f492bd1c9db89b98f719f7371b183c9c8d838 (patch) | |
tree | a868c6b75c252afc935a18fd42983897e9ef7ccf /.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a | |
parent | e6d48051cbce1f74ec3c50fc0ccb72003258889e (diff) | |
download | bugseverywhere-0f3f492bd1c9db89b98f719f7371b183c9c8d838.tar.gz |
Hack to fixe encoding bug in becommands/show
The situation really calls for a global encoding setting rather than
lots of hardcoded "utf-8"s. See bug
f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a
Diffstat (limited to '.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a')
5 files changed, 100 insertions, 0 deletions
diff --git a/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/15602c0c-25e4-4c2c-9e24-79bdb90721b1/body b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/15602c0c-25e4-4c2c-9e24-79bdb90721b1/body new file mode 100644 index 0000000..d97791d --- /dev/null +++ b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/15602c0c-25e4-4c2c-9e24-79bdb90721b1/body @@ -0,0 +1,14 @@ +$ be show 31cd490d-a1c2-4ab3-8284-d80395e34dd2 + +works as expected, but + +$ be show 31cd490d-a1c2-4ab3-8284-d80395e34dd2 | grep something +Traceback (most recent call last): + File "/home/wking/bin/be", line 30, in <module> + sys.exit(cmdutil.execute(sys.argv[1], sys.argv[2:])) + File "/home/wking/src/fun/be-bugfix/libbe/cmdutil.py", line 57, in execute + File "/home/wking/src/fun/be/be.wtk/becommands/show.py", line 44, in execute + print bug.string(show_comments=True) +UnicodeEncodeError: 'ascii' codec can't encode character u'\u2019' in position 2100: ordinal not in range(128) + +By the way, u2019 is a fancy apostrophe. diff --git a/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/15602c0c-25e4-4c2c-9e24-79bdb90721b1/values b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/15602c0c-25e4-4c2c-9e24-79bdb90721b1/values new file mode 100644 index 0000000..f976972 --- /dev/null +++ b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/15602c0c-25e4-4c2c-9e24-79bdb90721b1/values @@ -0,0 +1,21 @@ + + + +Content-type=text/plain + + + + + + +Date=Tue, 25 Nov 2008 02:36:16 +0000 + + + + + + +From=W. Trevor King <wking@drexel.edu> + + + diff --git a/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/3f556a48-c538-4569-8609-3e829b561d78/body b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/3f556a48-c538-4569-8609-3e829b561d78/body new file mode 100644 index 0000000..7bb09ff --- /dev/null +++ b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/3f556a48-c538-4569-8609-3e829b561d78/body @@ -0,0 +1,9 @@ +Solution here +http://www.amk.ca/python/howto/unicode + +You need to encode before printing. + +This is unfortunate, because we're currently very glib about just +printing info to the terminal. This makes it much more important to +have a single bugdir-wide encoding specification... + diff --git a/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/3f556a48-c538-4569-8609-3e829b561d78/values b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/3f556a48-c538-4569-8609-3e829b561d78/values new file mode 100644 index 0000000..bf5085b --- /dev/null +++ b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/comments/3f556a48-c538-4569-8609-3e829b561d78/values @@ -0,0 +1,21 @@ + + + +Content-type=text/plain + + + + + + +Date=Tue, 25 Nov 2008 03:02:59 +0000 + + + + + + +From=W. Trevor King <wking@drexel.edu> + + + diff --git a/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/values b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/values new file mode 100644 index 0000000..40ac06d --- /dev/null +++ b/.be/bugs/f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a/values @@ -0,0 +1,35 @@ + + + +creator=W. Trevor King <wking@drexel.edu> + + + + + + +severity=minor + + + + + + +status=open + + + + + + +summary=UTF-8 encoding trouble with pipes in becommands/show + + + + + + +time=Tue, 25 Nov 2008 02:30:35 +0000 + + + |