Bug 37403

Summary: Wrong progress quantity in job details when staging records with match check
Product: Koha Reporter: Caroline Cyr La Rose <caroline.cyr-la-rose>
Component: CatalogingAssignee: Hinemoea Viault <hinemoea.viault>
Status: Pushed to main --- QA Contact: Chris Cormack <chris>
Severity: minor    
Priority: P5 - low CC: m.de.rooy, martin.renvoize
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
24.11.00
Circulation function:
Attachments: Bug 37403 : Wrong progress quantity in job details
Bug 37403 : Wrong progress quantity in job details
Bug 37403: Wrong progress quantity in job details

Description Caroline Cyr La Rose 2024-07-18 13:36:19 UTC
I noticed that when you stage MARC records and do a match check ("Look for existing records in catalog?"), the progress quantity in the Details of the job is wrong.

To recreate:
1. Go to Cataloging > Stage records for import
2. Choose a file with bibliographic records and click Upload file
3. In "Look for existing records in catalog?" choose a record matching rule (e.g. ISBN)
4. Click Stage for import
5. Click View detail of the enqueued job
   --> Progress show 2/1

I've also seen 4/2 and 12500/1000 (it's not always double)

The number seems ok if you don't check for existing records.

This has been the case at least since 23.05.
Comment 1 Hinemoea Viault 2024-07-24 16:54:39 UTC
Created attachment 169509 [details] [review]
Bug 37403 : Wrong progress quantity in job details

In fact the system adds a previous value to the progress. As if the system keeps a previous value and adds the correct count of records in addition.
This patch removes the previously stored value.

To test:
1. Go to Cataloging > Stage records for import
2. Choose a file with bibliographic records and click Upload file
3. In "Look for existing records in catalog?" choose a record matching rule (e.g. ISBN)
4. Click Stage for import
5. Click View detail of the enqueued job
   --> Progress show 2/1
6. Apply the patch
7. Repeat steps 1 to 4
8. Click View detail of the enqueued job
   --> Progress show 1/1
Comment 2 Roman Dolny 2024-07-24 19:57:35 UTC
Created attachment 169519 [details] [review]
Bug 37403 : Wrong progress quantity in job details

In fact the system adds a previous value to the progress. As if the system keeps a previous value and adds the correct count of records in addition.
This patch removes the previously stored value.

To test:
1. Go to Cataloging > Stage records for import
2. Choose a file with bibliographic records and click Upload file
3. In "Look for existing records in catalog?" choose a record matching rule (e.g. ISBN)
4. Click Stage for import
5. Click View detail of the enqueued job
   --> Progress show 2/1
6. Apply the patch
7. Repeat steps 1 to 4
8. Click View detail of the enqueued job
   --> Progress show 1/1

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>

qa script:
Commit title does not start with 'Bug XXXXX: ' - d1bebb34d7
Comment 3 Chris Cormack 2024-10-18 01:51:25 UTC
Created attachment 172939 [details] [review]
Bug 37403: Wrong progress quantity in job details

In fact the system adds a previous value to the progress. As if the system keeps a previous value and adds the correct count of records in addition.
This patch removes the previously stored value.

To test:
1. Go to Cataloging > Stage records for import
2. Choose a file with bibliographic records and click Upload file
3. In "Look for existing records in catalog?" choose a record matching rule (e.g. ISBN)
4. Click Stage for import
5. Click View detail of the enqueued job
   --> Progress show 2/1
6. Apply the patch
7. Repeat steps 1 to 4
8. Click View detail of the enqueued job
   --> Progress show 1/1

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>

qa script:
Commit title does not start with 'Bug XXXXX: ' - d1bebb34d7

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Fixed patch subject line
Comment 4 Katrin Fischer 2024-10-18 12:27:14 UTC
Pushed for 24.11!

Well done everyone, thank you!