Closed likhithanimma1 closed 2 months ago
Attention: Patch coverage is 91.00000%
with 9 lines
in your changes are missing coverage. Please review.
Project coverage is 93.47%. Comparing base (
505e6c4
) to head (8fa0582
).
Files | Patch % | Lines |
---|---|---|
...es/zowe-explorer/src/command/UnixCommandHandler.ts | 90.72% | 9 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Failed conditions
13.2% Duplication on New Code (required ≤ 3%)
Apologies in advance for bringing up (again) the conversation about the sshSession
being optional.
For context, Trae (https://github.com/zowe/zowe-explorer-vscode/pull/2830#discussion_r1567767722) and I (https://github.com/zowe/zowe-explorer-vscode/pull/2830#pullrequestreview-1995169674) left a comment on the previous PR.
Since an extender can call the API directly, I'm curious as to why we made sshSession optional without providing a suitable replacement. Here are some examples:
There may be other ways to provide such functionality without requiring an SSH session 😋
Could someone help me understand this a bit better? 😋
Hey @zFernand0 if there are other ways to issue a unix command using the zosmf profile we can add that, but when this was first discussed as a new functionality using the ssh profile with zosmf was the path forward. Since some extenders don't require the ssh profile to issue unix commands, similar to TSO commands with check of TSO profile for account number, the passing of the session is an optional parameter. I don't believe there would be a replacement value sent for extenders that don't need it since they can grab this.session like other APIs for the service session information on demand.
Thanks for providing more details.
I see, I guess I never considered the possibility to call the ZoweExplorerZosmfApi.issueUnixCommand
without a session since it may fail with an ugly cannot read property of undefined
😋
Proposed changes
Making the sshSession parameter optional for issueUnixCommand Api so that profiles that doesn't require ssh can also have it.
Release Notes
Milestone:
Changelog:
Types of changes
What types of changes does your code introduce to Zowe Explorer? Put an
x
in the boxes that applyChecklist
Put an
x
in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This checklist will be used as reference for both the contributor and the revieweryarn workspace vscode-extension-for-zowe vscode:prepublish
has been executedFurther comments