s3 call pwd changes before file write