SOLVED

Very strange issue - Site pages showing up in a document library when viewed in OneDrive app?

Iron Contributor

Hi,

 

Ok, I've got a really odd one here.  I've just provisioned a brand new Office 365 tenant, I've created a couple of "modern" pages within the root SharePoint site and set one of these as the home page so the site has a modern feel.  Next I've deleted the original "Shared Documents" library and created a bunch of new libraries.  All good so far.

 

The last thing I've done is setup Windows 10 PCs (1803) with the latest OneDrive app installed and sync'd the libraries to the PCs.  

 

Now the strange bit, in one of the newly created libraries when viewed from the OneDrive app I can see the site pages I've created (showing as aspx pages).  I've checked the same document library through the browser and that library is empty (as it should be at the moment).  Checking the "Site Pages" library I can see the pages??

 

So from the OneDrive app I deleted the files from the document library, when I checked the site all the custom pages were gone.  So deleting them had actually deleted the files from the "Site Pages" library.  I had to restore them from the recycle bin and they were restored back to the "Site Pages" library and they appeared again in the OneDrive app.  What is going on?  

 

Just for fun I then stopped syncing the library in OneDrive and then deleted the library from the site.  I created a new library with a different name (just to be sure).  Sync'd it to OneDrive and the darn site pages are back!  The only thing I have done is the document library is displayed on one of the pages through the document library web part.  I've not tested if removing the web part changes this behaviour but I'll try that tomorrow.

 

Has anyone seen this sort of behaviour before, I've provisioned loads of O365 tenants but never seen an issue like this?

 

Any help gratefully received.


Rob

3 Replies
best response confirmed by Rob Clarke (Iron Contributor)
Solution

If I had to guess it's that pesky document library webpart as usual. I don't have the updated one so I can't prove my theroy, but you get a sync button now on it. And when you click Sync, your inside the context of the Site pages library "rendering the page" so it's probably picking up and syncing that library it's on based on the URL of the page your in "aka site pages" and not the contents of the library your linking too. They really shouldn't have the sync button on the library webpart cause I can see this causing issues.

 

That said, if you click into the library itself by clicking 'see all', or go to site contents then to the library and use the sync button there you won't have the issue because your browser URL will be to the correct library at time of clicking. Definitely seems like a bug to me for the webpart that needs fixed.

 

Hey @Stephen Rice probably SharePoint team issue but it touches the sync engine so you might have inside track of testing / reporting. Seems like one of those pesky modern context issues that needs ironed out! 

Definitely odd but I'll pass this along to the right folks so they see it. Thanks for flagging!

 

Stephen Rice

OneDrive Program Manager II

Thanks @Deleted that was the exact issue.  Setting up the OneDrive sync from the library rather than through the web part and everything worked as expected.

1 best response

Accepted Solutions
best response confirmed by Rob Clarke (Iron Contributor)
Solution

If I had to guess it's that pesky document library webpart as usual. I don't have the updated one so I can't prove my theroy, but you get a sync button now on it. And when you click Sync, your inside the context of the Site pages library "rendering the page" so it's probably picking up and syncing that library it's on based on the URL of the page your in "aka site pages" and not the contents of the library your linking too. They really shouldn't have the sync button on the library webpart cause I can see this causing issues.

 

That said, if you click into the library itself by clicking 'see all', or go to site contents then to the library and use the sync button there you won't have the issue because your browser URL will be to the correct library at time of clicking. Definitely seems like a bug to me for the webpart that needs fixed.

 

Hey @Stephen Rice probably SharePoint team issue but it touches the sync engine so you might have inside track of testing / reporting. Seems like one of those pesky modern context issues that needs ironed out! 

View solution in original post