[Test] Fix parsing bug with scontrol output for dumping JOB output and command timeouts#7373
Open
himani2411 wants to merge 2 commits into
Open
[Test] Fix parsing bug with scontrol output for dumping JOB output and command timeouts#7373himani2411 wants to merge 2 commits into
himani2411 wants to merge 2 commits into
Conversation
added 2 commits
May 4, 2026 16:08
* Use shelex quote for all filepath to prevent unexpected behaviour from special characters from scontrol * Check for `/` (absolute path), and contains only printable characters. This catches empty strings, non-printable characters (null bytes, carriage returns), and relative/garbage paths.
* OS-level timeout command sends SIGTERM after 60 seconds, regardless of PTY/login shell/Fabric behavior * Fabric's SSH timeout set to 70 seconds as a backup, giving the OS timeout 10 seconds to kill the process before the SSH layer intervenes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of changes
Adding checks for filepath before we output or read the file so that we avoid hanging of the command when we have non-printable characters.
/(absolute path), and contains only printable characters. This catches empty strings, non-printable characters (null bytes, carriage returns), and relative/garbage paths.Adding OS level timeout so that we can escape the test if PTY or Bash shell doesnt timeout or close the session cleanly.
Tests
References
Checklist
developadd the branch name as prefix in the PR title (e.g.[release-3.6]).Please review the guidelines for contributing and Pull Request Instructions.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.