コード例 #1
0
	def __call__(self, *params, **keywords):
		"""Override to replace the SDBResponseError 
		with a BadRequest error"""
		try:
			return RequestHandler.__call__(self, *params, **keywords)
		except SDBResponseError, e:
			raise BadRequest("Invalid Query", description=str(e))
コード例 #2
0
ファイル: robots.py プロジェクト: ssalkeld/botoweb
 def __init__(self, env, config):
     """Set up and fetch the routes for the first time"""
     RequestHandler.__init__(self, env, config)
コード例 #3
0
	def __init__(self, env, config):
		RequestHandler.__init__(self, env, config)
		db_class_name = self.config.get('db_class', None)
		if db_class_name:
			self.db_class = find_class(db_class_name)
		xmlize.register(self.db_class)
コード例 #4
0
ファイル: index.py プロジェクト: ssalkeld/botoweb
	def __init__(self, env, config):
		"""Set up and fetch the routes for the first time"""
		RequestHandler.__init__(self, env, config)