Traceback using "bzr log lp:bzr-email"

Andrew Bennetts andrew at canonical.com
Mon Jan 21 10:02:03 GMT 2008


Andrew Bennetts wrote:
> John Arbash Meinel wrote:
[...]
> > It might also be a different bug. Since it seems that
> > 
> >   bzr log bzr+ssh://bazaar.launchpad.net/~bzr/bzr-email/trunk
> > 
> > Is giving a "Not A Branch" error, whil
> > 
> >   bzr log sftp://bazaar.launchpad.net/~bzr/bzr-email/trunk
> > 
> > seems to work just fine.
> 
> It's due to the smart client in bzr.dev sending "%7E" rather than "~" in the
> relpaths it transmits.  I think the client should be sending UTF-8 rather than
> URL-encoded.  I'll try to fix that today.

This is a bit more awkward than it first looked; the encoding of paths in the
smart protocol hasn't been particularly explicitly defined.

As doc/developers/HACKING.txt points out, URLs are not unicode, and while they
can be url-decoded to bytes, the encoding of those bytes is ambiguous so you
don't know what characters they are supposed to represent.  Similiarly URL
components (i.e. relpaths) that transports handle are also not unicode.

However clearly the server in 1.1 and earlier is not expecting URL-encoded
relpaths, even though these are fed to transports.  I haven't yet decided how to
cope with this cleanly.  I suppose the client can mostly send URL-decoded
byte strings...

-Andrew.




More information about the bazaar mailing list