[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #32 from Jonathan Druart --- Created attachment 92031 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=92031=edit Bug 22741: Add a test Signed-off-by: Jonathan Druart -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Jonathan Druart changed: What|Removed |Added Attachment #90877|0 |1 is obsolete|| --- Comment #31 from Jonathan Druart --- Created attachment 92030 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=92030=edit Bug 22741: Make updated_on timezone aware in Koha::Patron Signed-off-by: Jonathan Druart -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Jonathan Druart changed: What|Removed |Added Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #30 from Jonathan Druart --- (In reply to Martin Renvoize from comment #29) > Hmm.. I don't really like the idea of calling a t/lib function in Koha:: > code.. if we're going to do that I'd suggest we move the compare function > into koha proper. Me neither :) It was to compare the 2 dates in the test. > However, I also don't think the updated_on field is a helpful piece of > information in the action logs table.. if it is helpful I believe the > correct approach would be to ensure it matches exactly the data in the > borrowers table. > > Shall we go ahead and change the title of the bug.. I think that's the way > forward.. bringing onboard a few more CC's Yup! -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Martin Renvoize changed: What|Removed |Added CC||katrin.fisc...@bsz-bw.de -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #29 from Martin Renvoize --- Hmm.. I don't really like the idea of calling a t/lib function in Koha:: code.. if we're going to do that I'd suggest we move the compare function into koha proper. However, I also don't think the updated_on field is a helpful piece of information in the action logs table.. if it is helpful I believe the correct approach would be to ensure it matches exactly the data in the borrowers table. Shall we go ahead and change the title of the bug.. I think that's the way forward.. bringing onboard a few more CC's -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #28 from Jonathan Druart --- (In reply to Martin Renvoize from comment #18) > { >"updated_on" : { > "after" : "2019-06-20 14:20:18", > "before" : "2019-06-20 14:20:19" > >} > } If this is the cause of the failure, we should compare the 2 values with t::lib::Dates::compare If we want to change the behavior we should update the bug report's title. -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #27 from Martin Renvoize --- To note.. the cause of this in the first place and a patch to try and alleviate it was written ages ago on bug 20621 -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Martin Renvoize changed: What|Removed |Added See Also||https://bugs.koha-community ||.org/bugzilla3/show_bug.cgi ||?id=20621 -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Martin Renvoize changed: What|Removed |Added Patch complexity|--- |Trivial patch -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Martin Renvoize changed: What|Removed |Added Status|ASSIGNED|Needs Signoff --- Comment #26 from Martin Renvoize --- Back to NSO with fresh patch attached :) -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Martin Renvoize changed: What|Removed |Added Attachment #90850|0 |1 is obsolete|| --- Comment #25 from Martin Renvoize --- Created attachment 90877 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=90877=edit Bug 22741: Make updated_on timezone aware in Koha::Patron -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 M. Tompsett changed: What|Removed |Added Status|Needs Signoff |ASSIGNED CC||mtomp...@hotmail.com --- Comment #24 from M. Tompsett --- Changing to assigned so this patch doesn't suffer the same fate as bug 23151 (signing off the old patch) when I forgot to change the status. :) -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #23 from Martin Renvoize --- Coolios, so just excluding from the action log trigger would do the trick and save us a call to date time.. I'll amend the patch in the morning -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #22 from Tomás Cohen Arazi --- The timezone can be set on connexion time, and we do in Koha/Database:78 -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Martin Renvoize changed: What|Removed |Added Keywords||RM_priority -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Martin Renvoize changed: What|Removed |Added Assignee|koha-b...@lists.koha-commun |martin.renvoize@ptfs-europe |ity.org |.com -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Martin Renvoize changed: What|Removed |Added Status|NEW |Needs Signoff -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #21 from Martin Renvoize --- Created attachment 90850 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=90850=edit Bug 22741: Make updated_on timezone aware in Koha::Patron -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #20 from Martin Renvoize --- Had a quick chat with Kyle and Tomas about this.. We think we should add updated_on to the exclude list for the actionlogs (I don't think it makes much sense to record such a system maintained internal field in the actionlogs change information like this) We also think this highlights that we shouldn't be letting the DB maintain the updated_on field here.. if the server timezone and your Koha instance timezone don't happen to match you're going to get interesting data in the updated_on field. So we're suggesting adding a dt_from_string call in the Koha::Patron store routine itself to make sure we account for koha instance timezones. (there's a precedent for this elsewhere already apparently) -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #19 from Martin Renvoize --- Wow.. this is a fun one.. The updated_on field is updated by a DB level trigger, but our Koha::Object store routine does not return freshly populated Koha::Object data (it uses update_or_insert which only updates the specified fields and does not repopulate from the database). So, in the Koha::Patron->store routine, where we build the actionlogs info we do a comparison between a freshly fetch row from the DB and the cached object data.. if this call to store happens to bridge a 1s boundary we spot a difference between whats in the updated_on in the Koha::Patron object and what's in the database row and record it as a change triggering an actionlog. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #18 from Martin Renvoize --- OK.. so I threw in some debugging and it looks like it's the updated_on field that's throwing us. ok 3 - With BorrowerLogs, one detailed MODIFY action should be logged for the modification. Log 1 { "cardnumber" : { "after" : "TESTCARDNUMBER", "before" : "FAS0pUt3wnZaFD_aJOR" } } Log 2 { "updated_on" : { "after" : "2019-06-20 14:20:18", "before" : "2019-06-20 14:20:19" } } not ok 4 - With BorrowerLogs and TrackLastPatronActivity we should not spam the logs # Failed test 'With BorrowerLogs and TrackLastPatronActivity we should not spam the logs' # at t/db_dependent/Koha/Patrons.t line 1480. # got: '2' # expected: '1' # Looks like you failed 1 test of 4. not ok 31 - BorrowersLog tests -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Martin Renvoize changed: What|Removed |Added CC||martin.renvoize@ptfs-europe ||.com --- Comment #17 from Martin Renvoize --- The code in questions doesn't appear to have any dependancy on timezone where I'm looking.. perhaps we need to add some debugging code around the test at this point.. it seems to be happening more and more frequently on Jenkins. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Jonathan Druart changed: What|Removed |Added Severity|enhancement |normal -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #16 from Jonathan Druart --- (In reply to Jonathan Druart from comment #14) > I can recreate in a devbox if I change the timezone (ie. tz is different > between host and box) It's not that, I can recreate when MySQL server has not been restarted after a tz change. % sudo dpkg-reconfigure tzdata # Pick something different than where you are % prove t/db_dependent/Koha/Patrons.t # Fail! % sudo systemctl restart mysql % prove t/db_dependent/Koha/Patrons.t # Success! It does not explain much why the tests are randomly failing. I have tried to run it with the different tests playing with the timezone config, without success. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #15 from Jonathan Druart --- It was D9 on Node 2 (#742) -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #14 from Jonathan Druart --- I can recreate in a devbox if I change the timezone (ie. tz is different between host and box) -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 --- Comment #13 from Tomás Cohen Arazi --- (In reply to Jonathan Druart from comment #12) > Jenkins is failing randomly with this error: Beware that run was launched with COVERAGE=yes, so a very allow run -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 22741] Koha/Patrons.t is failing randomly on test BorrowerLogs and TrackLastPatronActivity
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22741 Jonathan Druart changed: What|Removed |Added Summary|Second prove of |Koha/Patrons.t is failing |Koha/Patrons.t fails on |randomly on test |test BorrowerLogs and |BorrowerLogs and |TrackLastPatronActivity |TrackLastPatronActivity -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/