I have a Web Api implementation (version 2.2) that doesn't throw any errors in the test environment.
If I run this method in dev
[HttpGet]
public HttpResponseMessage Fail()
{
return Request.CreateErrorResponse(HttpStatusCode.InternalServerError, "I shall fail", new Exception("Exception message"));
}
It returns as supposed
In the other environment I only get
{"Message":"I shall fail"}
Any ideas where to start looking?
设置为Localonly
是IncludeErrorDetailPolicy
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.