Accessing fileURL from My Photo Stream says "Operation not permitted"

This question has a terrible formatting. It is not suitable for:

  • Text: as it is code(in some form) and such texts are best understood in monospaced texts + is has new lines which are not introduced in plain text.

  • ``` Code as some of the text flows out long inside the scroll-bar.

  • Quote: it brings back the text, though code part is highlighted and it is a form of quote (of the error) too.

  • Single line code: fixes scrollbar and monospace, But introduces whitespace and stray grey color at the end of some lines.

How can this question be nicely formatted or should this be edited at all?

text for quick experimentation:

[[PHImageManager defaultManager] requestImageDataForAsset:asset options:options resultHandler:^(NSData* imageData, __unused NSString dataUTI, __unused UIImageOrientation orientation, __unused NSDictionary info)

Printing description of info: { PHImageFileDataKey = bufferLength=638976 dataLength=635368; PHImageFileOrientationKey = 0; PHImageFileSandboxExtensionTokenKey = "b96d223e9c27f2539310dc2a6759c09510c8d957;00;00000000;00000000;00000000;000000000000001a;com.apple.app-sandbox.read;01;01000003;00000000001fc7e3;01;/private/var/mobile/Media/PhotoStreamsData/11__676__94/100APPLE/IMG_____.JPG"; PHImageFileURLKey = "file:///var/mobile/Media/PhotoStreamsData/11__676__94/100APPLE/IMG____.JPG"; PHImageFileUTIKey = "public.jpeg"; PHImageResultDeliveredImageFormatKey = 9999; PHImageResultIsDegradedKey = 0; PHImageResultIsInCloudKey = 0; PHImageResultIsPlaceholderKey = 0; PHImageResultWantedImageFormatKey = 9999; }

1 Answer 1


As the question is off-topic anyway there is no need to even try to format it correctly :-) But if it would have been on-topic I would expect

  • the code part to be pre-formatted with line breaks and then just formatted as code
  • the data dumps to be pre-formatted with one attribute per line and again formatted as code

But overall it's question which even on SO will require some heavy editing not only for the formatting..

As a more general answer see How do I format my code blocks? which covers this quite thoroughly, including how to include hints to get proper source code coloring. Formatting needs to be done by the OP though in any case.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .