Skip to content

Conversation

@t1m0thyj
Copy link
Member

@t1m0thyj t1m0thyj commented Dec 26, 2025

What It Does

  • Fixes method that issues TSO commands to be more reliable and consistent with Zowe Node SDKs
    • Fetch startup messages after starting TSO session to suppress them from command output
    • Pass readReply=false query param on API call for sending command to TSO session
  • Removes "notify" keyword from test JCL to prevent spamming test system with TSO notifications
  • Fixes apt-get install failing to install libsecret package in Linux CI builds

How to Test

Review Checklist
I certify that I have:

Additional Comments

@github-project-automation github-project-automation bot moved this to New Issues in Zowe CLI Squad Dec 26, 2025
@zowe-robot zowe-robot moved this from New Issues to In Progress in Zowe CLI Squad Dec 26, 2025
@codecov
Copy link

codecov bot commented Dec 26, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 81.88%. Comparing base (7d093e6) to head (52801dd).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #386      +/-   ##
==========================================
+ Coverage   81.86%   81.88%   +0.01%     
==========================================
  Files          48       48              
  Lines        2768     2771       +3     
==========================================
+ Hits         2266     2269       +3     
  Misses        502      502              
Flag Coverage Δ
unittests 81.88% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
@t1m0thyj t1m0thyj force-pushed the dev/fix-system-tests branch from a8e4324 to 6b1b9cc Compare December 26, 2025 19:31
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
@t1m0thyj t1m0thyj changed the title Don't use notify keyword in test JCL Fix flaky TSO test and remove notify keyword from test test JCL Dec 28, 2025
@t1m0thyj t1m0thyj changed the title Fix flaky TSO test and remove notify keyword from test test JCL Fix flaky TSO test and remove notify keyword from test JCL Dec 28, 2025
@t1m0thyj t1m0thyj force-pushed the dev/fix-system-tests branch from 329f01e to 151da20 Compare December 28, 2025 00:48
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
@t1m0thyj t1m0thyj force-pushed the dev/fix-system-tests branch from 151da20 to 52801dd Compare December 28, 2025 00:49
@t1m0thyj t1m0thyj requested review from Copilot and traeok December 28, 2025 00:52
@t1m0thyj t1m0thyj requested a review from zFernand0 December 28, 2025 00:53
@t1m0thyj t1m0thyj marked this pull request as ready for review December 28, 2025 00:53
@zowe-robot zowe-robot moved this from In Progress to Review/QA in Zowe CLI Squad Dec 28, 2025
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes a flaky TSO test by improving the reliability of TSO command execution to align with Zowe Node SDKs behavior, and removes the "notify" keyword from test JCL to prevent spamming the test system with TSO notifications.

Key Changes

  • Modified TSO command issuing to fetch and suppress startup messages before executing commands
  • Added read_reply parameter to the send() method to control whether to wait for TSO session replies
  • Removed NOTIFY=&SYSUID from test JCL fixtures to prevent unnecessary system notifications

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/zos_tso/zowe/zos_tso_for_zowe_sdk/tso.py Enhanced issue_command method to fetch startup messages and added read_reply parameter to send() method for better control over TSO session behavior
src/zos_tso/zowe/zos_tso_for_zowe_sdk/response/tso.py Made tsoData field optional in SendResponse to support responses without data when read_reply=False
tests/unit/test_zos_tso.py Updated unit test mocks to reflect new TSO command flow with additional API calls for fetching startup messages
tests/integration/fixtures/sample.jcl Removed NOTIFY=&SYSUID parameter from JCL job definition
tests/integration/fixtures/jobs.json Removed NOTIFY=&SYSUID parameter from JCL code array
CHANGELOG.md Documented the bug fix for TSO command output reliability issue
.github/workflows/sdk-release.yaml Added apt-get update before package installation for better reliability
.github/workflows/sdk-build.yml Added apt-get update before package installation for better reliability

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

list[dict[str, Any]]
A non-normalized list from TSO containing the result from the command
"""
return list(self.send(session_key, message).tsoData)
Copy link

Copilot AI Dec 28, 2025

Choose a reason for hiding this comment

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

This method calls self.send(session_key, message).tsoData and wraps it with list(). Since tsoData field in SendResponse is now Optional[list[dict[str, Any]]] (can be None), calling list(None) will raise a TypeError if the API returns a response without tsoData. Consider handling the None case, for example: return list(self.send(session_key, message).tsoData or []).

Suggested change
return list(self.send(session_key, message).tsoData)
return list(self.send(session_key, message).tsoData or [])

Copilot uses AI. Check for mistakes.
Comment on lines +182 to +183
read_reply: bool
Whether to read the reply from the TSO session
Copy link

Copilot AI Dec 28, 2025

Choose a reason for hiding this comment

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

The documentation for the read_reply parameter only states "Whether to read the reply from the TSO session" which is vague. Consider expanding this to explain what happens when set to False (e.g., "When False, the command is sent without waiting for a reply, and tsoData in the response will be None").

Copilot uses AI. Check for mistakes.
@t1m0thyj t1m0thyj requested a review from anaxceron December 28, 2025 04:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Review/QA

Development

Successfully merging this pull request may close these issues.

2 participants