On 2016-10-17, eryk sun wrote:
> On Mon, Oct 17, 2016 at 2:20 PM, Adam Funk wrote:
>> I'm using IDLE 3 (with python 3.5.2) to work interactively with
>> Twitter data, which of course contains emojis. Whenever the running
>> program tries to print the text of a tweet with an emoji, it barfs
>> th
On Tue, Oct 18, 2016 at 2:09 AM, Chris Angelico wrote:
> That's not a UTF-16 encoded byte string, though. It's a Unicode string
> that contains two surrogates. So maybe the solution is to convert from
> true Unicode strings into strings like the above - but if so, it
> absolutely must not be done
On Tue, Oct 18, 2016 at 10:23 AM, eryk sun wrote:
> I don't know whether it causes problems elsewhere in Tk, but it has no
> problem passing along a UTF-16 string to Windows. For example, see the
> following with a breakpoint set on TextOut [1]:
>
> >>> root = tkinter.Tk()
> >>> w = tkinte
On Mon, Oct 17, 2016 at 8:35 PM, Random832 wrote:
> On Mon, Oct 17, 2016, at 14:20, eryk sun wrote:
>> You can patch print() to transcode non-BMP characters as surrogate
>> pairs. For example:
>>
>> On Windows this should allow printing non-BMP characters such as
>> emojis (e.g. U+0001F44C).
>
> I
On Mon, Oct 17, 2016, at 14:20, eryk sun wrote:
> You can patch print() to transcode non-BMP characters as surrogate
> pairs. For example:
>
> On Windows this should allow printing non-BMP characters such as
> emojis (e.g. U+0001F44C).
I thought there was some reason this wouldn't work with tk, o
On Mon, Oct 17, 2016 at 2:20 PM, Adam Funk wrote:
> I'm using IDLE 3 (with python 3.5.2) to work interactively with
> Twitter data, which of course contains emojis. Whenever the running
> program tries to print the text of a tweet with an emoji, it barfs
> this & stops running:
>
> UnicodeEncod
On 2016-10-17, Adam Funk wrote:
> I'm using IDLE 3 (with python 3.5.2) to work interactively with
> Twitter data, which of course contains emojis. Whenever the running
> program tries to print the text of a tweet with an emoji, it barfs
> this & stops running:
>
> UnicodeEncodeError: 'UCS-2' co
I'm using IDLE 3 (with python 3.5.2) to work interactively with
Twitter data, which of course contains emojis. Whenever the running
program tries to print the text of a tweet with an emoji, it barfs
this & stops running:
UnicodeEncodeError: 'UCS-2' codec can't encode characters in
position 10