diff options
| author | Ed Bartosh <ed.bartosh@linux.intel.com> | 2016-07-08 17:35:20 +0300 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-07-21 07:47:52 +0100 |
| commit | 788d6fb30d1527ba021acea39a96261ba700945d (patch) | |
| tree | 089dbcc94737648e232fabaafde6ce6362c03a45 | |
| parent | d4d60218ec1f8c26ffe966cf6f04cf341934f553 (diff) | |
| download | poky-788d6fb30d1527ba021acea39a96261ba700945d.tar.gz | |
buildhistory-diff: reduce PKGR noise
When using PR service the buildhistory-diff output contains a lot of
PKGR changes: In practice the mass of PKGR updates hide other important
changes as they often account for 80% of all changes.
Skipped incremental and decremental changes of PKGR versions to reduce
amount of the script output. All changes are still included in the
output if script is run with -a/--report-all command line option.
[YOCTO #9755]
(From OE-Core rev: a343788b11f6c4f92ae8d2035fe8cb54f922227e)
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/lib/oe/buildhistory_analysis.py | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/meta/lib/oe/buildhistory_analysis.py b/meta/lib/oe/buildhistory_analysis.py index 4353381080..b6c0265c15 100644 --- a/meta/lib/oe/buildhistory_analysis.py +++ b/meta/lib/oe/buildhistory_analysis.py | |||
| @@ -359,6 +359,24 @@ def compare_dict_blobs(path, ablob, bblob, report_all, report_ver): | |||
| 359 | if ' '.join(alist) == ' '.join(blist): | 359 | if ' '.join(alist) == ' '.join(blist): |
| 360 | continue | 360 | continue |
| 361 | 361 | ||
| 362 | if key == 'PKGR' and not report_all: | ||
| 363 | vers = [] | ||
| 364 | # strip leading 'r' and dots | ||
| 365 | for ver in (astr.split()[0], bstr.split()[0]): | ||
| 366 | if ver.startswith('r'): | ||
| 367 | ver = ver[1:] | ||
| 368 | vers.append(ver.replace('.', '')) | ||
| 369 | maxlen = max(len(vers[0]), len(vers[1])) | ||
| 370 | try: | ||
| 371 | # pad with '0' and convert to int | ||
| 372 | vers = [int(ver.ljust(maxlen, '0')) for ver in vers] | ||
| 373 | except ValueError: | ||
| 374 | pass | ||
| 375 | else: | ||
| 376 | # skip decrements and increments | ||
| 377 | if abs(vers[0] - vers[1]) == 1: | ||
| 378 | continue | ||
| 379 | |||
| 362 | chg = ChangeRecord(path, key, astr, bstr, monitored) | 380 | chg = ChangeRecord(path, key, astr, bstr, monitored) |
| 363 | changes.append(chg) | 381 | changes.append(chg) |
| 364 | return changes | 382 | return changes |
