1

New issue and I don't understand it!

2 weeks ago it was working fine but today, I don't know why, my workflow is automatically cancelled.

Here's the message error:

RequestorId: 8ed78b10-b381-498f-7ee4-3e446c9596ad. Details: System.ApplicationException: HTTP 401 {"Transfer-Encoding":["chunked"],"X-SharePointHealthScore":["0"],"SPClientServiceRequestDuration":["1184"],"SPRequestGuid":["8ed78b10-b381-498f-7ee4-3e446c9596ad"],"request-id":["8ed78b10-b381-498f-7ee4-3e446c9596ad"],"X-FRAME-OPTIONS":["SAMEORIGIN"],"MicrosoftSharePointTeamServices":["15.0.0.4420"],"X-Content-Type-Options":["nosniff"],"X-MS-InvokeApp":["1; RequireReadOnly"],"Cache-Control":["max-age=0, private"],"Date":["Wed, 20 Nov 2013 09:22:26 GMT"],"Set-Cookie":["WSS_KeepSessionAuthenticated={4fe36e36-0dc1-41ee-a957-74e10d821ea7}; path=/; secure"],"Server":["Microsoft-IIS/8.0"],"WWW-Authenticate":["NTLM"],"X-AspNet-Version":["4.0.30319"],"X-Powered-By":["ASP.NET"]} at Microsoft.Activities.Hosting.Runtime.Subroutine.SubroutineChild.Execute(CodeActivityContext context) at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor,

  • i said hello but it doesn't want to show it – n0r1s Nov 20 '13 at 9:32
  • SP.SE removes Hello automatically from the beginning of posts, to help keep your posts clear :) – Robert Lindgren Nov 20 '13 at 9:33
  • Ok I don't like it because it seems rude but why not ;)... – n0r1s Nov 20 '13 at 9:36
  • Hello everyone...in the end the issue is still the same...i used the app step in the workflow but it didn't change the problem... i'm sure it's a rights issue...i gave full control for testing and then it worked perfectly but my app can't have full control to all users...what can i do? – n0r1s Dec 10 '13 at 10:39
2

That error is a very generic workflow error and is about as useful as saying "Sorry, Something went wrong!". There is a basic approach to debugging these:

  • Do you know where it crashed? If not, add "Write to Worfklow History" at different stages to get a general idea where it stopped.
  • View the workflow history as the workflow is running. During each step, press the blue "i" button at each step. Often, before becoming suspended and giving you the generic error, it will give you a more descriptive one, telling you that for example it stopped on the SendMail activity. It will also give you a correlation ID that you can check in ULS. That should give you a better idea of where to continue. For example: enter image description here. Note how I have the "Suspend this workflow" option still there: This is the error I get BEFORE the workflow is suspended (and generally the most useful one).

Generally I've experienced issues like these with activities involving users:

  • Sending email
  • Getting user details (ex: User title, user email address, user principal ID)
  • Insufficient permissions to do certain actions (IE: You might need to run the workflow under the "App Step"
  • Hi David, my workflow is for a stock management... i have a list for entries in stock...and for each new items the amount of items in stock must be increased with the qtt in the entries list... But like i said, 2 weeks ago my workflow was working fine... why having this error now? – n0r1s Nov 20 '13 at 10:01
  • @n0r1s There may have been a change in users, change in permissions, change in Active Directory or a change in SharePoint. Does it happen when you start another workflow? What is the workflow doing? Did you try the above steps to determine what step/activity is causing the issue? – David Nov 20 '13 at 10:21
  • @n0r1s very much so, yes. If you are sending emails to groups at any point in the workflow, you must ensure that "Everyone" can view members in the group. You can also enclose the workflow in an "App Step" (this is equivalent to running under elevated privileges) and turn on the "Workflow can use app permissions" feature, to ensure the workflow has permissions to do everything it needs to do. Reading from a list? Workflow needs access to read from that list. It also needs access to Task/Workflow History, etc.. – David Nov 20 '13 at 10:24
  • Actually i have made some user permissions for the list. Is it possible that is this causing the trouble? Here's my workflow and history... sdrv.ms/17KPnYK So i guess that the update causing the problem – n0r1s Nov 20 '13 at 10:25
  • @n0r1s Note on permissions: The workflow runs with the same permissions as the user who started it. Does the user who started the workflow have write access to the list? If you don't want to give that user write access, run the "Update item in stock" step under the App Step so workflow runs under "System Administrator". Make sure to turn on the Workflow can use app permissions" feature in the site to use the App Step. – David Nov 20 '13 at 10:28
3

I was facing the same issue in past, and I nailed it with following steps

  1. Be sure User profile synchronization is started.

  2. The user by whom you are logged is available in User Profile list. ( In my case it was not created new profile for the current logged in user) and make sure, you are not running workflow with SharePoint system user. Please create a new user in Active directory, and using this user, create/provision workflow

  3. Final step full synchronization of User Profile Application.

you can access : http://anujabhojani.blogspot.in/2013/02/sharepoint-2013-workflow-gets-canceled.html

might be discussion here can help you out

  • This should work! – Muhammedh Jun 9 '15 at 5:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.