Update writer.py