What do you need these metadata files for? More specifically, do you need these metadata files or do your users?
I deal with the same thing with GIS files. In my case, I have some open-source libraries that want to automatically write those metadata files. Obviously that fails in the sandbox.
But what I've been able to do is define an alternate location for these sidecar files. In my case, the library already supports a "PROXY_DIR" environment variable for read-only locations. So I just used that. I could have also hacked up the source, but I got lucky.
What this means is what when various legacy software bits want to write a sidecar file, it always succeeds. It writes the sidecar file in an appropriate location inside my app's sandbox container. Then when other bits of the legacy software look for the sidecar data, it's there and always available.
If I needed to export the sidecar files (which I won't), I could do that by allowing the user to specify an entire output directory and write all necessary files under a pre-determined name.