a better pattern I prefer is:

    with open(self.utils_path, "w+") as fh:
        fh.write(utils_template)

This handles filehandle cleanup, and is more 'idiomatic' python.