you can use with ```open(file, 'wb+) as file:``` which handles closing file descriptor