Request for help with errors occurring in an active flow that haven't been an issue in the past.

Options

Good morning trusty community!

This morning our acknowledgement flow is giving us grief. I'm using the Acknowledgement Flow that I published in 2023.

It failed yesterday with a “404 Error” and message "File Not Found\\r\\n…" and I don't understand why. During some testing today we changed the letter code to one that worked the day before and now I'm getting a “400 Error” with the message “A file with the same name is currently being saved to this site. Change the filename and try to save again.\\r\\n…” (I confirmed the file does not exist in the folder we are trying to create the file.) I also tried adding a delay before the Create Letter files step and still receive the same error. Below is a snip of the flow.

6f148b74a65b1bd815d70273f53b8df5-huge-im

I'd appreciate if someone could let me know what I'm missing or suggest additional things to test. I'm not sure what could have changed in the last 24 hours to create this error.

Thank you in advance!

Comments

  • Alex Wong
    Alex Wong Community All-Star
    Ninth Anniversary 1,500 Likes 2500 Comments Name Dropper

    @Hallie Guiseppe
    create file in sharepoint action has never really reported wrong error code, so i'm 99% certain that the error code is correct.

    What could happen:

    • someone changed your flow (if other have access)
    • someone changed the sharepoint location folder structure (intentionally or accident)

    file not found error can be b/c the folder you are trying to save to is not at the location flow expect it to be. Then not sure what you may have done, but the flow ran again and the same “location” to save the file now already have the file there.

    to troubleshoot:

    • edit the create file action to select the folder path and see if you can “drill down” to the same folder
    • update the file name with a random file name: you can use rand() expression to get a random number to add
      • This is my file name for my eReceipt SKY Add-in: tmp_ereceipt_@{triggerBody()['number']}_@{rand(1, 1000000)}.docx
      • Unless you “hardcode” the subsequent actions that uses this word doc file, you should not need to make any change to the rest of your flow.
  • @Alex Wong?
    Thanks so much for your feedback Alex. As I was digging in on your suggestions, I noticed that the constituent name had invalid characters that I had not accounted for in my replace step. Once I added %28 & %29 to the replace step, the flow worked. I wish the error codes were more clear ?.

    I use the gift id and date in my naming to mimic a random file name format so I've never had any issue with the file name already existing. However, I can see the Rand expression being useful in other cases. Thanks!

    Thanks again for jumping in to help problem solve!

  • Alex Wong
    Alex Wong Community All-Star
    Ninth Anniversary 1,500 Likes 2500 Comments Name Dropper

    @Hallie Guiseppe
    Glad you were able to find the issue.

    Yes, that is why I never use constituent name in the file name, only ID. But I can understand why you may want to use name if you have a repository of these files in sharepoint and want to make sure people looking at the folder can easily find the file for a donor.

    My 2-cents, and it is just an opinion, very subjective to your business process/needs: don't keep these files in SharePoint, once you are done with them, delete them in the flow. Depending on the file, I attach the file to the gift record or constituent record, so if someone need a backup of this file, they can find it in RE NXT.

    Reasoning: you are taking up valuable space (in terms of Bytes of data AND in terms of # of files in a folder, when you have too many files in a folder, SharePoint will have a problem with displaying it.

    If you want to do the delete file in the flow, you may have an issue with the file still being “open” by the flow, so to ignore that and still delete, you can do:

    a6fbfcd4d6ebfe2bb19d4cce5089da8b-huge-im

    Select Method=POST and Uri body is:

    _api/web/Lists/GetByTitle('Documents')/GetItemById(@{outputs('Create_Receipt_WordDoc_01')?['body/ItemId']})/recycle

    where ItemId is from the Create file action's dynamic content

    and in the Headers: include Prefer: bypass-shared-lock

  • @Alex Wong
    How~do I complain to Flipkart? To get Flipkart's customer••service team, you can call them at O8123+195-405 or (+8123)+195-405 or you can email them at cs@flipkart.com. Additionally, you can submit a complaint through their website's customer support portal issue•

Categories