def save(self):
        """Save the row back to the spreadsheet"""
        if self._sheet.readonly:
            raise ReadOnlyException
        if not self._changed:
            # nothing to save
            return
        gd_client = self._sheet.client
        assert gd_client is not None
        try:
            entry = gd_client.UpdateRow(self._entry, self._data)
        except RequestError as e:
            error_data = e.args[0]
            if error_data.status == 403:
                #  Forbidden
                raise
            if error_data.status == 409:
                # conflict
                raise
            else:
                raise
        self._entry = entry
        # reset `_changed` flag
        self._changed = False
        return entry
def save ( self ) : if self . _sheet . readonly : raise ReadOnlyException if not self . _changed : return gd_client = self . _sheet . client assert gd_client is not None try : entry = gd_client . UpdateRow ( self . _entry , self . _data ) except RequestError as e : error_data = e . args [ 0 ] if error_data . status == 403 : raise if error_data . status == 409 : raise else : raise self . _entry = entry self . _changed = False return entry
Save the row back to the spreadsheet