From 3a9d89d6812f042600a72e9633e37954f6e08d3b Mon Sep 17 00:00:00 2001 From: Walter Bender Date: Tue, 04 Oct 2011 13:26:28 +0000 Subject: only try to import the datastore when running Sugar #3133 --- (limited to 'plugins') diff --git a/plugins/turtle_blocks_extras/turtle_blocks_extras.py b/plugins/turtle_blocks_extras/turtle_blocks_extras.py index 831eb3c..a142d78 100644 --- a/plugins/turtle_blocks_extras/turtle_blocks_extras.py +++ b/plugins/turtle_blocks_extras/turtle_blocks_extras.py @@ -20,11 +20,6 @@ from time import time import os.path from gettext import gettext as _ -try: - from sugar.datastore import datastore -except ImportError: - pass - from plugins.plugin import Plugin from TurtleArt.tapalette import make_palette, define_logo_function from TurtleArt.talogo import primitive_dictionary, logoerror, \ @@ -936,6 +931,7 @@ bullets')) n[6:].lower not in media_blocks_dictionary: try: if self.tw.running_sugar: + from sugar.datastore import datastore try: dsobject = datastore.get(n[6:]) except: -- cgit v0.9.1