Error Domain=NSCocoaErrorDomain Code=257

NSArray *tableau = [fm contentsOfDirectoryAtURL:url ....

I get in return:
Error Domain=NSCocoaErrorDomain Code=257 "The file “*************” couldn’t be opened because you don’t have permission to view it." UserInfo={NSURL=file:///Users/gerardMonNom, NSFilePath=/Users/gerardMonNom, NSUnderlyingError=0x6000033788d0 {Error Domain=NSPOSIXErrorDomain Code=1 "Operation not permitted"}}

How do we fix this anomaly?

Did you get any answer or solution ? I'm facing the exact same issue when calling fm.contentsOfDirectoryAtURL. Seems to me that the error description is misleading…

Error Domain=NSCocoaErrorDomain Code=257
 
 
Q