mirror of
https://github.com/microsoft/onefuzz.git
synced 2025-06-19 13:03:44 +00:00
Fix logic of marking task as failed (#3083)
* Fix logic of markaing task as failed - Do not mark task as failed if it is already in the shutting down state - accumulate errors when setting task error to understand the context - refactor the Error record * fix tests * format * Fix build * Update src/ApiService/ApiService/onefuzzlib/ImageReference.cs Co-authored-by: George Pollard <porges@porg.es> * Update src/ApiService/ApiService/onefuzzlib/ProxyOperations.cs Co-authored-by: Teo Voinea <58236992+tevoinea@users.noreply.github.com> --------- Co-authored-by: George Pollard <porges@porg.es> Co-authored-by: Teo Voinea <58236992+tevoinea@users.noreply.github.com>
This commit is contained in:
@ -36,9 +36,9 @@ sealed class TestEndpointAuthorization : EndpointAuthorization {
|
||||
|
||||
return _context.RequestHandling.NotOk(
|
||||
req,
|
||||
new Error(
|
||||
Error.Create(
|
||||
ErrorCode.UNAUTHORIZED,
|
||||
new string[] { "Unrecognized agent" }
|
||||
"Unrecognized agent"
|
||||
),
|
||||
"token verification",
|
||||
HttpStatusCode.Unauthorized
|
||||
|
Reference in New Issue
Block a user