def getmod(modname):
  try:
    __import__(modname)
  except ImportError, e:
    logging.warn("import failed: %s." % e)
    return None
  mod = sys.modules[modname]
  return mod
dataset/ETHPy150Open IanLewis/kay/kay/ext/jsonrpc2/__init__.py/getmod/original