Skip to content
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

Add option for hiding profile from all trees #2566

Merged
merged 11 commits into from
Nov 16, 2023

Conversation

rudyflores
Copy link
Contributor

@rudyflores rudyflores commented Nov 10, 2023

Proposed changes

Solves #2567

Add ability for the user to hide profiles in the tree in sync or individually based on their choice in the quickpick

Sample

Screen.Recording.2023-11-10.at.2.30.00.PM.mov

Release Notes

Milestone: 2.13.0

Changelog: Add support for hiding a Zowe profile across all trees

Types of changes

What types of changes does your code introduce to Zowe Explorer?
Put an x in the boxes that apply

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Updates to Documentation or Tests (if none of the other choices apply)

Checklist

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 reviewer

  • I have read the CONTRIBUTOR GUIDANCE wiki
  • PR title follows Conventional Commits Guidelines
  • PR Description is included
  • gif or screenshot is included if visual changes are made
  • yarn workspace vscode-extension-for-zowe vscode:prepublish has been executed
  • All checks have passed (DCO, Jenkins and Code Coverage)
  • I have added unit test and it is passing
  • I have added integration test and it is passing
  • There is coverage for the code that I have added
  • I have tested it manually and there are no regressions found
  • I have added necessary documentation (if appropriate)
  • Any PR dependencies have been merged and published (if appropriate)

Further comments

@rudyflores rudyflores self-assigned this Nov 10, 2023
@rudyflores rudyflores added this to the v2.13.0 milestone Nov 10, 2023
Copy link

codecov bot commented Nov 10, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (971e0e8) 92.75% compared to head (2735b0c) 92.80%.
Report is 3 commits behind head on main.

❗ Current head 2735b0c differs from pull request most recent head 04f3a48. Consider uploading reports for the commit 04f3a48 to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2566      +/-   ##
==========================================
+ Coverage   92.75%   92.80%   +0.04%     
==========================================
  Files         104      104              
  Lines       10315    10371      +56     
  Branches     2192     2201       +9     
==========================================
+ Hits         9568     9625      +57     
+ Misses        746      745       -1     
  Partials        1        1              

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

@rudyflores rudyflores linked an issue Nov 10, 2023 that may be closed by this pull request
Signed-off-by: Rudy Flores <[email protected]>
Signed-off-by: Rudy Flores <[email protected]>
Copy link
Member

@zFernand0 zFernand0 left a comment

Choose a reason for hiding this comment

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

The prompt and everything around the functionality LGTM! 😋

I did notice that some of the old options came back in the USS context menu.
image
This doesn't happen (for me) on 2.12.1.

Also, the Edit history is above the Manage profile on the Jobs (but this also happens on the main branch)

@rudyflores
Copy link
Contributor Author

The prompt and everything around the functionality LGTM! 😋

I did notice that some of the old options came back in the USS context menu. image This doesn't happen (for me) on 2.12.1.

Also, the Edit history is above the Manage profile on the Jobs (but this also happens on the main branch)

Hey Fernando! That issue should be resolved once this PR is merged #2559

As for the menu order issue you mentioned that is not relevant to this change, but could create an issue for that an I can address that separately :)

traeok
traeok previously approved these changes Nov 13, 2023
Copy link
Member

@traeok traeok left a comment

Choose a reason for hiding this comment

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

LGTM - left a comment about a type cast, but the current logic won't affect the behavior 😅
Thanks @rudyflores!

packages/zowe-explorer/src/uss/init.ts Outdated Show resolved Hide resolved
Copy link
Member

@zFernand0 zFernand0 left a comment

Choose a reason for hiding this comment

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

LGTM! 😋
I'll wait for the PR below before approving

traeok
traeok previously approved these changes Nov 13, 2023
Copy link
Member

@traeok traeok left a comment

Choose a reason for hiding this comment

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

Thanks again for removing the cast and fixing the errors from the type change 😁

Copy link
Contributor

@JillieBeanSim JillieBeanSim left a comment

Choose a reason for hiding this comment

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

Hey @rudyflores this is looking great! I do have one question.
If the profile name is only in a single tree, is there a way for us to know this and react appropriately? I tested this situation and had a profile name in a single tree and was still prompted to choose. I didn't get any errors or anything from choosing all trees, but wonder if we can tell beforehand, and if only in a single tree just remove it instead of the prompt that doesn't really make sense if only in one tree.

@rudyflores
Copy link
Contributor Author

Hey @rudyflores this is looking great! I do have one question. If the profile name is only in a single tree, is there a way for us to know this and react appropriately? I tested this situation and had a profile name in a single tree and was still prompted to choose. I didn't get any errors or anything from choosing all trees, but wonder if we can tell beforehand, and if only in a single tree just remove it instead of the prompt that doesn't really make sense if only in one tree.

Perhaps we can cycle through each tree and see if the session exists in atleast another tree, if only in the current tree we can just remove the current one?

Signed-off-by: Rudy Flores <[email protected]>
Signed-off-by: Rudy Flores <[email protected]>
Copy link
Member

@zFernand0 zFernand0 left a comment

Choose a reason for hiding this comment

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

I was testing right before the meeting,
I just forgot to approve 😢

LGTM! 😋

Copy link

sonarcloud bot commented Nov 16, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
2.9% 2.9% Duplication

@rudyflores rudyflores merged commit 205dcdd into main Nov 16, 2023
14 checks passed
@rudyflores rudyflores deleted the hide-profile-only-one-time branch November 16, 2023 16:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Closed
Development

Successfully merging this pull request may close these issues.

Add ability to hide Zowe profiles from all tree views in one action
4 participants