Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: packagerChrome.py

Issue 6214230382477312: Noissue - Fix PIL import (Closed)
Patch Set: Created Aug. 8, 2014, 2:52 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: packagerChrome.py
===================================================================
--- a/packagerChrome.py
+++ b/packagerChrome.py
@@ -51,7 +51,10 @@
return data
def makeIcons(files, filenames):
- from PIL import Image
+ try:
+ from PIL import Image
+ except ImportError:
+ import Image
icons = {}
for filename in filenames:
width, height = Image.open(StringIO(files[filename])).size
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld