gpt4 book ai didi

ios - 代码=-1011“请求失败: internal server error (500)

转载 作者:行者123 更新时间:2023-11-28 21:22:45 29 4
gpt4 key购买 nike

我遇到这个问题2天了,Android应用程序在这个后台界面上运行良好,但我总是收到500错误。我的代码是这样的。

AFHTTPSessionManager *manager = [AFHTTPSessionManager manager];
manager.requestSerializer = [AFJSONRequestSerializer serializer];
manager.responseSerializer = [AFHTTPResponseSerializer serializer];
manager.responseSerializer.acceptableContentTypes = [NSSet setWithObject:@"text/html"];
[manager POST:urlString parameters:self.param.mj_keyValues success:^(NSURLSessionDataTask *task, id responseObject) {
....
} failure:^(NSURLSessionDataTask *task, NSError *error) {
....
}];

然后,程序进入失败 block ,我得到这样的 NSError 日志。

Error Domain=com.alamofire.error.serialization.response Code=-1011 "Request failed: internal server error (500)" UserInfo={com.alamofire.serialization.response.error.response=<NSHTTPURLResponse: 0x7fc26b49a080> { URL: https://training.duapp.com/record_data } { status code: 500, headers {
Server = openresty;
Content-Type = text/html;charset=utf-8;
Vary = Accept-Encoding;
Content-Language = en;
Date = Fri, 02 Sep 2016 03:55:00 GMT;
Content-Encoding = gzip;
Content-Length = 646;
Connection = keep-alive;
}
}, NSErrorFailingURLKey=https://training.duapp.com/record_data, com.alamofire.serialization.response.error.data=

然后我尝试将参数从NSDictionary转换为NSData或NSString,并用它更改requestSerializer,但都失败了,错误500。参数的格式没有错误,这是我的后台工作人员符合的。我能得到吗你有什么帮助吗?我该怎么办?

最佳答案

Code=-1011 "Request failed: internal server error (500)" 是服务器端问题。请与您的服务器团队核实,因为服务器正在向您的请求返回错误。

关于ios - 代码=-1011“请求失败: internal server error (500),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39284150/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com