def get_artist_tags(connect, artist_mbid, maxtags=20):
    """
    Get the musicbrainz tags and tag count given a musicbrainz
    artist. Returns two list of length max 'maxtags'
    Always return two lists, eventually empty
    """
    if artist_mbid is None or artist_mbid == '':
        return [],[]
    # find all tags
    q = "SELECT tag.name,artist_tag.count FROM artist"
    q += " INNER JOIN artist_tag ON artist.id=artist_tag.artist"
    q += " INNER JOIN tag ON tag.id=artist_tag.tag"
    q += " WHERE artist.gid='"+artist_mbid+"'"
    q += " ORDER BY count DESC LIMIT "+str(maxtags)
    res = connect.query(q)
    if len(res.getresult()) == 0:
        return [],[]
    return map(lambda x: x[0],res.getresult()),map(lambda x: x[1],res.getresult())