Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-25251

The job status display shows Done for any job already finished when the page is loaded

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • None
    • 18.8.0
    • Job
    • None
    • Unknown

    Description

      Problem

      The pages that display the status of a job with the displayJobStatus macro of job_macros.vm display "Done." for a job which is already finished when the page is loaded, even when the job failed. This affects for example the status page of an attachment move, the page restore status, the filter stream job page, the legacy notification migration page and the orphaned extensions clean-up step of the Distribution Wizard (distribution/extension.clean.apply.finalize.wiki).

      The message is only correct when the page is opened while the job runs: the progress bar is then replaced by the message computed by job_status_json.vm when the job ends.

      Cause

      displayJobStatus passes $status, which is not one of its parameters (so generally undefined), to jobFinishedMessage instead of its own $jobStatus parameter. With an undefined status, jobFinishedMessage finds no error, no cancellation and no error in the log, and displays the success message.

      Fix

      Pass $jobStatus.

      Attachments

        Issue Links

          Activity

            People

              ciaens Clément Christiaens
              ciaens Clément Christiaens
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated: