OmegaPhil / animecheck

Commandline CRC32, MD5 and eD2k-based hashing script also capable of reading and creating SFV and MD5 checksum files and generating eD2k links. This is an initial foray into python and github
GNU General Public License v3.0
46 stars 5 forks source link

Unable to cope with [2008.09.03] 6th Story CD 『Moira』.sfv #4

Closed OmegaPhil closed 11 years ago

OmegaPhil commented 12 years ago

In checksum read mode:

Traceback (most recent call last):
  File "/mnt/Storage_1/Desktop Files/Linux Programming/Python/animecheck/animecheck.py", line 1320, in <module>
    checksum_read_mode(args)
  File "/mnt/Storage_1/Desktop Files/Linux Programming/Python/animecheck/animecheck.py", line 1050, in checksum_read_mode
    print('\nProcessing \'' + passedFile + '\'...\n')
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe3 in position 65: ordinal not in range(128)
OmegaPhil commented 12 years ago

Problem appears to be introduced as soon as you try to concatenate.

OmegaPhil commented 12 years ago

Python was treating arguments as ASCII strings - so failed when unicode characters were involved. Fixed in f860188df1

OmegaPhil commented 11 years ago

wiiaboo has reported:

This doesn't work in Python 3.

AttributeError: 'str' object has no attribute 'decode'

https://github.com/OmegaPhil/animecheck/commit/f860188df1125cd4c8e7bfcb238437e7158bfc9a#commitcomment-2063046

wiiaboo commented 11 years ago

Only byte arrays have decode() in Python 3. Strings only have encode(), because they're always utf-8, by default.

OmegaPhil commented 11 years ago

Cheers - as I've done some work on animecheck recently, it will be some time before I reach this again.