1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
|
Description: Fix PIL import
see http://lists.debian.org/debian-python/2013/02/msg00017.html for details.
Author: Daniele Tricoli <eriol@mornie.org>
Last-Update: 2013-07-09
--- a/circuits/web/apps/memorymonitor/__init__.py
+++ b/circuits/web/apps/memorymonitor/__init__.py
@@ -6,8 +6,11 @@
import threading
from types import FrameType, ModuleType
-import Image
-import ImageDraw
+try:
+ from PIL import Image, ImageDraw
+except ImportError:
+ import Image
+ import ImageDraw
from circuits import handler
from circuits.web import Controller
|