Skip to content

Commit

Permalink
Add meaningful, consistent error message for scrapers build number ha…
Browse files Browse the repository at this point in the history
…ndling (#121) - use exact same error message
  • Loading branch information
piri-p committed May 6, 2024
1 parent b95c144 commit 09a2082
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions mozdownload/scraper.py
Original file line number Diff line number Diff line change
Expand Up @@ -543,7 +543,7 @@ def get_build_info_for_date(self, date, build_index=None):
break

if build_index >= len(parser.entries):
raise errors.NotFoundError('Specified build number is not found ', url)
raise errors.NotFoundError('Specified build number has not been found ', url)

self.logger.info('Selected build: %s' % parser.entries[build_index])

Expand Down Expand Up @@ -766,7 +766,7 @@ def get_build_info(self):
self.build_index = 0
self.logger.info('Selected build: build%s' % self.build_number)
else:
raise errors.NotFoundError('Specified build has not been found', url)
raise errors.NotFoundError('Specified build number has not been found ', url)

@property
def candidate_build_list_regex(self):
Expand Down Expand Up @@ -990,7 +990,7 @@ def get_build_info_for_index(self, build_index=None):
break

if build_index >= len(parser.entries):
raise errors.NotFoundError('Specified build has not been found', url)
raise errors.NotFoundError('Specified build number has not been found ', url)

self.logger.info('Selected build: %s' % parser.entries[build_index])

Expand Down

0 comments on commit 09a2082

Please sign in to comment.