Here in this SharePoint blog post we will discuss how we can resolve the below issue.
Errors were found when compiling the workflow. The workflow files were saved but cannot be run. The error I got while publishing a workflow to SharePoint online list using SharePoint 2013 designer.
When I check the details about the error, the full error message was:
System.Net.WebException: The underlying connection was closed: A connection that was expected to be kept alive was closed by the server. —> System.IO.IOException: Unable to read data from the transport connection: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond. —> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did
It looks like below:
Recently we were developing a email notification workflow using sharepoint 2013 designer for sharepoint online list. But while publishing the workflow, we got the above error. When we check the details of the error we got to know since there is a connection problem, it was giving the error.
To resolve the issue, we restart the designer workflow and open the site once again. Now when we try to publish the workflow to sharepoint online site, it published successfully.
Hope this will help to resolve Errors were found when compiling the workflow sharepoint 2013. The workflow files were saved but cannot be run issue.