This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author JosephArmbruster
Recipients JosephArmbruster
Date 2008-02-13.14:21:03
SpamBayes Score 0.00013074072
Marked as misclassified No
Message-id <1202912464.45.0.11566210495.issue2100@psf.upfronthosting.co.za>
In-reply-to
Content
I receive the following warning when running the test_unicode_file unit
tests out of the trunk (60758)

python  -E -tt ../../lib/test/regrtest.py -g "test_unicode_file"
test_unicode_file
D:\work\pytrunk\lib\test\test_unicode_file.py:103: UnicodeWarning:
Unicode equal comparison failed to convert both arguments to Unicode -
interpreting them as being unequal
  filename1==filename2
D:\work\pytrunk\lib\shutil.py:36: UnicodeWarning: Unicode equal
comparison failed to convert both arguments to Unicode - interpreting
them as being unequal
  os.path.normcase(os.path.abspath(dst)))
1 test OK.

It looks like the warning was meant to be suppressed in
test_unicode_file.py line 104:

# Try using shutil on the filenames.
try:
    filename1==filename2
except UnicodeDecodeError:
    # these filenames can't be compared - shutil.copy tries to do
    # just that.  This is really a bug in 'shutil' - if one of shutil's
    # 2 params are Unicode and the other isn't, it should coerce the
    # string to Unicode with the filesystem encoding before comparison.
    pass


This does not handle the UnicodeWarning, was it meant to?
History
Date User Action Args
2008-02-13 14:21:04JosephArmbrustersetspambayes_score: 0.000130741 -> 0.00013074072
recipients: + JosephArmbruster
2008-02-13 14:21:04JosephArmbrustersetspambayes_score: 0.000130741 -> 0.000130741
messageid: <1202912464.45.0.11566210495.issue2100@psf.upfronthosting.co.za>
2008-02-13 14:21:03JosephArmbrusterlinkissue2100 messages
2008-02-13 14:21:03JosephArmbrustercreate