Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    5.1d BatchUploader does not clear errors

    Hi Isomorphic,

    please see the testcase from this thread, but with your working employeesUpload.ds.xml from here.
    I'm using SNAPSHOT_v10.1d_2015-10-14/PowerEdition Deployment in FF26 DevMode.

    I have two - possibly unrelated - errors here for one request:
    #1:
    Upload the file with the error (1 row has an error, 1 row is fine) and commit (1 row will be saved).
    Now change the primaryKey-IDs in the .csv and fix the NOTKNOWN to "Charles Madigan".
    If you upload this file now again, you'll see this as request (not response):
    Code:
    {
        dataSource:"batchUpload",
        operationType:"update",
        operationId:"upload",
        componentId:"isc_DynamicForm_0",
        data:{
            file:"Testdata.csv",
            dsName:"employeesUpload",
            delimiter:",",
            quoteString:"\"",
            dataFormat:"csv",
            discardedColumns:[
            ],
            [B]errors:[
                {
                    errors:{
                        ReportsTo:[
                            "Must be a whole number.",
                            "Unknown ReportsTo"
                        ]
                    },
                    rowNum:0
                }
            ][/B],
            gridRows:[
                {
                    Name:"Michael Mann",
                    Job:"Developer",
                    Gender:"male",
                    ReportsTo:4,
                    EmployeeId:7033,
                    employeeName:"Charles Madigen"
                },
                {
                    Name:"Ray Sun",
                    Job:"IT-Infrastructure",
                    ReportsTo:4,
                    EmployeeId:8033,
                    employeeName:"Charles Madigen"
                }
            ]
        },
        textMatchStyle:"exact",
        callback:{
            target:[DynamicForm ID:isc_DynamicForm_0],
            methodName:"saveEditorReply"
        },
        showPrompt:true,
        prompt:"Saving form...",
        oldValues:{
            dsName:"employeesUpload",
            delimiter:",",
            quoteString:"\"",
            dataFormat:"csv",
            file:null,
            discardedColumns:[
            ],
            [B]errors:[
                {
                    errors:{
                        ReportsTo:[
                            "Must be a whole number.",
                            "Unknown ReportsTo"
                        ]
                    },
                    rowNum:0
                }
            ][/B],
            gridRows:[
                {
                    Name:"Michael Mann",
                    Job:"Developer",
                    Gender:"male",
                    ReportsTo:4,
                    EmployeeId:7033,
                    employeeName:"Charles Madigen"
                },
                {
                    Name:"Ray Sun",
                    Job:"IT-Infrastructure",
                    ReportsTo:4,
                    EmployeeId:8033,
                    employeeName:"Charles Madigen"
                }
            ]
        },
        requestId:"batchUpload$62720",
        clientContext:{
            saveDataTarget:{
                ns:Obj,
                creator:[BatchUploader ID:isc_BatchUploader_0],
                ID:"isc_BatchUploader_0_uploadForm",
                saveOperationType:"update",
                width:1182,
                fields:Array[5],
                position:"absolute",
                className:"normal",
                height:20,
                items:Array[5],
                values:Obj,
                originalFields:Array[5],
                children:Array[1],
                errors:Obj,
                parentElement:[BatchUploader ID:isc_BatchUploader_0],
                topElement:[Window ID:isc_Window_0],
                tabIndex:1280,
                ruleScope:"isc_Window_0",
                cacheOffsetCoords:true,
                zIndex:200198,
                dataSource:"batchUpload"
            }
        },
        internalClientContext:{
        },
        fallbackToEval:false,
        afterFlowCallback:"isc_DynamicForm_0.$49z(dsRequest, dsResponse, data)",
        directSubmit:true,
        submitForm:[DynamicForm ID:isc_DynamicForm_0],
        editor:[DynamicForm ID:isc_DynamicForm_0],
        lastClientEventThreadCode:"MUP7",
        bypassCache:true,
        dataProtocol:"getParams"
    }
    I don't see why the errors should be transferred - neither as data nor as oldValues.

    Error #2:
    I also got this response once (not always) while repeating the steps:
    Code:
    {
        affectedRows:0,
        data:{
            discardedColumns:[
            ],
            errors:[
                "Index: 6, Size: 6\n\nSee the log for more details about this error."
            ],
            gridRows:null
        },
        invalidateCache:false,
        isDSResponse:true,
        operationType:"update",
        queueStatus:0,
        status:0
    }
    See the screenshot for this. I don't know what this means or where it comes from. I did not get a message in the GUI.
    The BatchUploader Grid is empty afterwards. Click image for larger version

Name:	ErrorIndexSize.png
Views:	98
Size:	68.1 KB
ID:	232044





    Best regards
    Blama
    Last edited by Blama; 15 Oct 2015, 01:36.

    #2
    Hi Isomorphic,

    error #1 does also affect gridRows in data and oldValues.

    I uploaded the working file, committed, updated the IDs in the file, uploaded again. These are the two batchUpload.update<upload> requests from the Developer Console:
    #1:
    Code:
    {
        dataSource:"batchUpload", 
        operationType:"update", 
        operationId:"upload", 
        componentId:"isc_DynamicForm_1", 
        data:{
            file:"TestdataImportEmployees.csv", 
            dsName:"employeesUpload", 
            delimiter:",", 
            quoteString:"\"", 
            dataFormat:"csv"
        }, 
        textMatchStyle:"exact", 
        callback:{
            target:[DynamicForm ID:isc_DynamicForm_1], 
            methodName:"saveEditorReply"
        }, 
        showPrompt:true, 
        prompt:"Saving form...", 
        oldValues:{
            dsName:"employeesUpload", 
            delimiter:",", 
            quoteString:"\"", 
            dataFormat:"csv", 
            file:null
        }, 
        requestId:"batchUpload$62722", 
        clientContext:{
            saveDataTarget:{
                ns:Obj, 
                creator:[BatchUploader ID:isc_BatchUploader_1], 
                ID:"isc_BatchUploader_1_uploadForm", 
                saveOperationType:"update", 
                width:1182, 
                fields:Array[5], 
                position:"absolute", 
                className:"normal", 
                height:20, 
                items:Array[5], 
                values:Obj, 
                originalFields:Array[5], 
                children:Array[1], 
                errors:Obj, 
                parentElement:[BatchUploader ID:isc_BatchUploader_1], 
                topElement:[Window ID:isc_Window_1], 
                tabIndex:2402, 
                ruleScope:"isc_Window_1", 
                cacheOffsetCoords:true, 
                zIndex:202340, 
                dataSource:"batchUpload"
            }
        }, 
        internalClientContext:{
        }, 
        fallbackToEval:false, 
        afterFlowCallback:"isc_DynamicForm_1.$49z(dsRequest, dsResponse, data)", 
        directSubmit:true, 
        submitForm:[DynamicForm ID:isc_DynamicForm_1], 
        editor:[DynamicForm ID:isc_DynamicForm_1], 
        lastClientEventThreadCode:"MUP9", 
        bypassCache:true, 
        dataProtocol:"getParams"
    }
    #2:
    Code:
    {
        dataSource:"batchUpload", 
        operationType:"update", 
        operationId:"upload", 
        componentId:"isc_DynamicForm_1", 
        data:{
            file:"TestdataImportEmployees.csv", 
            dsName:"employeesUpload", 
            delimiter:",", 
            quoteString:"\"", 
            dataFormat:"csv", 
            discardedColumns:[
            ], 
            [B]gridRows:[
                {
                    Name:"Michael Mann", 
                    Job:"Developer", 
                    Gender:"male", 
                    ReportsTo:4, 
                    EmployeeId:7035, 
                    employeeName:"Charles Madigen"
                }, 
                {
                    Name:"Ray Sun", 
                    Job:"IT-Infrastructure", 
                    ReportsTo:4, 
                    EmployeeId:8035, 
                    employeeName:"Charles Madigen"
                }
            ][/B]
        }, 
        textMatchStyle:"exact", 
        callback:{
            target:[DynamicForm ID:isc_DynamicForm_1], 
            methodName:"saveEditorReply"
        }, 
        showPrompt:true, 
        prompt:"Saving form...", 
        oldValues:{
            dsName:"employeesUpload", 
            delimiter:",", 
            quoteString:"\"", 
            dataFormat:"csv", 
            file:null, 
            discardedColumns:[
            ], 
            [B]gridRows:[
                {
                    Name:"Michael Mann", 
                    Job:"Developer", 
                    Gender:"male", 
                    ReportsTo:4, 
                    EmployeeId:7035, 
                    employeeName:"Charles Madigen"
                }, 
                {
                    Name:"Ray Sun", 
                    Job:"IT-Infrastructure", 
                    ReportsTo:4, 
                    EmployeeId:8035, 
                    employeeName:"Charles Madigen"
                }
            ][/B]
        }, 
        requestId:"batchUpload$62726", 
        clientContext:{
            saveDataTarget:{
                ns:Obj, 
                creator:[BatchUploader ID:isc_BatchUploader_1], 
                ID:"isc_BatchUploader_1_uploadForm", 
                saveOperationType:"update", 
                width:1182, 
                fields:Array[5], 
                position:"absolute", 
                className:"normal", 
                height:20, 
                items:Array[5], 
                values:Obj, 
                originalFields:Array[5], 
                children:Array[1], 
                errors:Obj, 
                parentElement:[BatchUploader ID:isc_BatchUploader_1], 
                topElement:[Window ID:isc_Window_1], 
                tabIndex:2402, 
                ruleScope:"isc_Window_1", 
                cacheOffsetCoords:true, 
                zIndex:202340, 
                dataSource:"batchUpload"
            }
        }, 
        internalClientContext:{
        }, 
        fallbackToEval:false, 
        afterFlowCallback:"isc_DynamicForm_1.$49z(dsRequest, dsResponse, data)", 
        directSubmit:true, 
        submitForm:[DynamicForm ID:isc_DynamicForm_1], 
        editor:[DynamicForm ID:isc_DynamicForm_1], 
        lastClientEventThreadCode:"MUP2", 
        bypassCache:true, 
        dataProtocol:"getParams"
    }
    Best regards
    Blama

    Comment


      #3
      Just a note to say we have reproduced this issue and have a developer queued up to look deeper

      We'll follow up when we have more information for you

      Thanks
      Isomorphic Software

      Comment


        #4
        Ok - we have found the culprit and have a fix.
        Please try the next nightly build - Oct 21

        Regards
        Isomorphic Software

        Comment


          #5
          Hi Isomorphic

          this is fixed for me using SNAPSHOT_v10.1d_2015-10-22.

          Thank you,
          Blama

          Comment

          Working...
          X