Media upload return unknown error and second have no response
See original GitHub issueWhich Umbraco version are you using? (Please write the exact version, example: 10.1.0)
11.4
Bug summary
In appsetting, I have add
"Runtime": { "MaxQueryStringLength": 90, "MaxRequestLength": 1000 }
which restrict upload over 1mb
The first time, when I upload 3mb file, it return
Error: An unknown error occurred
Max file size is “1000KB”
as expected, but the second time, it have no response, when I inspected, the console have provide error like below :
`data":{"ExceptionMessage":"Object reference not set to an instance of an object.","ExceptionType":"System.NullReferenceException,
System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e","StackTrace":"
at Umbraco.Cms.Web.BackOffice.Controllers.MediaController.PostAddFile(String path, String currentFolder, String contentTypeAlias, List`1 file)\r\n
at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.TaskOfIActionResultExecutor.Execute(ActionContext actionContext, IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)\r\n
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Logged|12_1(ControllerActionInvoker invoker)\r\n
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeNextActionFilterAsync>g__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)\r\n
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)\r\n
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)\r\n
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeInnerFilterAsync>g__Awaited|13_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextExceptionFilterAsync>g__Awaited|26_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)"},"status":500,"config":{"method":"POST","transformRequest":[null],"transformResponse":[null],"jsonpCallbackParam":"callback","url":"/umbraco/backoffice/umbracoapi/media/PostAddFile","fields":{"currentFolder":"11025","contentTypeAlias":"umbracoAutoSelect","propertyAlias":"umbracoFile"},"file":{"$error":"maxSize","$errorMessages":{"maxSize":true},"$errorParam":"1000KB","key":"04045f2b-fc30-4309-9b51-b9b1c6324901","messages":[]},"_isDigested":true,"_chunkSize":null,"headers":{"Accept":"application/json, text/plain, */*","X-Requested-With":"XMLHttpRequest","X-UMB-CULTURE":"en-GB","X-UMB-SEGMENT":null,"X-UMB-XSRF-TOKEN":"CfDJ8KHpP_QJKXFMo0vhgKjfj8vdhZvh9p3LDXtPeU4iBVidfCeAWGx_iSqMuJ8Zjs-gx8Dn1ZS3XHzO0iIkq5f7mqWYDL75-TggfqlOkK4cvK0kKwDVBKohy1_kOuvy4xlGX1aLbxrbfCotXaY4iDQaYM5M3mmTV0cztcWx57TRIHmE5-Q2usApF4Vudiyd5Zbh9g"},"_deferred":{"promise":{}}},"statusText":"","xhrStatus":"complete"}
(anonymous) @ angular.js:15697`
Specifics
No response
Steps to reproduce
In the appsetting the configuration is
"CMS": {
"RuntimeMinification": {
"UseInMemoryCache": true,
"CacheBuster": "Timestamp"
},
"Runtime": {
"MaxQueryStringLength": 90,
"MaxRequestLength": 1000
}
}
}
Upload the first big file can return error, but the second have no response
Expected result / actual result
It should always return error if file is oversize
Issue Analytics
- State:
- Created 4 months ago
- Comments:10 (4 by maintainers)
Top Results From Across the Web
Firebase Storage: An unknown error occurred, please ...
5 Answers. First go to Storage, Rules tab and change allow read, write: if false; to true; as shown bellow. The console error...
Read more >Unknown Error Uploading PDF (with and without Migration ...
I uploaded about 40GB with the SPO Migration Tool and received errors on 3 PDF files. The error according to the MigTool is:...
Read more >[SOLVED] Upload Problem with some (large) files
The error response only says “Unknown Error”. Using either the web or the desktop client makes no difference (same negative Response after ...
Read more >Common uploading errors - YouTube Help
If you're having problems uploading your video, select the error message you're seeing and follow the troubleshooting steps to solve your issue.
Read more >How to Fix "Error 520: Web Server Is Returning an ...
The 520 error has to do with an error with your server that causes Cloudflare to not connect. Check out how to troubleshoot...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@laputaworkuk We are looking into this issue
Hi @elit0451 Thank you for your help, if you have any update, please let me know Thank you