"First time" file upload failing

Vote:
 

Experiencing a bug when uploading a file for the first time on an EpiServer page.

Using the "+"-button as the image shows:

I get the following result with the "Content type "DocumentFile" is not allowed..."-message when hovering on "Mislyktes" (Norwegian for "Failed"):

The "DocumentFile" is defined as follows:

Getting this console message if helpful:

If I, however, use drag and drop to add the first file - it works. And when I then add a new file with the "+"-button after a file is uploaded with drag and drop, this will now also work.

So, the issue only occurs when uploading a file with the "+"-button the first time.

Is this a known issue? Or does anyone have an idea what causes this behavior?

Running EpiServer 11.12

#206668
Aug 28, 2019 13:57
Vote:
 

Hi jonasloc,

The error message in the above screenshot pointing you to exact issue. Actually, when you pressed the + button first time it will try to create the media file under the "StartPage" and media items are not allowed under the "StartPage" so that's why it is giving the failed error.

So it might be possible that for the first time Episerver not able to identify the parent folder to upload the media item or you have selected the "StartPage" to upload the media item.

Also attaching the ss with highlighting the message

I hope it helps.

Regards

Ravindra

#206676
Edited, Aug 28, 2019 14:44
Vote:
 

The issue also applies to all sub-pages of "StartPage" as long as no previous successful file upload has occured on that page.

Which is the case here:

I also mention in the original post that the drag and drop functionality works regardless if it is the first time or not. Do you know why there is a difference between using the + and drag-and-drop?

#206697
Aug 28, 2019 16:31
Vote:
 

I think this was a bug for one specific Episerver version that was fixed rather quickly.
What version are you running? Is upgrading an option?

#206702
Aug 28, 2019 20:45
Vote:
 

Running Episerver CMS 11.12.0.

EPiServer.UI is at 11.21.2. 

Upgrading is an option yes - but cannot find any fix for this in recent release notes.

#206720
Aug 29, 2019 10:27
Vote:
 

What if you create a new folder first? Does the upload work then?

That was our workaround for the bug I have in mind. I can't find it in the release notes either.

#206721
Aug 29, 2019 10:31
jonasloc - Aug 29, 2019 12:28
Creating a folder first worked! But since our editors are unaware of the issue they will still try the "+"-button first. So then we might as well tell them to use drag-and-drop instead of the new folder "hack".

Do you have any idea why the drag-and-drop works and not the + when uploading for the first time?
Vote:
 

I tried the same scenario with Episerver.UI "11.20.1.0" and not able to replicate this issue so I think you can give a try with upgrading the Episerver version.

#206722
Edited, Aug 29, 2019 10:42
jonasloc - Aug 29, 2019 12:32
Since we are running the same EPiserver version do you suggest upgrading EPiServer.UI to latest or downgrade to your version?
Ravindra S. Rathore - Aug 29, 2019 12:36
I think you should upgrade the UI to the latest version
jonasloc - Aug 29, 2019 15:41
The issue still persists with the latest versions.
Vote:
 

Sorry for the long post, but I checked the devtools network tab to see what was going on with both the "+"-button and drag-and-drop, and found some interesting results.

"+"-button:

Call stack:                                                                                                             

Response of Upload/:

contentLink = null which lead to contenLink = -1 in the URL Request in the header of "-1?dojo.prevent...":

And returns:

------------------------------------------------------------------------------------------------------------

Drag-and-drop:

Call stack:                                                                                                     

 

Response of Upload/:

contentLink = 778_866 which leads to contenLink = 547 in the URL Request in the header of "547?dojo.prevent...":

And has an "assetsFolderLink" in the response:

Which we in the call stack see is called later in "777?dojo.prevent..." and is the contentFolder.

------

Clearly the contentLink is the issue here. Doesn't really help fixing the issue, but shares som light on what's going on.

#206762
Edited, Aug 29, 2019 15:36
Vote:
 

Thanks for doing this research, Jonasloc. Can you please submit this bug to support@episerver.com?

#206788
Aug 29, 2019 18:59
jonasloc - Aug 30, 2019 12:47
Done.
Vote:
 

We are also experiencing the same error. I've upgraded to the latest EPi nugets but still the problem persists. 

For now only drag and drop works. 

#206811
Aug 30, 2019 10:27
Vote:
 

Same problem here..

#206883
Sep 03, 2019 10:40
Vote:
 

The bug has returned - and is fixed (again) in EPiServer.CMS.UI 11.21.7, bug CMS-14589.

#207688
Sep 30, 2019 21:15
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.