daisy / pipeline-ui

A user interface for the DAISY Pipeline 2
MIT License
6 stars 2 forks source link

Status says error but no info about why #233

Closed marisademeglio closed 5 months ago

marisademeglio commented 5 months ago

Testing feedback from @rachanasinghg for 1.4.0-beta

There are no errors/warnings in messages but the status says "Error".

DP_FalseErrorReport

marisademeglio commented 5 months ago

This one I can reproduce. The job status is reported by the engine as FAIL:

14:35:40.106 › received job data  {
[1]   jobId: '45715faa-7e3d-4930-9a46-1398e6c59908',
[1]   status: 'FAIL',
[1]   href: 'http://127.0.0.1:49152/ws/jobs/45715faa-7e3d-4930-9a46-1398e6c59908',
[1]   nicename: 'DAISY 2.02 Validator',
[1]   log: 'http://127.0.0.1:49152/ws/jobs/45715faa-7e3d-4930-9a46-1398e6c59908/log',
[1]   results: {
[1]     href: 'http://127.0.0.1:49152/ws/jobs/45715faa-7e3d-4930-9a46-1398e6c59908/result',
[1]     mimeType: 'application/zip',
[1]     namedResults: [ [Object] ]
[1]   },
[1]   messages: [ 'removed to keep log cleaner' ],
[1]   progress: 1,
[1]   script: {
[1]     id: 'daisy202-validator',
[1]     href: 'http://127.0.0.1:49152/ws/scripts/daisy202-validator',
[1]     nicename: 'DAISY 2.02 Validator',
[1]     description: 'Validates a DAISY 2.02 fileset.',
[1]     version: '2.0.10',
[1]     homepage: '',
[1]     inputs: [],
[1]     options: []
[1]   }
[1] }

and the validation report says

    expected duration 0 but found 327

    file:/Users/marisa/dev/pipeline-samples/daisy202/Mountains_skip/master.smil

But the messages from the job don't reflect what's in the validation report, nor does the job status really give any clues as to what "Error" means.

Right now we translate job status "ERROR" and "FAIL" both to "Error". We could instead translate "FAIL" to "Fail" ? Would that always make sense @bertfrees ? https://github.com/daisy/pipeline-ui/blob/main/src/shared/jobName.ts#L3

bertfrees commented 5 months ago

Yes, that would make sense! An error means that the script was not able to complete. It stopped somewhere in the middle of the conversion. If the status is FAIL, the script completed, but there is an issue with the results. Typically there is some validation that failed, and a validation report is given, and/or the user can find some error or warning messages in the log that indicate what the issue is.