python write json to file example