PATCH prefix is not appropriately identified as such if it is not sepparated from following word in an email Subject line. This leads to wrong email parsing and revisions not appended to initial series.
This change allows appropriate email parsing by checking if PATCH prefix in Subject line is not sepparated from following word and adding a space between them. [YOCTO #10823] Signed-off-by: Jose Lamego <jose.a.lam...@linux.intel.com> --- patchwork/bin/parsemail.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/patchwork/bin/parsemail.py b/patchwork/bin/parsemail.py index c9eb05c..6e13beb 100755 --- a/patchwork/bin/parsemail.py +++ b/patchwork/bin/parsemail.py @@ -578,11 +578,18 @@ def find_patch_for_comment(project, refs): split_re = re.compile(r'[,\s]+') +patch_pref = re.re.compile(r'^.*\[(\s*PATCH\w+).*', re.I) def split_prefixes(prefix): """ Turn a prefix string into a list of prefix tokens """ + # Check if PATCH prefix is followed by anoter word without a sepparation + # space. Add missing space to allow appropriate parsing + if patch_pref.match(prefix): + index = prefix.find(patch_pref.match(prefix).group(1)) + prefix = prefix[:index + 5] + ' ' + prefix[index + 5:] + matches = split_re.split(prefix) return [s for s in matches if s != ''] -- 1.9.1 -- _______________________________________________ yocto mailing list yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/yocto