patman: Fix indenting in patchstream

Update the indenting to keep pylint3 happy.

Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
Simon Glass 2020-10-29 21:46:17 -06:00
parent f9e428489b
commit d06e55a7c6

View file

@ -2,6 +2,8 @@
# Copyright (c) 2011 The Chromium OS Authors.
#
"""Handles parsing a stream of commits/emails from 'git log' or other source"""
import datetime
import math
import os
@ -15,8 +17,8 @@ from patman import gitutil
from patman.series import Series
# Tags that we detect and remove
re_remove = re.compile('^BUG=|^TEST=|^BRANCH=|^Review URL:'
'|Reviewed-on:|Commit-\w*:')
re_remove = re.compile(r'^BUG=|^TEST=|^BRANCH=|^Review URL:'
r'|Reviewed-on:|Commit-\w*:')
# Lines which are allowed after a TEST= line
re_allowed_after_test = re.compile('^Signed-off-by:')
@ -46,7 +48,7 @@ re_commit = re.compile('^commit ([0-9a-f]*)$')
re_space_before_tab = re.compile('^[+].* \t')
# Match indented lines for changes
re_leading_whitespace = re.compile('^\s')
re_leading_whitespace = re.compile(r'^\s')
# States we can be in - can we use range() and still have comments?
STATE_MSG_HEADER = 0 # Still in the message header
@ -336,8 +338,9 @@ class PatchStream:
value = change_id_match.group(1)
if self.is_log:
if self.commit.change_id:
raise ValueError("%s: Two Change-Ids: '%s' vs. '%s'" %
(self.commit.hash, self.commit.change_id, value))
raise ValueError(
"%s: Two Change-Ids: '%s' vs. '%s'" % self.commit.hash,
self.commit.change_id, value)
self.commit.change_id = value
self.skip_blank = True