OneDrive / samples

Contains samples, scenarios, and guidance for integrating with OneDrive and SharePoint drives, drive items, and files.
MIT License
58 stars 59 forks source link

v8 FilePicker does not honour entry.oneDrive.files when accessing onedrive.live.com accounts #45

Closed jonathon-love closed 8 months ago

jonathon-love commented 1 year ago

video demonstrating the issue:

https://youtu.be/swX_ZH_kVpM

From the schema here: https://learn.microsoft.com/en-us/onedrive/developer/controls/file-pickers/v8-schema

      /**
       * Indicates that the File Picker should start in the user's OneDrive.
       */
      oneDrive?: {
         /**
         * Indicates that File Picker should start in the user's recent files.
         */
         recent?: {};
         /**
         * Specifies that File Picker should start in the user's Files tab.
         */
         files?: {
            /**
             * Path segment for sub-folder within the user's OneDrive.
             * @example
             *  'Pictures'
             * @example
             *  '/personal/user_contoso_com/Documents/Attachments'
             */
            folder?: string;
         }
      };

the example listed is 'Pictures' but if you try that with a onedrive.live.com account, that does not work. i cannot find any value that changes the entry point of the file picker when accessing live.onedrive.com accounts ... note that i can get some paths to work when accessing sharepoints (aka non-onedrive.live.com accounts).

with thanks

JCrew0 commented 10 months ago

@jonathon-love, I'm going through and looking at some of the older issues. Did anyone ever address this or did you come up with a solution? If not, I can try to take a look. Thanks!

jonathon-love commented 10 months ago

hi,

i'm pretty sure (99.9%) this is still a problem.

with thanks

JCrew0 commented 10 months ago

@jonathon-love

Ok, thanks! I can take a look!

Orangeapplebot commented 8 months ago

Hey, Im facing a similar issue. In my case, the post call just ends with a 404, "This item might not exist or is no longer available". No matter what entry point I use. I just want the user to enter their base onedrive. Even using recents, doesnt do the trick

JCrew0 commented 8 months ago

@jonathon-love @Orangeapplebot , I spoke with my team and the files configuration is not supported in OneDrive for Consumer. The documentation will likely need to be updated to appropriately reflect this. Sorry for any inconvenience this causes!

jonathon-love commented 8 months ago

thanks @JCrew0, i imagine you as the lone zoro, travelling the corrupt halls of microsoft, advocating for the little people "we provide this professional looking service, and then make people who integrate with it look bad!" ... carving Z's in cubicle walls, etc.

i work with some google projects too, and there's a lone google developer who plays a similar role, trying to get documentation updated that presents a particular product working in a particular way, when it really does not work (and collectively wastes thousands of developer hours).

maybe you guys could get together and draw strength.

you have my thanks.

Orangeapplebot commented 8 months ago

Hey @JCrew0 , I dont have a Onedrive for consumers, I have a normal Azure application. I perform auth code flow and get an access and refresh token. I'm trying to open the onedrive picker, so that the user can give me access to selected files and folders. If you want, I can give you more details on my auth flow and my onedrive params

JCrew0 commented 7 months ago

@Orangeapplebot, your application will either serve the consumer or business version of file picker based upon which one you specify in file picker configuration/url (requiring the appropriate associated auth flow). It sounds like you are having some different issues, perhaps create a new issue?