-
Notifications
You must be signed in to change notification settings - Fork 92
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
Fix credentials not refreshed in ds tree and misc profile related fixes #3111
Conversation
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3111 +/- ##
==========================================
+ Coverage 92.76% 92.80% +0.03%
==========================================
Files 113 113
Lines 11658 11669 +11
Branches 2453 2594 +141
==========================================
+ Hits 10815 10829 +14
+ Misses 841 838 -3
Partials 2 2 ☔ View full report in Codecov by Sentry. |
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
3abf5ae
to
151f66d
Compare
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
845da1d
to
02b1fd4
Compare
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.
Thanks for working on these bugs @t1m0thyj
I did experience some strange behavior after updating credentials from failing one to working one and successfully did search and expand members but got the below error in text editor when trying to open file
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
@JillieBeanSim Thanks for catching this, I think I've fixed the issue but need to update some tests 😋 |
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
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.
LGTM! 😋
Left a couple of comments but nothing that requires changes on this PR 😋
Nice to see the error icon for global profiles now, thank you!
A few quirks:
- With
autoStore: false
and only the login regular profile- ✅ triggering the equivalent of updateCreds works fine with nested profiles
- ❓ triggering the equivalent of updateCreds with flat profiles throws an error, but works fine
- ✅ login with base profile works fine
- ✅ logout works fine for regular and base
- ❓ login with regular/nested profiles
- I noticed that the same profile in other trees does prompt for credentials to login, however, it works fine if I escape that first prompt and go to the actual search. That means that the credentials are propagated, but perhaps the checkCurrentProfile (or similar method) is not aware of the new credentials.
- With
autoStore: true
:
...-explorer/__tests__/__integration__/bdd/step_definitions/profiles/UpdateCredentials.steps.ts
Show resolved
Hide resolved
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
@zFernand0 Thanks for the detailed testing and feedback, I believe issues should be fixed now 😋 |
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Quality Gate failedFailed conditions |
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.
issues with autoStore: true
have been resolved.
However, I feel autoStore: false
isn't ideal yet 😋
- Credentials are not propagated between trees (which I believe is expected)
- Login is propagated (even though you have to escape the login prompt), but logout is not.
- Logout happens to remove the credential propagation, i.e. I can't navigate inside folders, but it lets you navigate (perhaps from cached contents) to the same directory from before (even though the token should be expired)
I know autoStore: false
is not the most common configuration, and the things I mentioned here are small enough that people should not even encounter unless they are purposely trying to get into a weird state. 😋
TL;DR: LGTM! 😋
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.
I'm still running into a 401 error when opening PDS members - here's the scenario I tested:
- Enter a search pattern for one of your profiles with pre-existing, valid credentials in place
- With the session expanded and data sets listed, right-click on profile node and select Manage Profile -> Update Credentials
- Enter in invalid credentials for the profile
- When the "invalid credentials" prompt occurs for the profile, cancel out of the prompt
a. Notice that the children elements for the profile node are removed - Right click on profile node -> Manage Profile -> Update Credentials
- Enter in valid credentials this time
- Click on profile node to toggle its collapsible state to expanded
- Open one of the PDS in the list
- Click on one of its members
I realized this was merged in the middle of my review, but figured I should post it anyway as it will likely need addressed in a future PR. The scenario is a bit niche, but could be reproduced if a user doesn't update their invalid creds right away.
@t1m0thyj can a bug report be created for the edge case please? TIA |
Proposed changes
This PR resolves several issues related to profile management in V3:
How to Test
Test that profile changes are propagated:
Release Notes
Milestone: 3.0.0
Changelog: TBD
Types of changes
Checklist
General
yarn workspace vscode-extension-for-zowe vscode:prepublish
pnpm --filter vscode-extension-for-zowe vscode:prepublish
Code coverage
Deployment
Further comments