def log_hooks(debug=False):
 request = cherrypy.serving.request
 msg = []
 from cherrypy import _cprequest
 points = _cprequest.hookpoints
 for k in request.hooks.keys():
  if (k not in points):
   points.append(k)
 for k in points:
  msg.append(('    %s:' % k))
  v = request.hooks.get(k, [])
  v.sort()
  for h in v:
   msg.append(('        %r' % h))
 cherrypy.log(((('\nRequest Hooks for ' + cherrypy.url()) + ':\n') + '\n'.join(msg)), 'HTTP')

def log_hooks ( debug = False ) : request = cherrypy . serving . request msg = [ ] from cherrypy import _cprequest points = _cprequest . hookpoints for k in request . hooks . keys ( ) : if ( k not in points ) : points . append ( k ) for k in points : msg . append ( ( '    %s:' % k ) ) v = request . hooks . get ( k , [ ] ) v . sort ( ) for h in v : msg . append ( ( '        %r' % h ) ) cherrypy . log ( ( ( ( '\nRequest Hooks for ' + cherrypy . url ( ) ) + ':\n' ) + '\n' . join ( msg ) ) , 'HTTP' )
write request .