-
-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Attempting to download call attachments returns HTTP 500 #105
Comments
Thanks for opening this issue. A contributor should be by to give feedback soon. In the meantime, please check out the contributing guidelines. |
A short update to this issue... The file data is being saved in the CallAttachments table and we're able to get the data back out using bcp: The issue seems to be with |
Hey @trystcat thank you for all that info! I'll take a look here shortly, I'm wrapping up a Unit app update and once that's done I'll be looking at some Resgrid Core issues and I've added this to my list. |
Thanks, @ucswift. We're going to do a bit more digging this weekend and I'll share any further insights that we find. |
To give a small update on this, I have found that the web container is giving the following error when trying to download a file. {
"EventId":1,
"LogLevel":"Error",
"Category":"Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware",
"Message":"An unhandled exception has occurred while executing the request.",
"Exception":"
System.NullReferenceException: Object reference not set to an instance of an object.
at Resgrid.Web.Areas.User.Controllers.DispatchController.GetCallFile(Int32 callAttachmentId) in /src/Web/Resgrid.WebCore/Areas/User/Controllers/DispatchController.cs:line 1692
at lambda_method970(Closure , Object )
at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.TaskOfActionResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.\u003CInvokeActionMethodAsync\u003Eg__Awaited|12_0(ControllerActionInvoker invoker, ValueTask\u00601 actionResultValueTask)
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.\u003CInvokeNextActionFilterAsync\u003Eg__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State\u0026 next, Scope\u0026 scope, Object\u0026 state, Boolean\u0026 isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.\u003CInvokeInnerFilterAsync\u003Eg__Awaited|13_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.\u003CInvokeNextResourceFilter\u003Eg__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(State\u0026 next, Scope\u0026 scope, Object\u0026 state, Boolean\u0026 isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.\u003CInvokeFilterPipelineAsync\u003Eg__Awaited|20_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.\u003CInvokeAsync\u003Eg__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.\u003CInvokeAsync\u003Eg__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
at Microsoft.AspNetCore.Builder.RouterMiddleware.Invoke(HttpContext httpContext)
at Microsoft.AspNetCore.Session.SessionMiddleware.Invoke(HttpContext context)
at Microsoft.AspNetCore.Session.SessionMiddleware.Invoke(HttpContext context)
at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
at Resgrid.Web.Startup.\u003C\u003Ec.\u003C\u003CConfigure\u003Eb__19_0\u003Ed.MoveNext() in /src/Web/Resgrid.WebCore/Startup.cs:line 434 --- End of stack trace from previous location ---
at Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware.\u003CInvoke\u003Eg__Awaited|6_0(ExceptionHandlerMiddleware middleware, HttpContext context, Task task)
",
"State":
{
"Message":"An unhandled exception has occurred while executing the request.",
"{OriginalFormat}":"An unhandled exception has occurred while executing the request."
}
} |
In |
I've confirmed this issue in the upstream project and working on a fix now. |
I have this issue fixed in the upstream repo, there is another issue I need to look at and I'll push the changes down and cut a new container release. |
I've pushed the latest from upstream with the fix https://github.com/Resgrid/Core/blob/develop/Core/Resgrid.Services/CallsService.cs#L366 it's currently in develop, I'm going to be testing and validating before I push to master and cut a new container release. There was a lot to sync. my bad, so I have a bit to check. |
Behaviour
Add attachment to call via
/User/Dispatch/ViewCall
Files tabAttempting to download the file via the files tab,
/User/Dispatch/GetCallFile
returns the following error:On SaaS: "Error // An Error Has Occurred // There was an error trying to process the request you have made. You can go back and retry the operation but we recommend logging out and logging back in and retrying."
On self-hosted (Docker 0.6.93): "500 // Error // An error occurred trying to process your request // The resource you requested could not be found, either contact support or try again. Use your browsers Back button to navigate to the page you have previously come from."
Analysis
CallAttachments
table.Without knowing how and where uploaded files are stored, I'm not able to dig much further into this one.
Bug reports must include:
The text was updated successfully, but these errors were encountered: