Skip to content

Library/Caches counting towards app Documents & Data storage #99

@AndrewSB

Description

@AndrewSB

Hey! posting this since I can't find any relevant documentation about this from Apple or otherwise:

It seems like iOS is counting my app's Library/Caches. all the documentation I can find (like https://developer.apple.com/documentation/foundation/optimizing_your_app_s_data_for_icloud_backup/#3928528) seems to explicitly call out the Caches/ usage isn't counted towards Documents & Data.

here's the app's usage, from the Settings app

image

If I download the app container, I see:

  1. the overall AppData folder is 613.8MB
  2. AppData/Library/Caches is 555.9MB
  3. the remaining files in AppData are 613.8-555.9=57.9MB

I'm confused as to why iOS seems to be counting my 0.5GB of caches towards my app's Documents & Data usage. for the files I'm saving in the cache, I use the static func url(for path: String?, in directory: Directory) throws -> URL, with the directory: .caches to access a sub folder inside the caches

Is this expected behavior? or am I doing something wrong? I expected the Settings app to report ~57MB of documents & data usage, not ~600MB

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions