Did I find the right examples for you? yes no

All Samples(21)  |  Call(20)  |  Derive(0)  |  Import(1)

src/p/y/pyastre-0.9.9/examples/setvar.py   pyastre(Download)
##
from pyastre.channel import Channel
from twisted.python.log import debug, err
 
def execute(c, args):
	return
 
    debug("setvar: setting chan[%s] = %s" % (key, value))
 
    chan = Channel(c)

src/s/m/smartproxy-HEAD/smartproxy/reducer.py   smartproxy(Download)
			def reduce_finished(response):
				self.return_to_pool(reducer)
				log.debug("ReduceQueue: success, queue size %d, pool size %d" % (len(self.queue), len(self.pool)))
				cb(response)
 
			def reduce_failed(*args, **kwargs):
				self.return_to_pool(reducer)
				log.debug("ReduceQueue: failure, queue size %d, pool size %d" % (len(self.queue), len(self.pool)))
			reducer.feed(keys, lines, reduce_finished, reduce_failed)
		else:
			log.debug("ReduceQueue: success, queue size %d, pool size %d" % (len(self.queue), len(self.pool)))
 
class ReducerProcessProtocol(protocol.ProcessProtocol):
 
		if len(self.lines)==0:
			log.debug("nothing to reduce")
			self._deferred.callback( ([], "") )
			return
 
		for line in self.lines:
			log.debug("Sending line to reducer %s" % line)

src/s/m/smartproxy-HEAD/smartproxy/proxy.py   smartproxy(Download)
			def succeed(*args, **kwargs):
				log.debug("ClientQueue: success, queue size %d, reqs out %d" % (len(self.queue), self.count))
				self.count -= 1
				try:
					success(*args, **kwargs)
			def fail(*args, **kwargs):
				log.debug("ClientQueue: failure, queue size %d, reqs out %d" % (len(self.queue), self.count))
				self.count -= 1
				try:
					err(*args, **kwargs)
			defer.addErrback(fail)
		else:
			log.debug("ClientQueue: queue size %d, reqs out %d" % (len(self.queue), self.count))
 
def make_success_callback(request):
		if request.uri in self.in_progress:
			self.in_progress[request.uri].append(request)
			log.debug("Attaching request for %s to an earlier request for that uri" % request.uri)
		else:
			self.in_progress[request.uri] = [request]
 
				# send the cached copy back to the client synchronously
				log.debug("Using cached copy of " + request.uri)
				send_output(response)
 

src/s/m/smartproxy-HEAD/smartproxy/fetcher.py   smartproxy(Download)
		def handle_success(data):
			log.debug("ViewFetcher: handle_succes")
			if not self._failed:
				self._deferred.callback(data)