Re: [PATCH v2 6/8] git-remote-testpy: hash bytes explicitly

2013-01-17 Thread Junio C Hamano
John Keeping writes: > On Thu, Jan 17, 2013 at 02:24:37PM -0800, Junio C Hamano wrote: >> John Keeping writes: >> >>> You're right - I think we need to add ", errors='replace'" to the call >>> to encode. >> >> Of if it is used just as a opaque token, you can .encode('hex') or >> something to p

Re: [PATCH v2 6/8] git-remote-testpy: hash bytes explicitly

2013-01-17 Thread John Keeping
On Thu, Jan 17, 2013 at 02:24:37PM -0800, Junio C Hamano wrote: > John Keeping writes: > >> You're right - I think we need to add ", errors='replace'" to the call >> to encode. > > Of if it is used just as a opaque token, you can .encode('hex') or > something to punt on the whole issue, no? Eve

Re: [PATCH v2 6/8] git-remote-testpy: hash bytes explicitly

2013-01-17 Thread Junio C Hamano
John Keeping writes: > You're right - I think we need to add ", errors='replace'" to the call > to encode. Of if it is used just as a opaque token, you can .encode('hex') or something to punt on the whole issue, no? > >> > git-remote-testpy.py | 8 >> > 1 file changed, 4 insertions(+)

Re: [PATCH v2 6/8] git-remote-testpy: hash bytes explicitly

2013-01-17 Thread John Keeping
On Thu, Jan 17, 2013 at 09:00:48PM +, John Keeping wrote: > On Thu, Jan 17, 2013 at 12:36:33PM -0800, Junio C Hamano wrote: >> John Keeping writes: >> >>> Under Python 3 'hasher.update(...)' must take a byte string and not a >>> unicode string. Explicitly encode the argument to this method a

Re: [PATCH v2 6/8] git-remote-testpy: hash bytes explicitly

2013-01-17 Thread John Keeping
On Thu, Jan 17, 2013 at 12:36:33PM -0800, Junio C Hamano wrote: > John Keeping writes: > >> Under Python 3 'hasher.update(...)' must take a byte string and not a >> unicode string. Explicitly encode the argument to this method as UTF-8 >> so that this code works under Python 3. >> >> This moves

Re: [PATCH v2 6/8] git-remote-testpy: hash bytes explicitly

2013-01-17 Thread Junio C Hamano
Junio C Hamano writes: > John Keeping writes: > >> Under Python 3 'hasher.update(...)' must take a byte string and not a >> unicode string. Explicitly encode the argument to this method as UTF-8 >> so that this code works under Python 3. >> >> This moves the required Python version forward to 2

Re: [PATCH v2 6/8] git-remote-testpy: hash bytes explicitly

2013-01-17 Thread Junio C Hamano
John Keeping writes: > Under Python 3 'hasher.update(...)' must take a byte string and not a > unicode string. Explicitly encode the argument to this method as UTF-8 > so that this code works under Python 3. > > This moves the required Python version forward to 2.0. > > Signed-off-by: John Keepi

[PATCH v2 6/8] git-remote-testpy: hash bytes explicitly

2013-01-17 Thread John Keeping
Under Python 3 'hasher.update(...)' must take a byte string and not a unicode string. Explicitly encode the argument to this method as UTF-8 so that this code works under Python 3. This moves the required Python version forward to 2.0. Signed-off-by: John Keeping --- git-remote-testpy.py | 8 +