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

DatasetFSprovider fetchDataset() - fix behavior with non-existent datasets and members #3255

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

benjamin-t-santos
Copy link
Contributor

@benjamin-t-santos benjamin-t-santos commented Oct 17, 2024

Proposed changes

There are currently issues for extenders with fetching MVS resources on-demand using the v3 file system. I outline them in this issue: #3252.

The proposed changes are:

  • Fix how dataset/member names are parsed before fetching them from remote
  • Look at the items in the API response to ensure that the requested resource actually exists, rather than just checking if the API call is completed successfully
  • Use allMembers when fetching a member vs. dataSet for datasets

In the issue, Trae raised concerns about opened files in Zowe Explorer being impacted when the extension reloads or restarts - I do not see any issues with these new changes. The opened files are fetched and displayed if they are available on the host. If they were deleted via some other source, the editor will display a "The editor could not be opened because the file was not found" message, which seems appropriate.

Release Notes

Milestone: #3252

Changelog:

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (non-breaking change which adds or improves functionality)
  • Breaking change (a change that would cause existing functionality to not work as expected)
  • Documentation (Markdown, README updates)
  • Other (please specify above in "Proposed changes" section)

Checklist

General

  • I have read the CONTRIBUTOR GUIDANCE wiki
  • All PR dependencies have been merged and published (if applicable)
  • A GIF or screenshot is included in the PR for visual changes
  • The pre-publish command has been executed:
    • v2 and below: yarn workspace vscode-extension-for-zowe vscode:prepublish
    • v3: pnpm --filter vscode-extension-for-zowe vscode:prepublish

Code coverage

  • There is coverage for the code that I have added
  • I have added new test cases and they are passing
  • I have manually tested the changes

Deployment

  • I have added developer documentation (if applicable)
  • Documentation should be added to Zowe Docs
    • If you're an outside contributor, please post in the #zowe-doc Slack channel to coordinate documentation.
    • Otherwise, please check with the rest of the squad about any needed documentation before merging.
  • These changes may need ported to the appropriate branches (list here):

Further comments

Copy link

codecov bot commented Oct 17, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 93.05%. Comparing base (c4f772e) to head (203b0df).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3255      +/-   ##
==========================================
+ Coverage   93.02%   93.05%   +0.02%     
==========================================
  Files         113      113              
  Lines       11720    11731      +11     
  Branches     2598     2646      +48     
==========================================
+ Hits        10903    10916      +13     
+ Misses        815      813       -2     
  Partials        2        2              

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

@benjamin-t-santos
Copy link
Contributor Author

benjamin-t-santos commented Oct 17, 2024

I do recognize this is a core part of the code for the ZE data sets view. Take all the time needed for review

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.

These changes look good to me, I tested opening multiple data sets, both through the tree view and a virtual workspace - contents were still fetched as expected.

I noticed that the changelog entry was in the FTP extension - can you please move this to the zowe-explorer/CHANGELOG.md file?

I'll approve this as soon as that's resolved. Thanks for the fix!

Signed-off-by: Benjamin Santos <[email protected]>
@benjamin-t-santos
Copy link
Contributor Author

These changes look good to me, I tested opening multiple data sets, both through the tree view and a virtual workspace - contents were still fetched as expected.

I noticed that the changelog entry was in the FTP extension - can you please move this to the zowe-explorer/CHANGELOG.md file?

I'll approve this as soon as that's resolved. Thanks for the fix!

Oops 🤦‍♂️ I moved it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: In Progress
Development

Successfully merging this pull request may close these issues.

2 participants