def _make_writeable(filename):
 import stat
 if sys.platform.startswith('java'):
  return
 if (not os.access(filename, os.W_OK)):
  st = os.stat(filename)
  new_permissions = (stat.S_IMODE(st.st_mode) | stat.S_IWUSR)
  os.chmod(filename, new_permissions)

def _make_writeable ( filename ) : import stat if sys . platform . startswith ( 'java' ) : return if ( not os . access ( filename , os . W_OK ) ) : st = os . stat ( filename ) new_permissions = ( stat . S_IMODE ( st . st_mode ) | stat . S_IWUSR ) os . chmod ( filename , new_permissions )
make sure that the file is writeable .