diff --git a/zulip/integrations/twitter/twitter-bot b/zulip/integrations/twitter/twitter-bot index 94fbd0ea..ef42ac55 100755 --- a/zulip/integrations/twitter/twitter-bot +++ b/zulip/integrations/twitter/twitter-bot @@ -215,11 +215,10 @@ for status in statuses[::-1][: opts.limit_tweets]: if opts.search_terms: search_term_used = None - for term in opts.search_terms.split(","): + for raw_term in opts.search_terms.split(","): # Remove quotes from phrase: # "Zulip API" -> Zulip API - if term.startswith('"') and term.endswith('"'): - term = term[1:-1] + term = raw_term[1:-1] if term.startswith('"') and term.endswith('"') else raw_term if any(term.lower() in text for text in text_to_check): search_term_used = term break diff --git a/zulip/integrations/zephyr/zephyr_mirror_backend.py b/zulip/integrations/zephyr/zephyr_mirror_backend.py index 62f6bde8..a4ab9773 100755 --- a/zulip/integrations/zephyr/zephyr_mirror_backend.py +++ b/zulip/integrations/zephyr/zephyr_mirror_backend.py @@ -98,8 +98,8 @@ def unwrap_lines(body: str) -> str: lines = body.split("\n") result = "" previous_line = lines[0] - for line in lines[1:]: - line = line.rstrip() + for raw_line in lines[1:]: + line = raw_line.rstrip() if re.match(r"^\W", line, flags=re.UNICODE) and re.match( r"^\W", previous_line, flags=re.UNICODE ): @@ -1096,8 +1096,8 @@ def parse_zephyr_subs(verbose: bool = False) -> Set[Tuple[str, str, str]]: logger.error("Couldn't find ~/.zephyr.subs!") return zephyr_subscriptions - for line in open(subs_file).readlines(): - line = line.strip() + for raw_line in open(subs_file).readlines(): + line = raw_line.strip() if len(line) == 0: continue try: