Identify automatic str/unicode coercions
Martin Pool
mbp at canonical.com
Tue Jun 17 03:18:40 BST 2008
On Tue, Jun 17, 2008 at 10:54 AM, Martin von Gagern
<Martin.vGagern at gmx.net> wrote:
> Martin Pool wrote:
>>
>> Could you post a small sample of the reports here and we'll have a look?
>
> Sure. The attached report is the result of a simple "bzr init foo" on a
> machine called "server".
Thanks very much, that is quite a neat summary, especially the way it
combines similar errors.
> Most of these implicit conversions seem to decode fixed literals, so that's
> harmless. The most likely part here to cause real trouble would probably be
> that part about the nonce, although I guess this simple operation is still
> well away from causing any harm.
Right, many of them do seem to be literals, and so even with this nice
summary of the data it may be hard to remove the noise from this list.
Maybe we can do something clever to detect which ones really come
from literals vs elsewhere, but it seems a bit like an inherent
problem under python2.x. (I believe it will get better in py3k with a
clearer distinction between bytes and unicode strings.)
If you want to search through the list and find specific cases that
are broken that could be good. I'll look at your other locale patch.
> This is nothing final, of course, but I'd guess a useful tool nonetheless.
> Maybe some dev wants to adopt the branch, to keep the tool around and
> improve on it as need arises?
As you've put the branch up on Launchpad we can find it later.
--
Martin <http://launchpad.net/~mbp/>
More information about the bazaar
mailing list