[New-bugs-announce] [issue4889] difflib

Pratik Potnis report at bugs.python.org
Fri Jan 9 06:49:39 CET 2009


New submission from Pratik Potnis <pratik.potnis at gmail.com>:

While using function HtmlDiff() from Library difflib, if there is
difference in caps of two strings it does not provide proper diff results.
Two strings in two different files in this context that I used are:
hostname vaijain123 and (this string is in small caps)
hostname CAVANC1001CR1 (This one is in large caps)

Expected behavior after diffing : It should show hostname changed (and
highlight it with Yellow color)

instead of this it is showing Added in one file and deleted in another
file. (Highlighting them with green and red color respectively)

When tried with same caps (either small or large) it shows expected
behavior(highlighting the strings in yellow color). Also with numbers it
works well.

I think its an issue with the CAPS of letters. difflib is not able to
differentiate between the caps of letters.

----------
components: Library (Lib)
files: c1.ios
messages: 79455
nosy: pratik.potnis
severity: normal
status: open
title: difflib
type: behavior
versions: Python 2.5
Added file: http://bugs.python.org/file12659/c1.ios

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue4889>
_______________________________________


More information about the New-bugs-announce mailing list