diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2020-10-29 15:21:35 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2020-10-30 13:04:39 +0000 |
commit | 98df63020d963d6ff606db77aae7542a4e5f5291 (patch) | |
tree | 6ae5a03f5850a0b77cbd57cee0a93b6eb4e45f8d /meta | |
parent | 6fd014b7c42f7b6b1ed50940409d9dd730547bec (diff) | |
download | poky-98df63020d963d6ff606db77aae7542a4e5f5291.tar.gz |
scripts/buildhistory_analysis: Avoid tracebacks from file comparision code
We're seeing tracebacks from buildhistory analysing the python 3.8 -> 3.9
upgrade due to the significant file renames. Avoid these by checking before
removal as they can happen multiple times.
(From OE-Core rev: b1eb390bbcb995c0da70478e17f9170721c75341)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/lib/oe/buildhistory_analysis.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/meta/lib/oe/buildhistory_analysis.py b/meta/lib/oe/buildhistory_analysis.py index 2d6fa1779e..b1856846b6 100644 --- a/meta/lib/oe/buildhistory_analysis.py +++ b/meta/lib/oe/buildhistory_analysis.py | |||
@@ -373,8 +373,10 @@ def compare_file_lists(alines, blines, compare_ownership=True): | |||
373 | removals.remove(removal2) | 373 | removals.remove(removal2) |
374 | continue | 374 | continue |
375 | filechanges.append(FileChange(removal, FileChange.changetype_move, addition)) | 375 | filechanges.append(FileChange(removal, FileChange.changetype_move, addition)) |
376 | additions.remove(addition) | 376 | if addition in additions: |
377 | removals.remove(removal) | 377 | additions.remove(addition) |
378 | if removal in removals: | ||
379 | removals.remove(removal) | ||
378 | for rename in renames: | 380 | for rename in renames: |
379 | filechanges.append(FileChange(renames[rename], FileChange.changetype_move, rename)) | 381 | filechanges.append(FileChange(renames[rename], FileChange.changetype_move, rename)) |
380 | 382 | ||