[GitHub] thrift issue #1289: fix TypeError when a py3 str is passed to the function.

2018-03-19 Thread jeking3
Github user jeking3 commented on the issue: https://github.com/apache/thrift/pull/1289 @nsuke there must be some common wisdom and/or tooling to facilitate the conversion from py2 to py3 in this regard - what have other projects done when facing this issue? ---

[GitHub] thrift issue #1289: fix TypeError when a py3 str is passed to the function.

2017-10-29 Thread nsuke
Github user nsuke commented on the issue: https://github.com/apache/thrift/pull/1289 Basically yes with some note. It's typically not a UTF-8 encoded binary. To write utf8 strings we can use `writeString`. The point is that `writeBinary` is for writing binaries. The

[GitHub] thrift issue #1289: fix TypeError when a py3 str is passed to the function.

2017-10-28 Thread jeking3
Github user jeking3 commented on the issue: https://github.com/apache/thrift/pull/1289 @nsuke it sounds like you would recommend that we do not accept this fix, and have people do their own conversion before trying to add a string, to make sure it is a byte string (UTF-8 encoded).

[GitHub] thrift issue #1289: fix TypeError when a py3 str is passed to the function.

2017-10-28 Thread nsuke
Github user nsuke commented on the issue: https://github.com/apache/thrift/pull/1289 It's more of a usability problem. The problem is that the user is passing a non-`byte` instance to `writeBinary`. It's basically the same error as when you pass str `'42'` (not integer `42`)

[GitHub] thrift issue #1289: fix TypeError when a py3 str is passed to the function.

2017-10-28 Thread jeking3
Github user jeking3 commented on the issue: https://github.com/apache/thrift/pull/1289 Based on what I've read about py3 strings, and the fact that thrift strings are designated to be encoded as UTF8, this change seems correct. I'm not so sure about what happens on the other side

[GitHub] thrift issue #1289: fix TypeError when a py3 str is passed to the function.

2017-10-25 Thread jeking3
Github user jeking3 commented on the issue: https://github.com/apache/thrift/pull/1289 Could you open a Jira ticker for this? https://thrift.apache.org/docs/HowToContribute Also could you rebase on master and refresh the PR so we get a clean build, now that CI is

[GitHub] thrift issue #1289: fix TypeError when a py3 str is passed to the function.

2017-09-21 Thread jeking3
Github user jeking3 commented on the issue: https://github.com/apache/thrift/pull/1289 Could you open a Jira ticker for this? https://thrift.apache.org/docs/HowToContribute Also could you rebase on master and refresh the PR so we get a clean build, now that CI is