-
Notifications
You must be signed in to change notification settings - Fork 108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
v0.72.0: Fix handling of labeled hosts by pbench-postprocess-tools #3456
Conversation
Fixes distributed-system-analysis#3454 pbench-postprocess-tools mishandles hosts with labels (added by tool registration commands): it ignores the label and complains that it cannot find the tool output directory. The tool output directory path contains '<label>:<host>' as one element in the path but pbench-postprocess-tools looks for a '<host>' element. pbench-postprocess-tools parses the output of pbench-list-tools to get the tool info it needs, but pbench-list-tools omits the label from its output. This commit fixes pbench-list-tools to add the label to its output and pbench-postprocess-tools to parse that output, derive the label and use it to construct the path of the tool output directory. The next commit deals with tests. PBENCH-1178
This commit adds a "functional" test for pbench-list-tools to verify the output when labeled hosts have registered tools. It also fixes an incorrect legacy test (test-07) for pbench-postprocess-tools: the test was using a labeled host, but it was testing the wrong tool output directory (without the label). It adds a similar legacy test (test-07.1) to test the unlabeled host case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, I think this makes sense... although trying to follow legacy tests (especially the agent, which is even weirder than the server was) makes my head hurt ...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK; the apparent React fix (which I won't mention here as I don't really want the "mention" to show up in the React PR) has an approval but hasn't been submitted. Still, we might be able to retract the workaround soon ... but leaving it on the b0.72 branch is probably fine anyway.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, but I have a bunch of suggestions, particularly the two requests for better comments.
...s/samples/pbench-postprocess-tools/test-07.1/pbench/tools-v1-foobar/testhost.example.com/foo
Outdated
Show resolved
Hide resolved
lib/pbench/test/functional/agent/cli/commands/tools/test_tools_list.py
Outdated
Show resolved
Hide resolved
lib/pbench/test/functional/agent/cli/commands/tools/test_tools_list.py
Outdated
Show resolved
Hide resolved
lib/pbench/test/functional/agent/cli/commands/tools/test_tools_list.py
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I fell into a GitHub pitfall and my review ended up being submitted before I was ready.
Approved!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks OK; although, as I pointed out, we might not need the React workaround anymore...
Fix comment in pbench-postprocess-tools. Rework ugly code in list.py.
I think this is the last one.
I dropped the React commit (that's the only change). We'll see what Jenkins thinks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
…rt of distributed-system-analysis#3456) Fixes distributed-system-analysis#3454 pbench-postprocess-tools mishandles hosts with labels (added by tool registration commands): it ignores the label and complains that it cannot find the tool output directory. The tool output directory path contains '<label>:<host>' as one element in the path but pbench-postprocess-tools looks for a '<host>' element. pbench-postprocess-tools parses the output of pbench-list-tools to get the tool info it needs, but pbench-list-tools omits the label from its output. This PR fixes pbench-list-tools to add the label to its output and pbench-postprocess-tools to parse that output, derive the label and use it to construct the path of the tool output directory. It also adds a "functional" test for pbench-list-tools to verify the output when labeled hosts have registered tools and fixes an incorrect legacy test (test-07) for pbench-postprocess-tools: the test was using a labeled host, but it was testing the wrong tool output directory (without the label). It adds a similar legacy test (test-07.1) to test the unlabeled host case. Bump the version to 0.72.1 PBENCH-1178
…rt of distributed-system-analysis#3456) Fixes distributed-system-analysis#3454 pbench-postprocess-tools mishandles hosts with labels (added by tool registration commands): it ignores the label and complains that it cannot find the tool output directory. The tool output directory path contains '<label>:<host>' as one element in the path but pbench-postprocess-tools looks for a '<host>' element. pbench-postprocess-tools parses the output of pbench-list-tools to get the tool info it needs, but pbench-list-tools omits the label from its output. This PR fixes pbench-list-tools to add the label to its output and pbench-postprocess-tools to parse that output, derive the label and use it to construct the path of the tool output directory. It also adds a "functional" test for pbench-list-tools to verify the output when labeled hosts have registered tools and fixes an incorrect legacy test (test-07) for pbench-postprocess-tools: the test was using a labeled host, but it was testing the wrong tool output directory (without the label). It adds a similar legacy test (test-07.1) to test the unlabeled host case. Bump the version to 0.72.1 PBENCH-1178
…#3456) (#3472) * Fix handling of labeled hosts by pbench-postprocess-tools (forward port of #3456) Fixes #3454 pbench-postprocess-tools mishandles hosts with labels (added by tool registration commands): it ignores the label and complains that it cannot find the tool output directory. The tool output directory path contains '<label>:<host>' as one element in the path but pbench-postprocess-tools looks for a '<host>' element. pbench-postprocess-tools parses the output of pbench-list-tools to get the tool info it needs, but pbench-list-tools omits the label from its output. This PR fixes pbench-list-tools to add the label to its output and pbench-postprocess-tools to parse that output, derive the label and use it to construct the path of the tool output directory. It also adds a "functional" test for pbench-list-tools to verify the output when labeled hosts have registered tools and fixes an incorrect legacy test (test-07) for pbench-postprocess-tools: the test was using a labeled host, but it was testing the wrong tool output directory (without the label). It adds a similar legacy test (test-07.1) to test the unlabeled host case. Bump the version to 1.0 PBENCH-1178
Fixes #3454
pbench-postprocess-tools
mishandles hosts with labels (added by tool registration commands): it ignores the label and complains that it cannot find the tool output directory. The tool output directory path contains<label>:<host>
as one element in the path butpbench-postprocess-tools
looks for a<host>
element.pbench-postprocess-tools
parses the output ofpbench-list-tools
to get the tool info it needs, butpbench-list-tools
omits the label from its output.The first commit fixes
pbench-list-tools
to add the label to its output andpbench-postprocess-tools
to parse that output, derive the label and use it to construct the path of the tool output directory.The second commit deals with tests.
PBENCH-1178