def getArtistId(artist):
  u"""j-lyrics.netでのアーティストのIDを取得
  """
  params = {"ka": artist,}
  baseurl = "http://search.j-lyric.net/index.php"
  r = requests.get(baseurl, params=params)
  soup = BeautifulSoup(r.content)

  urls = soup.find("div", id="lyricList").findAll("a")
  r = re.compile(r'http://j-lyric.net/artist/\w+/')

  for url in urls:
    href = url.get("href")
    if href.startswith("http://j-lyric.net/artist/"):
      return href.split("/")[-2]
  if verbose:
    logger.warning(artist + ": Not found")

  return None