OOlashyn / PCF-AttachmentGalleryControl

Attachment Gallery Control using Powerapps Component Framework
MIT License
26 stars 11 forks source link

Maximum Call stack size exceeded #28

Closed shah1341 closed 2 years ago

shah1341 commented 2 years ago

Hi OOlashyn, first of all let me thank you for your amazing PCF control, you are AWESOME.

we having an issue with PCF-AttachmentGalleryControl used on CRM form for Notes attachment. Time to time end-user reported that issue when they tried to attach a file to the Note.

Error code 0x0: An error has occurred while trying to upload the attachment. Maximum call stack size exceeded.

Would you please look into these to see if you can find a solution for that.

Environment: Dynamics365 on cloud.

Please feel free to ask any question to obtain more information.

P.S: I have no access to the application logs on server side.

new-issue
OOlashyn commented 2 years ago

Hi @shah1341, Unfortunately, the error log isn't helpful and the error described here is too generic. You can try to open console logs of the browser to check for any additional errors. Also, my control doesn't allow for note attachment. Do you mean that the user cannot attach notes when my control is on the form? Or that it cannot download the note through my control?

shah1341 commented 2 years ago

Hi OOlashyn, thank you for reply. I agree with you that is a very generic error. I did a debug via developer tools from browser, when I do the drag and drop, console is absolutely empty and no any information logged in console. User can attach file/document to the note, no any issue here, however, time to time that error message shows up and when user try again, it goes through and file will be uploaded.

Based on the research and reading articles from internet, it's kind of recursion is happing here, I mean one of the function called recursively until stack is full. Attached is screenshot captured from PFC control when I did a debug. And as I mentioned, this is not happening all the time, also I tried to reproduce it in the other environment, it's same, sometimes it appeared and most of the time works as it supposed to.

Thanks again

debug
OOlashyn commented 2 years ago

@shah1341 the files that you are showing belong to AttachmentUpload control - which isn't mine. My control is AttachmentGalleryControl. You will need to find out author of that control and reach out to him