Not receiving ES notification for inflated files

I would have thought ES would emit an es_event_create_t for files being created as a result of inflating an archive in the Downloads folder.

A good test for this would be to:

  1. Download Visual Studio Code (or any zip archive) to ~/Downloads
  2. Run /usr/bin/eslogger create | grep "Visual Studio Code" and watch for file creation events you'll notice a bunch in /private/var/folders but none in ~/Downloads
  3. Expand the archive and notice there's no file creation events
  4. You can run sudo eslogger create | grep "/Downloads/Visual Studio Code.app" to see that there are no files being "created" in the Downloads folder by that name.

I briefly went through the other "File Metadata Event Types" and did not seem to find one that fit the bill. Completely understand there could be another event that will collect behavior. My mute set is pretty standard and don't think there is an issue there.

Any suggestions would be greatly appreciated!

Answered by DTS Engineer in 745238022

Most unarchiving tools do the unarchiving in a temporary directory and then, when that’s all done, do a rename to move the item into place.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Accepted Answer

Most unarchiving tools do the unarchiving in a temporary directory and then, when that’s all done, do a rename to move the item into place.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Perfect! Exactly what we needed. I was searching through the telemetry as if it would be reported as /Downloads/$SOME_FILE but eslogger reports it as "destination type" and "file name". This is going to make life a bit harder with what we're trying to do, but thanks Quinn!

For those curious it looks something like this:

{
    "event": {
        "rename": {
            "destination": {
                "new_path": {
                    "dir": {
                        "path": "\/Users\/brandondalton\/Downloads"
                    },
                    "filename": "Visual Studio Code.app"
                }
            },
            "source": {
                "path": "\/private\/var\/folders\/8b\/fg_9sj9j2_9c0ghl_knlpp1c0000gp\/T\/com.apple.desktopservices.ArchiveService\/TemporaryItems\/NSIRD_ArchiveService_oK7iOq\/Visual Studio Code.app"
            }
        }
    }
}
Not receiving ES notification for inflated files
 
 
Q