-
Notifications
You must be signed in to change notification settings - Fork 344
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
GetParent for StorageFile doesn't work if the app doesn't have access to the parent folder #327
Comments
It makes sense for me. What is the expected result for you? |
@maxkatz6 It should always return a StorageFolder even without access to the folder |
@ptorr-msft - should we fold all the file system asks into one? See also #8, #127 and #140 |
@Jaiganeshkumaran is your suggestion that instead of returning Can you explain the use-case for that? |
@stevewri I think #140 is better kept separate since it's more of a bug with existing behaviour, vs. a new feature request. #127 is about media transport controls; typo? :). #8 is the main thread but again I think it's best kept separate (if app has full access, this issue is moot; if the app doesn't have full access, this issue is still valid). |
Personally I don't think this proposal is a good idea, because it would be a breaking change. At the moment my app code assumes that if I can get the StorageFolder object then I have access to the items in the folder (apart from some cases where some child items may have especially restricted permissions), and I can create items in the folder as long as it's not read-only. @Jaiganeshkumaran - what is the use case? Are you looking for an easy way to get the parent path? |
@Jaiganeshkumaran @maxkatz6 @ptorr-msft the better solution would be to handle this similarly MacOS does: If the app already has access to parent folder then app @ptorr-msft @benstevens48 as for the use cases:
|
@soumyamahunt - of course I completely agree there needs to be a way to prompt access to the parent folder, or to ensure access to the parent folder to begin with via a more fine-grained permissions story (and I've commented on this before). My point was that StorageFile.GetParentAsync() should not return a StorageFolder object which has no permission to do anything, which is what the suggestion was. I think the API for prompting the user for access should be separate, because obviously there are situations in which you wouldn't want a prompt to appear or to be waiting for the results of a prompt. |
Agreed with @benstevens48 - the feature being asked for here is a separate feature ("Let me ask for permission to access other files in the folder without showing the picker"). Thanks for the scenarios @soumyamahunt. We refer to these as "related files" or "linked files" and are looking at options for these kinds of scenarios, either enabling them automatically (maybe somewhat akin to the |
No description provided.
The text was updated successfully, but these errors were encountered: