file: write was always throwing exceptions
file: write should fail if file format does not support write