Skip to content

Fix 1 test plan fail will cancel all peer test plans issue#21138

Merged
StormLiangMS merged 3 commits intosonic-net:masterfrom
xwjiang-ms:fix_1_test_plan_cancel_all
Oct 31, 2025
Merged

Fix 1 test plan fail will cancel all peer test plans issue#21138
StormLiangMS merged 3 commits intosonic-net:masterfrom
xwjiang-ms:fix_1_test_plan_cancel_all

Conversation

@xwjiang-ms
Copy link
Copy Markdown
Contributor

@xwjiang-ms xwjiang-ms commented Oct 29, 2025

Description of PR

Summary:
Fixes # (issue)

Type of change

  • Bug fix
  • Testbed and Framework(new/improvement)
  • New Test case
    • Skipped for non-supported platforms
  • Test case improvement

Back port request

  • 202205
  • 202305
  • 202311
  • 202405
  • 202411
  • 202505

Approach

What is the motivation for this PR?

When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by #12978 using set -o and failure counter, but set -o was changed back by #15618.

How did you do it?

Change set -e back to set -o to make failure counter work again.

How did you verify/test it?

Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Any platform specific information?

Supported testbed topology if it's a new test case?

Documentation

@xwjiang-ms xwjiang-ms requested a review from wangxin as a code owner October 29, 2025 23:58
@xwjiang-ms xwjiang-ms marked this pull request as draft October 29, 2025 23:58
@mssonicbld
Copy link
Copy Markdown
Collaborator

/azp run

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link
Copy Markdown
Collaborator

/azp run

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link
Copy Markdown
Collaborator

/azp run

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@xwjiang-ms xwjiang-ms marked this pull request as ready for review October 30, 2025 01:35
@xwjiang-ms xwjiang-ms changed the title Fix 1 test plan fail will cancel all issue Fix 1 test plan fail will cancel all peer test plans issue Oct 30, 2025
Copy link
Copy Markdown
Collaborator

@StormLiangMS StormLiangMS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@StormLiangMS StormLiangMS merged commit 3defdc9 into sonic-net:master Oct 31, 2025
19 checks passed
@xwjiang-ms xwjiang-ms deleted the fix_1_test_plan_cancel_all branch October 31, 2025 04:57
dcaugher pushed a commit to dcaugher/sonic-mgmt that referenced this pull request Nov 12, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image
dcaugher pushed a commit to dcaugher/sonic-mgmt that referenced this pull request Nov 12, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image
vikumarks pushed a commit to vikumarks/sonic-mgmt that referenced this pull request Dec 1, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: vikumarks <vikumar7ks@gmail.com>
albertovillarreal-keys pushed a commit to albertovillarreal-keys/sonic-mgmt that referenced this pull request Dec 2, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: Alberto Villarreal <alberto.villarreal@keysight.com>
opcoder0 pushed a commit to opcoder0/sonic-mgmt that referenced this pull request Dec 8, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: opcoder0 <110003254+opcoder0@users.noreply.github.com>
selldinesh pushed a commit to selldinesh/sonic-mgmt that referenced this pull request Dec 11, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: selldinesh <dinesh.sellappan@keysight.com>
echuawu pushed a commit to echuawu/sonic-mgmt that referenced this pull request Dec 12, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image
saravanan-nexthop pushed a commit to saravanan-nexthop/sonic-mgmt that referenced this pull request Dec 15, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: Saravanan <saravanan@nexthop.ai>
gshemesh2 pushed a commit to gshemesh2/sonic-mgmt that referenced this pull request Dec 16, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: Guy Shemesh <gshemesh@nvidia.com>
AharonMalkin pushed a commit to AharonMalkin/sonic-mgmt that referenced this pull request Dec 16, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: Aharon Malkin <amalkin@nvidia.com>
gshemesh2 pushed a commit to gshemesh2/sonic-mgmt that referenced this pull request Dec 21, 2025
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: Guy Shemesh <gshemesh@nvidia.com>
venu-nexthop pushed a commit to venu-nexthop/sonic-mgmt that referenced this pull request Jan 13, 2026
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image
yifan-nexthop pushed a commit to nexthop-ai/sonic-mgmt that referenced this pull request Jan 14, 2026
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: YiFan Wang <yifan@nexthop.ai>
gshemesh2 pushed a commit to gshemesh2/sonic-mgmt that referenced this pull request Jan 26, 2026
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: Guy Shemesh <gshemesh@nvidia.com>
lakshmi-nexthop pushed a commit to lakshmi-nexthop/sonic-mgmt that referenced this pull request Jan 28, 2026
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: Lakshmi Yarramaneni <lakshmi@nexthop.ai>
ytzur1 pushed a commit to ytzur1/sonic-mgmt that referenced this pull request Jan 29, 2026
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image
ytzur1 pushed a commit to ytzur1/sonic-mgmt that referenced this pull request Feb 2, 2026
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: Yael Tzur <ytzur@nvidia.com>
abhishek-nexthop pushed a commit to nexthop-ai/sonic-mgmt that referenced this pull request Feb 6, 2026
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image
rraghav-cisco pushed a commit to rraghav-cisco/sonic-mgmt that referenced this pull request Feb 13, 2026
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image

Signed-off-by: Raghavendran Ramanathan <rraghav@cisco.com>
venu-nexthop pushed a commit to venu-nexthop/sonic-mgmt that referenced this pull request Mar 27, 2026
…#21138)

What is the motivation for this PR?
When we use TEST_PLAN_NUM and .azure-pipelines/run-test-elastictest-template.yml to create a batch of test plans, if 1 test plan fails, the others will be cancelled because test_plan.py will raise exception then run sys.exit. Previously this issue was fixed by sonic-net#12978 using set -o and failure counter, but set -o was changed back by sonic-net#15618.

How did you do it?
Change set -e back to set -o to make failure counter work again.

How did you verify/test it?
Verified in pipeline https://dev.azure.com/mssonic/build/_build/results?buildId=971751&view=logs&j=9657d7a6-3fe9-53eb-d67f-701685efa9c8&t=316819a7-603a-55dc-2941-0b950b5989c2
image
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants