• You can't perform a paste that partially intersects a merge.", 'status'

    From Martinais Hudson@21:1/5 to All on Tue Sep 27 23:17:10 2022
    I have a spreadsheet that updates employee data every 2 weeks.
    I use Python script to move old data to down.
    Here is the request that I use.
    "copyPaste": {
    "source": {
    "sheetId": sheet.id,
    "startRowIndex": constants.BASE_ROW - 2,
    "endRowIndex": totalRows,
    "startColumnIndex": 0,
    "endColumnIndex": constants.WORKDAYS_PER_WEEK + 5
    },
    "destination": {
    "sheetId": sheet.id,
    "startRowIndex": newrowcount + 3,
    "endRowIndex": newrowcount + 4 + totalRows,
    "startColumnIndex": 0,
    "endColumnIndex": constants.WORKDAYS_PER_WEEK + 5
    },
    "pasteType": "PASTE_FORMAT"
    }
    While running the script, I get an exception with message: gspread.exceptions.APIError: {'code': 400, 'message': "Invalid requests[0].copyPaste: You can't perform a paste that partially intersects a merge.", 'status': 'INVALID_ARGUMENT'}

    I want to know the exact reason that the same script works in another spreadsheet. The only different thing is that the spreadsheet with exception has cells with comments, where the working spreadsheet has no ones.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)