]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commitdiff
resulttool/regression.py: fix AttributeError
authorChangqing Li <changqing.li@windriver.com>
Fri, 11 Oct 2024 02:19:10 +0000 (10:19 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 11 Oct 2024 12:33:13 +0000 (13:33 +0100)
Fix following AttributeError when running "resulttool regression base target":
  File "/yocto/poky/scripts/lib/resulttool/regression.py", line 322, in regression_common
    res, resstr = compare_result(logger, c, b, base_results[a][c], target_results[a][b], args.limit)
AttributeError: 'Namespace' object has no attribute 'limit'

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
scripts/lib/resulttool/regression.py

index 10e7d13841a72dc93365507e27e172be334fc289..204e6eecb7a8949cd798902464f5294eaab63192 100644 (file)
@@ -422,6 +422,7 @@ def register_commands(subparsers):
                               help='(optional) filter the base results to this result ID')
     parser_build.add_argument('-t', '--target-result-id', default='',
                               help='(optional) filter the target results to this result ID')
+    parser_build.add_argument('-l', '--limit', default=REGRESSIONS_DISPLAY_LIMIT, help="Maximum number of changes to display per test. Can be set to 0 to print all changes")
 
     parser_build = subparsers.add_parser('regression-git', help='regression git analysis',
                                          description='regression analysis comparing base result set to target '