def __init__(self):
"""Class constructor."""
self._fields_to_check = ['description', 'name', 'summary', 'reviews']
self._minimum_monthly_discount = int(settings.get('MINIMUM_MONTHLY_DISCOUNT', None))
self._minimum_weekly_discount = int(settings.get('MINIMUM_WEEKLY_DISCOUNT', None))
self._skip_list = settings.get('SKIP_LIST', None)
self._cannot_have_regex = settings.get('CANNOT_HAVE', None)
if self._cannot_have_regex:
self._cannot_have_regex = re.compile(str(self._cannot_have_regex), re.IGNORECASE)
self._must_have_regex = settings.get('MUST_HAVE', None)
if self._must_have_regex:
self._must_have_regex = re.compile(str(self._must_have_regex), re.IGNORECASE)
self._web_browser = settings.get('WEB_BROWSER', None)
if self._web_browser:
self._web_browser += ' %s' # append URL placeholder (%s)
评论列表
文章目录