def gridLog(**kw):
 import os
 if (not bool(int(os.environ.get('GRIDLOG_ON', 0)))):
  return
 url = os.environ.get('GRIDLOG_DEST')
 if (url is None):
  return
 try:
  scheme = url[:url.find('://')]
  send = GLRegistry[scheme]
  send(url, str(GLRecord(**kw)))
 except Exception as ex:
  print >>sys.stderr, ('*** gridLog failed -- %s' % str(kw))

def gridLog ( ** kw ) : import os if ( not bool ( int ( os . environ . get ( 'GRIDLOG_ON' , 0 ) ) ) ) : return url = os . environ . get ( 'GRIDLOG_DEST' ) if ( url is None ) : return try : scheme = url [ : url . find ( '://' ) ] send = GLRegistry [ scheme ] send ( url , str ( GLRecord ( ** kw ) ) ) except Exception as ex : print >> sys . stderr , ( '*** gridLog failed -- %s' % str ( kw ) )
send glrecord .