diff --git a/lastfm/api.py b/lastfm/api.py index bfd2474..b6abaf3 100644 --- a/lastfm/api.py +++ b/lastfm/api.py @@ -177,7 +177,10 @@ class Api(object): return None def get_venue(self, venue): - return self.search_venue(venue)[0] + try: + return self.search_venue(venue)[0] + except IndexError: + return None def search_venue(self, venue): return Venue.search(self, search_item = venue) diff --git a/lastfm/artist.py b/lastfm/artist.py index 7763f4c..b83024f 100644 --- a/lastfm/artist.py +++ b/lastfm/artist.py @@ -311,7 +311,8 @@ class Artist(LastfmBase, Cacheable, Sharable, Shoutable, Searchable, Taggable): ] self._bio = Wiki( self, - published = datetime(*(time.strptime( + published = data.findtext('bio/published').strip() and + datetime(*(time.strptime( data.findtext('bio/published').strip(), '%a, %d %b %Y %H:%M:%S +0000' )[0:6])),