ios file无法删除?代码如下
let file = AVFile(URL: "http://ac-nh0FlDrM.clouddn.com/AaqmRCTO3UN8hJ5CpW29BTC.png")
file.deleteInBackgroundWithBlock({succeed, error in
if succeed {
print("delete succeed")
}else {
print("\ (error)")
}
})

Error Domain=AVOS Cloud Error Domain Code=1 "Not Found" UserInfo={error=Not Found, NSLocalizedDescription=Not Found, code=1}

为什么会找不到文件呢,下载正常啊,
权限也设置成所有用户了。

请打开日志,将request 和 response 日志粘贴出来看下。
打开日志的方法:
[AVOSCloud setAllLogsEnabled:YES];

------ BEGIN LeanCloud REST Request -------

------ END --------------------------------

2016-06-30 19:22:30.635 ServerTest[1663:16438] [DEBUG] _59-[AVPaasClient performRequest:saveResult:block:retryTimes:]block_invoke.408 [Line 603]

------ BEGIN LeanCloud REST Response ------

------ END -------------------------------

2016-06-30 19:22:30.635 ServerTest[1663:16438] [ERROR] +[AVErrorUtils errorFromJSON:] [Line 201] error: Error Domain=AVOS Cloud Error Domain Code=1 "Not Found" UserInfo={error=Not Found, NSLocalizedDescription=Not Found, code=1}
Error Domain=AVOS Cloud Error Domain Code=1 "Not Found" UserInfo={error=Not Found, NSLocalizedDescription=Not Found, code=1}

谢谢

本主题设置为不显示在主题列表中。只能通过直达链接来访问。

???
为什么隐藏了帖子?

因为日志暴露了 App Id 和 App Key
我们正在查看问题,有结果后会回复

好的 我编辑下把app id和key 隐藏了可以吧?
如果可以把贴子显示出来吧

本主题已设置为显示在主题列表中。

不能使用 url 构造 file 之后删除,因为无法获取服务器端的 objectId。
要先通过 AVFileQuery 将相应的 AVFile 查询下来,再调用 delete 方法。

谢谢 问题解决了。