Bugzilla – Attachment 172705 Details for
Bug 38156
Auto renew cron job mangles digest notices when parallel processing is enabled
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 38156: [DO NOT PUSH] Test data to reproduce the issue
Bug-38156-DO-NOT-PUSH-Test-data-to-reproduce-the-i.patch (text/plain), 3.15 KB, created by
Emily Lamancusa (emlam)
on 2024-10-11 20:15:57 UTC
(
hide
)
Description:
Bug 38156: [DO NOT PUSH] Test data to reproduce the issue
Filename:
MIME Type:
Creator:
Emily Lamancusa (emlam)
Created:
2024-10-11 20:15:57 UTC
Size:
3.15 KB
patch
obsolete
>From 8ae4972c4cb7ef5147d4234caba185a1c1a92ab6 Mon Sep 17 00:00:00 2001 >From: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov> >Date: Fri, 11 Oct 2024 15:24:26 -0400 >Subject: [PATCH] Bug 38156: [DO NOT PUSH] Test data to reproduce the issue > >--- > generate_checkouts.pl | 35 +++++++++++++++++++++++++++++ > misc/cronjobs/automatic_renewals.pl | 3 +++ > 2 files changed, 38 insertions(+) > create mode 100644 generate_checkouts.pl > >diff --git a/generate_checkouts.pl b/generate_checkouts.pl >new file mode 100644 >index 0000000000..a15f0d2d61 >--- /dev/null >+++ b/generate_checkouts.pl >@@ -0,0 +1,35 @@ >+#!/usr/bin/perl >+ >+use Modern::Perl; >+use Koha::DateUtils qw ( dt_from_string ); >+use C4::Circulation qw( AddIssue ); >+use Koha::Patrons; >+ >+C4::Context->set_userenv(42, 51, 42, 'koha', '', 'CPL', 'Centerville'); >+ >+my $datedue = dt_from_string->add( days => 2 ); >+my $p1 = Koha::Patrons->find(18); >+my $p2 = Koha::Patrons->find(22); >+my $p3 = Koha::Patrons->find(49); >+my $p4 = Koha::Patrons->find(5); >+ >+AddIssue( $p1, 39999000002034, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p1, 39999000005417, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p2, 39999000010138, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p3, 39999000018653, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p3, 39999000006452, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p3, 39999000006773, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p1, 39999000010114, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p4, 39999000012897, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p2, 39999000008111, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p1, 39999000002331, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p1, 39999000008074, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p3, 39999000012958, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p3, 39999000014891, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p1, 39999000001358, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p1, 39999000014419, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p2, 39999000006759, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p2, 39999000001679, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p4, 39999000005455, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p4, 39999000001594, $datedue, undef, undef, { auto_renew => 1 } ); >+AddIssue( $p4, 39999000015331, $datedue, undef, undef, { auto_renew => 1 } ); >diff --git a/misc/cronjobs/automatic_renewals.pl b/misc/cronjobs/automatic_renewals.pl >index d5018a46e1..3c687e4517 100755 >--- a/misc/cronjobs/automatic_renewals.pl >+++ b/misc/cronjobs/automatic_renewals.pl >@@ -161,8 +161,11 @@ if ( $loops > 1 ) { > } > $i = 0 if $i >= $loops; > push( @{ $chunks[$i] }, $auto_renew ); >+ >+ warn("Chunk $i - Borrowernumber:" . $auto_renew->borrowernumber . " Item " . $auto_renew->itemnumber); > } > my $pm = Parallel::ForkManager->new($loops); >+ > DATA_LOOP: > foreach my $chunk (@chunks) { > my $pid = $pm->start and next DATA_LOOP; >-- >2.34.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 38156
: 172705 |
172706
|
172763
|
172831