我正在使用Python请求模块进行HTTP DELETE,但由于“Content-Length:0”,我在应用程序中遇到了问题。有办法解决这个问题吗?可以删除“Content-Length:0”吗?你有什么建议?
问题是服务器应用程序不接受“Content-Length”,也不接受有效负载。这样,我的请求就不应该有这些信息。
我正在做的请求:
value
答案 0 :(得分:2)
您可以像在here
中一样手动删除标题示例:
{
"description": "NativeScript Application",
"license": "SEE LICENSE IN <your-license-filename>",
"readme": "NativeScript Application",
"repository": "<fill-your-repository-here>",
"nativescript": {
"id": "org.nativescript.drawertest",
"tns-android": {
"version": "2.4.1"
}
},
"dependencies": {
"nativescript-telerik-ui": "^1.5.1",
"nativescript-theme-core": "^0.2.1",
"tns-core-modules": "2.4.4"
},
"devDependencies": {
"babel-traverse": "6.21.0",
"babel-types": "6.21.0",
"babylon": "6.14.1",
"lazy": "1.0.11",
"nativescript-dev-android-snapshot": "^0.*.*"
}
}