Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@psanal35
Copy link
Contributor

@psanal35 psanal35 commented Sep 12, 2025

Add --continue_on_fail flag, similar to run_single_gpu.py. It will be used in nightly runs.

@psanal35
Copy link
Contributor Author

I tested both cases locally,

Copy link
Contributor

@gulsumgudukbay gulsumgudukbay left a comment

Choose a reason for hiding this comment

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

Additionally, the pytest command should be modified to reflect the continue_on_fail logic.

if continue_on_fail is not set, -x should be used in the pytest command
@psanal35
Copy link
Contributor Author

Additionally, the pytest command should be modified to reflect the continue_on_fail logic.

Thank you for catching this, I did not realized pytest has its own flag. In this case, we can remove break in the loop?

@gulsumgudukbay
Copy link
Contributor

Additionally, the pytest command should be modified to reflect the continue_on_fail logic.

Thank you for catching this, I did not realized pytest has its own flag. In this case, we can remove break in the loop?

Depends. So the loop traverses the test files. pytest's -x flag stops the test file execution if any unit test within a file fails. However the loop traverses the files and it stops **traversing the files ** after any test within a file fails.
So the -x argument is for within the file, however your break statement is for the whole loop that traverses the files.

Depending on the use case, if you want the loop to halt, you can keep the break statement. If you do not want the loop to halt but you want the test file execution to halt, you can remove the break statement.

@psanal35
Copy link
Contributor Author

Additionally, the pytest command should be modified to reflect the continue_on_fail logic.

Thank you for catching this, I did not realized pytest has its own flag. In this case, we can remove break in the loop?

Depends. So the loop traverses the test files. pytest's -x flag stops the test file execution if any unit test within a file fails. However the loop traverses the files and it stops **traversing the files ** after any test within a file fails. So the -x argument is for within the file, however your break statement is for the whole loop that traverses the files.

Depending on the use case, if you want the loop to halt, you can keep the break statement. If you do not want the loop to halt but you want the test file execution to halt, you can remove the break statement.

I tested this and break seems redundant as it stands, but I am leaving it -- in any case it is correct to keep it~

Copy link
Contributor

@gulsumgudukbay gulsumgudukbay left a comment

Choose a reason for hiding this comment

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

I approve, but we will need another person to review as well since I pushed changes to this PR.

Copy link
Contributor

@zahiqbal zahiqbal left a comment

Choose a reason for hiding this comment

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

Looks good,

@psanal35 psanal35 merged commit 4efb2a0 into master Sep 12, 2025
7 checks passed
@psanal35 psanal35 deleted the mgpu-continue branch September 12, 2025 20:51
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