diff --git a/src/Active/YahooFinance.py b/src/Active/YahooFinance.py index f654d5c..be5ce4b 100644 --- a/src/Active/YahooFinance.py +++ b/src/Active/YahooFinance.py @@ -15,7 +15,7 @@ def _construct_url(cls, ticker_symbol): def _isPercentage(cls, text): if not isinstance(text, str): return False - match = re.match('(\d+(\.\d+)?%)', text) + match = re.match(r'(\d+(\.\d+)?%)', text) return match != None @classmethod @@ -41,4 +41,4 @@ def parse_analyst_five_year_growth_rate(self, content): if text == 'Next 5 Years (per annum)': percentage = YahooFinanceAnalysis._parseNextPercentage(tree_iterator) self.five_year_growth_rate = percentage.rstrip("%") if percentage else None - return True if self.five_year_growth_rate else False \ No newline at end of file + return True if self.five_year_growth_rate else False