Bytes filenames should be accepted with Python 3. They are accepted with Python 2. An application might want to use bytes filenames to avoid problems with undecodable characters.
$ python2.7 -c 'import PIL.Image; PIL.Image.open(b"file.png")'
$ python3.3 -c 'import PIL.Image; PIL.Image.open(b"file.png")'
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/usr/lib64/python3.3/site-packages/PIL/Image.py", line 1993, in open
prefix = fp.read(16)
AttributeError: 'bytes' object has no attribute 'read'
Also there is NameError in line 491 of PIL/JpegImagePlugin.py with Python 3.
Bytes filenames should be accepted with Python 3. They are accepted with Python 2. An application might want to use bytes filenames to avoid problems with undecodable characters.
Also there is NameError in line 491 of PIL/JpegImagePlugin.py with Python 3.