Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some jpg-images cannot be read #3784

Closed
nkoerb opened this issue Apr 9, 2019 · 4 comments
Closed

Some jpg-images cannot be read #3784

nkoerb opened this issue Apr 9, 2019 · 4 comments

Comments

@nkoerb
Copy link

nkoerb commented Apr 9, 2019

When I try to read an image I get the following error:

from PIL import Image
im = Image.open('..\\WikiArt\\915.jpg')

local variable 'photoshop' referenced before assignment

I think the error is in
https://github.com/python-pillow/Pillow/blob/master/src/PIL/JpegImagePlugin.py

line 139, the indentation should be inside the if-statement

What are your OS, Python and Pillow versions?

  • OS: win10
  • Python: 3.6
  • Pillow: 6.0.0

wikiart-915.jpg:
915

@nulano
Copy link
Contributor

nulano commented Apr 11, 2019

This is probably a duplicate of #3769 and #3772, fixed by #3771.

@nkoerb
Copy link
Author

nkoerb commented Apr 11, 2019

Thank you!

@nkoerb nkoerb closed this as completed Apr 11, 2019
@jschierl
Copy link

Indented this line and it worked. Thanks!!

@klory
Copy link

klory commented Jul 9, 2019

Indented this line and it worked. Thanks!!

What do you mean by indent?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants