Hello there
I am using the Microsoft.SharePointOnline.CSOM to provisioning modern sites, pages and joining to hub.
But i seems to be getting errors that are intermittent, doesn't happen all the time but does happens after several successful provisioning.
There are two main error that i'm getting:
One of the error is: The object id "site:11468684-da02-48e5-a052-35e27a0232d9:web:457cf5a0-755f-4008-8d8b-64047b42d884" is invalid.
The guid are always different on each error and this seems to happen when my code is working with modern pages, so sometime i get it on this line:
searchPage.Save("SearchCentre.aspx"); or on this line ClientSidePage page = ClientSidePage.Load(context, "Home.aspx");
The second error occurs within my method for joining site to hub site: I get an error File Not Found. This seems to happen on tenantContext.ExecuteQueryRetry();
My full code for the hub site is this:
using (ClientContext tenantContext = new
ClientContext(ConfigurationManager.AppSettings["TenantAdminUrl"]))
{
tenantContext.Credentials = new SharePointOnlineCredentials(ConfigurationManager.AppSettings["SPUsername"], Program.GetSPOSecureStringPassword());
tenantContext.ExecuteQueryRetry();
var tenant = new Tenant(tenantContext);
tenant.ConnectSiteToHubSite(siteToJoin.ToString(), ConfigurationManager.AppSettings["RWProjectHubSiteUrl"].ToString());
tenantContext.ExecuteQueryRetry();
}
I don't know what could be the cause of these errors and as i said they work most of the time but fails consistently with the same error sometime. I need to deliver something that is stable
Any help is much appreciated.
+1, seeing same type of random errors
@jansenbe thanks for confirming these issues.
Do you know if this is something that will be fixed soon, if so any eta on this?
Is there any recommended temporary fix, I don't know if these are new issues so perhaps downgrading to an earlier version may be more stable? If so, what version number would you recommend?
Cheers
This seems to be backend related: the errors randomly popup and we've not made changes in the places where the errors are thrown. I'll need to some more testing and verify on other environments
I started to see this also using the Provisioning Framework with the Tenant Templates (#2025). I'm getting the exact same 2 errors you are getting... Curious to see what is happening here! Even added random delays to wait and seems to be non-related...
@jansenbe is there any update on this issue?
Thanks
+1. Seeing these same errors intermittently when applying a PnP template (most often when provisioning term groups).
Same here ! With PnPPowerShell
And random errors with Set-PnPTenantSite with the option NoScriptSite
I can confirm similar behaviour in the last few days. It really seems random and rerunning the same scripts a few moments later does not reproduce the issue. I'm looking for some insights on how to avoid this.
If this is indeed a backend issue, priority should be given to resolve this.
I do see these errors when I'm deleting a site collection and creating a new site collection with the same name immediately afterwards... @awdhaan : does my scenario also apply to you?
Applies to me. We also happen to be setting the NoScript flag each time the site collection is being reprovisioned.
I do see these errors when I'm deleting a site collection and creating a new site collection with the same name immediately afterwards... @awdhaan : does my scenario also apply to you?
I think so. I'm testing a migration script and afterwards I clean up the sites end-to-end in the tenant. Usually I recreate the test sites with the same name shortly afterwards. So if that is the case, than this won't be an issue for the final migration.
@LarterStyles what's context do you use? I had this error each time when I used the site context. I changed the context to the -admin one and I have less often the error
@jansenbe is there any update on this issue?
Thanks
Hi @jansenbe, do you know any known workaround for this?
In our own Provisioning engine we also depend on some sites which are generated automatically by a deployment script. Sometimes we remove those sites and recreate them to test the deployment scripts but in that case we have the same errors as described by @Mike-tech.
Thanks for your time!
We are provisioning large number of sites and the intermittent failure causes us a real headache. Any sign of a fix please?
Any updates on this?
+1 seeing the same issue.
also happens here
Most helpful comment
I do see these errors when I'm deleting a site collection and creating a new site collection with the same name immediately afterwards... @awdhaan : does my scenario also apply to you?