Bug 41238

Summary: Pseudonymize statistic jobs don't update progress
Product: Koha Reporter: Nick Clemens (kidclamp) <nick>
Component: Architecture, internals, and plumbingAssignee: Bugs List <koha-bugs>
Status: Signed Off --- QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low CC: david
Version: Main   
Hardware: All   
OS: All   
GIT URL: Initiative type: ---
Sponsorship status: --- Comma delimited list of Sponsors:
Crowdfunding goal: 0 Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
This fixes the progress shown for pseudonymize statistics background jobs. The progress was shown in the list of jobs (Administration > Jobs > Manage jobs) as "0/1" instead of "1/1", even though the background job was finished.
Version(s) released in:
Circulation function:
Attachments: Bug 41238: Update progress for peseudonmyzation bacgkround jobs
Bug 41238: Update progress for peseudonmyzation bacgkround jobs

Description Nick Clemens (kidclamp) 2025-11-11 18:51:53 UTC
To test:
Enable pseudonymization, may need to add bcrypt settings (see bug 28911)
Perform some circulations
View the jobs (Admin->Manage jobs)
Filter for Pseudonymize statistic
Note the progress is 0/1 even when job finished
Comment 1 Nick Clemens (kidclamp) 2025-11-11 18:53:23 UTC
Created attachment 189495 [details] [review]
Bug 41238: Update progress for peseudonmyzation bacgkround jobs

To test:
Enable pseudonymization, may need to add bcrypt settings (see bug 28911)
Perform some circulations
View the jobs (Admin->Manage jobs)
Filter for Pseudonymize statistic
Note the progress is 0/1 even when job finished
Apply patch, restart all
Do more circulations
Confirm jobs now say 1/1 complete
Comment 2 David Nind 2025-11-11 19:49:45 UTC
Created attachment 189496 [details] [review]
Bug 41238: Update progress for peseudonmyzation bacgkround jobs

To test:
Enable pseudonymization, may need to add bcrypt settings (see bug 28911)
Perform some circulations
View the jobs (Admin->Manage jobs)
Filter for Pseudonymize statistic
Note the progress is 0/1 even when job finished
Apply patch, restart all
Do more circulations
Confirm jobs now say 1/1 complete

Signed-off-by: David Nind <david@davidnind.com>
Comment 3 David Nind 2025-11-11 19:57:28 UTC
Testing notes (using KTD):

1. Generate a password: htpasswd -bnBC 10 "" password | tr -d ':\n' | sed 's/$2y/$2a/'

2. Edit the koha-conf.xml file: sudo vi /etc/koha/sites/kohadev/koha-conf.xml

3. Add brypt_settings to the file near the end (before the closing </config> at the end of the file:
   <bcrypt_settings></bcrypt_settings>

4. Add the value generated in step 1 to the setting.

5. Restart everything: restart_all