Skip to content

Commit

Permalink
fix indent
Browse files Browse the repository at this point in the history
  • Loading branch information
dzid26 committed Oct 2, 2024
1 parent 57d1358 commit 27e7d96
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
12 changes: 6 additions & 6 deletions board/jungle/scripts/can_health.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
GREEN = '\033[92m'

def colorize_errors(value):
if isinstance(value, str):
if re.search(r'(?i)No error', value):
return f'{GREEN}{value}\033[0m'
elif re.search(r'(?i)(?<!No error\s)(err|error)', value):
return f'{RED}{value}\033[0m'
return str(value)
if isinstance(value, str):
if re.search(r'(?i)No error', value):
return f'{GREEN}{value}\033[0m'
elif re.search(r'(?i)(?<!No error\s)(err|error)', value):
return f'{RED}{value}\033[0m'
return str(value)

if __name__ == "__main__":
jungle = PandaJungle()
Expand Down
12 changes: 6 additions & 6 deletions tests/can_health.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
GREEN = '\033[92m'

def colorize_errors(value):
if isinstance(value, str):
if re.search(r'(?i)No error', value):
return f'{GREEN}{value}\033[0m'
elif re.search(r'(?i)(?<!No error\s)(err|error)', value):
return f'{RED}{value}\033[0m'
return str(value)
if isinstance(value, str):
if re.search(r'(?i)No error', value):
return f'{GREEN}{value}\033[0m'
elif re.search(r'(?i)(?<!No error\s)(err|error)', value):
return f'{RED}{value}\033[0m'
return str(value)

if __name__ == "__main__":

Expand Down

0 comments on commit 27e7d96

Please sign in to comment.