[Koha-bugs] [Bug 14036] "Date::Calc::Add_Delta_YM(): not a valid date" error when accessing subscription detail

2019-12-11 Thread bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Jonathan Druart  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|Failed QA   |RESOLVED

--- Comment #29 from Jonathan Druart  
---
Date formatting is enforced template-side. This is certainly no longer valid.
Closing, please reopen if still valid.

-- 
You are receiving this mail because:
You are watching all bug changes.
___
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
https://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 14036] "Date::Calc::Add_Delta_YM(): not a valid date" error when accessing subscription detail

2016-01-13 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Janet McGowan  changed:

   What|Removed |Added

 CC||janet.mcgowan@ptfs-europe.c
   ||om

-- 
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 14036] "Date::Calc::Add_Delta_YM(): not a valid date" error when accessing subscription detail

2015-12-24 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Marc Véron  changed:

   What|Removed |Added

 CC||ve...@veron.ch

--- Comment #28 from Marc Véron  ---
Is this bug still valid?

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-05-19 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #26 from M. Tompsett mtomp...@hotmail.com ---
(In reply to Katrin Fischer from comment #25)
 If you or Rolando can tell me how to alter the data in order to make the
 problem appear that would work for me for now.

Haven't triggered the exact problem, but a similar one:
1) Set up stuff.
a) Home - Acquisitions
b) Add Vendor
c) Add Budget
d) Add Fund for that Budget
   -- not all these steps may be necessary, but they are a good idea.
2) Home - Serials
3) New Subscription
4) Fill in first page nicely, click Next
5) Fill in second page nicely, click 'Test prediction pattern'
6) EVIL STEP: Change the publication date to 00/00/
7) Click 'Save'
   -- KABOOM!

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-05-19 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #27 from M. Tompsett mtomp...@hotmail.com ---
(In reply to Katrin Fischer from comment #25)
 If you or Rolando can tell me how to alter the data in order to make the
 problem appear that would work for me for now.

I have looked further, and believe the only way to trigger this problem is bad
data.

However, as I just posted, there are validation failures at the template level
which end up calling these functions in exploding ways.

GetNextSeq and GetNextDate in C4::Serials both call GetFictiveIssueNumber, and
it is the second parameter as -00-00 which causes the explosion.

This is easy to trigger as tests apart from the interface.

However, some validation on the template pages actually prevents such
explosions. Though, as demonstrated in comment #26, there needs to be an
improvement in validations done.

Would adding those validations to solve comment #26 be sufficient to pass all
of this?

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #18 from Katrin Fischer katrin.fisc...@bsz-bw.de ---
Mark, this is what I did.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #19 from M. Tompsett mtomp...@hotmail.com ---
mtompset@debian:~/kohaclone$ git reset --hard origin/master
HEAD is now at 381959a Bug 13109: Serial failure for received and general
viewin 
   g.
mtompset@debian:~/kohaclone$ git bz apply 14036
Bug 14036 - Date::Calc::Add_Delta_YM(): not a valid date error when accessing

subscription detail

38467 - Bug 14036 - GetNextDate.t lacking test cases.
38468 - Bug 14036: Date::Calc::Add_Delta_YM(): not a valid date error when
acc
essing subscription detail

Apply? [(y)es, (n)o, (i)nteractive] i
Applying: Bug 14036 - GetNextDate.t lacking test cases.
mtompset@debian:~/kohaclone$ prove -v t/db_dependent/Serials/GetNextDate.t
t/db_dependent/Serials/GetNextDate.t ..
1..88
Date::Calc::Delta_Days(): not a valid date at
/home/mtompset/kohaclone/C4/Serial 
   s.pm line 2345.
# Looks like your test exited with 255 before it could output anything.
Dubious, test returned 255 (wstat 65280, 0xff00)
Failed 88/88 subtests

Test Summary Report
---
t/db_dependent/Serials/GetNextDate.t (Wstat: 65280 Tests: 0 Failed: 0)
  Non-zero exit status: 255
  Parse errors: Bad plan.  You planned 88 tests but ran 0.
Files=1, Tests=0,  0 wallclock secs ( 0.02 usr  0.00 sys +  0.31 cusr  0.05
csys   
  =  0.38 CPU)
Result: FAIL
mtompset@debian:~/kohaclone$ git bz apply 14036
Bug 14036 - Date::Calc::Add_Delta_YM(): not a valid date error when accessing

subscription detail

38467 - Bug 14036 - GetNextDate.t lacking test cases.
38468 - Bug 14036: Date::Calc::Add_Delta_YM(): not a valid date error when
acc
essing subscription detail

Apply? [(y)es, (n)o, (i)nteractive] i
Applying: Bug 14036: Date::Calc::Add_Delta_YM(): not a valid date error when
a
ccessing subscription detail
mtompset@debian:~/kohaclone$ prove -v t/db_dependent/Serials/GetNextDate.t
t/db_dependent/Serials/GetNextDate.t ..
1..88
ok 1 - -00-00 is an expected undef date.
ok 2 - -99-99 is an expected undef date.
[SNIP]
ok 88
ok
All tests successful.
Files=1, Tests=88,  1 wallclock secs ( 0.02 usr  0.00 sys +  0.37 cusr  0.00
csy
s =  0.39 CPU)
Result: PASS

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #22 from M. Tompsett mtomp...@hotmail.com ---
(In reply to Katrin Fischer from comment #21)
 Can you still reproduce the issue in the GUI on current master?
 What does your entry in subscription and serial look like?

I will attempt to replicate it in the interface later, but I did not use the
interface in my testing.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

 Status|Failed QA   |Signed Off

--- Comment #17 from M. Tompsett mtomp...@hotmail.com ---
Please see the test plan in comment #12, Katrin.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #20 from M. Tompsett mtomp...@hotmail.com ---
BTW, I have no subscriptions before testing.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #21 from Katrin Fischer katrin.fisc...@bsz-bw.de ---
Can you still reproduce the issue in the GUI on current master?
What does your entry in subscription and serial look like?

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Katrin Fischer katrin.fisc...@bsz-bw.de changed:

   What|Removed |Added

 Status|Signed Off  |Failed QA

--- Comment #23 from Katrin Fischer katrin.fisc...@bsz-bw.de ---
Please provide steps to make the problem visible outside of the tests.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #25 from Katrin Fischer katrin.fisc...@bsz-bw.de ---
If you or Rolando can tell me how to alter the data in order to make the
problem appear that would work for me for now.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-29 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #24 from M. Tompsett mtomp...@hotmail.com ---
(In reply to Katrin Fischer from comment #23)
 Please provide steps to make the problem visible outside of the tests.

I'll work on it, but it make require setting up bad data in an earlier version,
upgrading, and then trying to edit.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-28 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Katrin Fischer katrin.fisc...@bsz-bw.de changed:

   What|Removed |Added

 CC||katrin.fisc...@bsz-bw.de
 Status|Signed Off  |Failed QA

--- Comment #16 from Katrin Fischer katrin.fisc...@bsz-bw.de ---
I am sorry, but I can't reproduce the problem on current master. I tried with
an irregular subscription that will leave planneddate and publisheddateempty
and I manually changed the database values to -00-00 for both. 

Please include a test plan.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-24 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Rolando Isidoro rolando.isid...@gmail.com changed:

   What|Removed |Added

 Status|Needs Signoff   |Signed Off

--- Comment #15 from Rolando Isidoro rolando.isid...@gmail.com ---
Signed off and added bug 13109 dependency.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-24 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Rolando Isidoro rolando.isid...@gmail.com changed:

   What|Removed |Added

 Depends on||13109

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

  Attachment #38399|0   |1
is obsolete||

--- Comment #7 from M. Tompsett mtomp...@hotmail.com ---
Created attachment 38459
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38459action=edit
Bug 14036: Date::Calc::Add_Delta_YM(): not a valid date error when accessing
subscription detail

When accessing the subscription detail page for a serial with unknown Planned
date and/or Published date the following error occurs:

subscription-detail.pl: Date::Calc::PP::Add_Delta_YM():
Date::Calc::Add_Delta_YM(): not a valid date at
/usr/share/koha/lib/C4/Serials.pm line 2607
 at /usr/share/perl/5.14/CGI/Carp.pm line 379
CGI::Carp::realdie('[Tue Apr 21 14:43:06 2015] subscription-detail.pl:
Date::Calc...') called at /usr/share/perl/5.14/CGI/Carp.pm line 475
CGI::Carp::die('Date::Calc::PP::Add_Delta_YM(): Date::Calc::Add_Delta_YM():
n...') called at /usr/share/perl5/Carp/Clan.pm line 225
Carp::Clan::__ANON__('Date::Calc::Add_Delta_YM(): not a valid date') called
at /usr/share/perl5/Date/Calc/PP.pm line 408
Date::Calc::PP::DATECALC_DATE_ERROR('Add_Delta_YM') called at
/usr/share/perl5/Date/Calc/PP.pm line 817
Date::Calc::PP::Add_Delta_YM(, 00, 00, 0, 1) called at
/usr/share/koha/lib/C4/Serials.pm line 2607
C4::Serials::GetNextDate('HASH(0x6244de0)', '-00-00') called at
/usr/share/koha/lib/C4/Serials.pm line 2382
C4::Serials::abouttoexpire(525) called at
/usr/share/koha/intranet/cgi-bin/serials/subscription-detail.pl line 104

This patch adds validation to prevent the error from occurring.

Test plan

Before applying the patch

1 - In the intranet interface pick a serial biblio record with a subscription
with empty Planned date and/or Published date;
2 - Click the Subscription(s) tab on the left side;
3 - Click the subscription title link to view it's detail;

The error should occur at this point.

Apply the patch, follow the 3 steps from the test plan and the error shouldn't
show up anymore.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com 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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

  Attachment #38465|0   |1
is obsolete||

--- Comment #12 from M. Tompsett mtomp...@hotmail.com ---
Created attachment 38467
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38467action=edit
Bug 14036 - GetNextDate.t lacking test cases.

Two test cases were added to improve testing. This catches the
problem encountered by Rolando Isidoro.

TEST PLAN
-
1) Apply this test patch first.
2) prove t/db_dependent/Serials/GetNextDate.t
   -- this should bomb horribly.
3) Apply the other patch.
4) prove t/db_dependent/Serials/GetNextDate.t
   -- this should succeed.
5) koha qa test tools

Signed-off-by: Mark Tompsett mtomp...@hotmail.com

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #8 from M. Tompsett mtomp...@hotmail.com ---
Created attachment 38461
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38461action=edit
Bug 14036 - GetNextDate.t lacking test cases.

Two test cases were added to improve testing. This catches the
problem encountered by Rolando Isidoro.

TEST PLAN
-
1) Apply this test patch first.
2) prove t/db_dependent/Serials/GetNextDate.t
   -- this should bomb horribly.
3) Apply the other patch.
4) prove t/db_dependent/Serials/GetNextDate.t
   -- this should succeed.
5) koha qa test tools

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

 Status|REOPENED|ASSIGNED

--- Comment #6 from M. Tompsett mtomp...@hotmail.com ---
(In reply to Rolando Isidoro from comment #5)
 As for the patch I submitted, both validation are required, the check_date
 one you mentioned as not being needed is mandatory to solve the problem as
 the error occurs in the GetNextDate function.
 
 I'm reverting the status to 'REOPENED', can you please take a second look at
 it?

GetNextDate receives a parameter $publisheddate (which it may or may not be).
As far as I can tell, it is either:
NULL, -00-00 (MySQL badness), or a valid MySQL date (-MM-DD).
I have confirmed that -00-00 triggers an error. I'll be attaching tests
that were missing.

Please remove the first part of this patch, as 13109 resolves that issue.
Perhaps add a dependency?

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

  Attachment #38459|0   |1
is obsolete||

--- Comment #11 from M. Tompsett mtomp...@hotmail.com ---
Created attachment 38466
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38466action=edit
Bug 14036: Date::Calc::Add_Delta_YM(): not a valid date error when accessing
subscription detail

When accessing the subscription detail page for a serial with unknown Planned
date and/or Published date the following error occurs:

subscription-detail.pl: Date::Calc::PP::Add_Delta_YM():
Date::Calc::Add_Delta_YM(): not a valid date at
/usr/share/koha/lib/C4/Serials.pm line 2607
 at /usr/share/perl/5.14/CGI/Carp.pm line 379
CGI::Carp::realdie('[Tue Apr 21 14:43:06 2015] subscription-detail.pl:
Date::Calc...') called at /usr/share/perl/5.14/CGI/Carp.pm line 475
CGI::Carp::die('Date::Calc::PP::Add_Delta_YM(): Date::Calc::Add_Delta_YM():
n...') called at /usr/share/perl5/Carp/Clan.pm line 225
Carp::Clan::__ANON__('Date::Calc::Add_Delta_YM(): not a valid date') called
at /usr/share/perl5/Date/Calc/PP.pm line 408
Date::Calc::PP::DATECALC_DATE_ERROR('Add_Delta_YM') called at
/usr/share/perl5/Date/Calc/PP.pm line 817
Date::Calc::PP::Add_Delta_YM(, 00, 00, 0, 1) called at
/usr/share/koha/lib/C4/Serials.pm line 2607
C4::Serials::GetNextDate('HASH(0x6244de0)', '-00-00') called at
/usr/share/koha/lib/C4/Serials.pm line 2382
C4::Serials::abouttoexpire(525) called at
/usr/share/koha/intranet/cgi-bin/serials/subscription-detail.pl line 104

This patch adds validation to prevent the error from occurring.
Follow the test plan in the subsequent patch.

This patch deals solely with this.
 C4::Serials::GetNextDate('HASH(0x6244de0)', '-00-00') called at 
 /usr/share/koha/lib/C4/Serials.pm line 2382

abouttoexpire issues exist, but may be resolved by applying bug 13109 first.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

 Status|ASSIGNED|Needs Signoff

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #14 from M. Tompsett mtomp...@hotmail.com ---
Leaving as 'Needs Signoff' since I shouldn't be signing off on my own tests.
Feel free to sign off, Rolando.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

  Attachment #38461|0   |1
is obsolete||

--- Comment #9 from M. Tompsett mtomp...@hotmail.com ---
Created attachment 38464
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38464action=edit
Bug 14036 - GetNextDate.t lacking test cases.

Two test cases were added to improve testing. This catches the
problem encountered by Rolando Isidoro.

TEST PLAN
-
1) Apply this test patch first.
2) prove t/db_dependent/Serials/GetNextDate.t
   -- this should bomb horribly.
3) Apply the other patch.
4) prove t/db_dependent/Serials/GetNextDate.t
   -- this should succeed.
5) koha qa test tools

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

  Attachment #38464|0   |1
is obsolete||

--- Comment #10 from M. Tompsett mtomp...@hotmail.com ---
Created attachment 38465
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38465action=edit
Bug 14036 - GetNextDate.t lacking test cases.

Two test cases were added to improve testing. This catches the
problem encountered by Rolando Isidoro.

TEST PLAN
-
1) Apply this test patch first.
2) prove t/db_dependent/Serials/GetNextDate.t
   -- this should bomb horribly.
3) Apply the other patch.
4) prove t/db_dependent/Serials/GetNextDate.t
   -- this should succeed.
5) koha qa test tools

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

  Attachment #38466|0   |1
is obsolete||

--- Comment #13 from M. Tompsett mtomp...@hotmail.com ---
Created attachment 38468
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38468action=edit
Bug 14036: Date::Calc::Add_Delta_YM(): not a valid date error when accessing
subscription detail

When accessing the subscription detail page for a serial with unknown Planned
date and/or Published date the following error occurs:

subscription-detail.pl: Date::Calc::PP::Add_Delta_YM():
Date::Calc::Add_Delta_YM(): not a valid date at
/usr/share/koha/lib/C4/Serials.pm line 2607
 at /usr/share/perl/5.14/CGI/Carp.pm line 379
CGI::Carp::realdie('[Tue Apr 21 14:43:06 2015] subscription-detail.pl:
Date::Calc...') called at /usr/share/perl/5.14/CGI/Carp.pm line 475
CGI::Carp::die('Date::Calc::PP::Add_Delta_YM(): Date::Calc::Add_Delta_YM():
n...') called at /usr/share/perl5/Carp/Clan.pm line 225
Carp::Clan::__ANON__('Date::Calc::Add_Delta_YM(): not a valid date') called
at /usr/share/perl5/Date/Calc/PP.pm line 408
Date::Calc::PP::DATECALC_DATE_ERROR('Add_Delta_YM') called at
/usr/share/perl5/Date/Calc/PP.pm line 817
Date::Calc::PP::Add_Delta_YM(, 00, 00, 0, 1) called at
/usr/share/koha/lib/C4/Serials.pm line 2607
C4::Serials::GetNextDate('HASH(0x6244de0)', '-00-00') called at
/usr/share/koha/lib/C4/Serials.pm line 2382
C4::Serials::abouttoexpire(525) called at
/usr/share/koha/intranet/cgi-bin/serials/subscription-detail.pl line 104

This patch adds validation to prevent the error from occurring.
Follow the test plan in the subsequent patch.

This patch deals solely with this.
 C4::Serials::GetNextDate('HASH(0x6244de0)', '-00-00') called at 
 /usr/share/koha/lib/C4/Serials.pm line 2382

abouttoexpire issues exist, but may be resolved by applying bug 13109 first.

Signed-off-by: Mark Tompsett mtomp...@hotmail.com

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Jonathan Druart jonathan.dru...@biblibre.com changed:

   What|Removed |Added

 CC||jonathan.dru...@biblibre.co
   ||m

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Rolando Isidoro rolando.isid...@gmail.com changed:

   What|Removed |Added

Version|3.18|master

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Rolando Isidoro rolando.isid...@gmail.com changed:

   What|Removed |Added

 Status|NEW |Needs Signoff
   Assignee|koha-b...@lists.koha-commun |rolando.isid...@gmail.com
   |ity.org |

--- Comment #1 from Rolando Isidoro rolando.isid...@gmail.com ---
Created attachment 38399
  --
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38399action=edit
Patch that adds date validation

This patch adds validation to prevent the error from occurring.

Test plan

Before applying the patch

1 - In the intranet interface pick a serial biblio record with a subscription
with empty Planned date and/or Published date;
2 - Click the Subscription(s) tab on the left side;
3 - Click the subscription title link to view it's detail;

The error should occur at this point.

Apply the patch, follow the 3 steps from the test plan and the error shouldn't
show up anymore.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

Rolando Isidoro rolando.isid...@gmail.com changed:

   What|Removed |Added

 Resolution|DUPLICATE   |---
 Status|RESOLVED|REOPENED

--- Comment #5 from Rolando Isidoro rolando.isid...@gmail.com ---
Hi M. Tompsett, the bugs are very similar indeed but this problem occurs for
'planneddate' while #13109 refers to 'startdate' or 'enddate'.

As for the patch I submitted, both validation are required, the check_date one
you mentioned as not being needed is mandatory to solve the problem as the
error occurs in the GetNextDate function.

I'm reverting the status to 'REOPENED', can you please take a second look at
it?

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #3 from M. Tompsett mtomp...@hotmail.com ---
Comment on attachment 38399
  -- http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38399
Patch that adds date validation

Review of attachment 38399:
 -- 
(http://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.htmlbug=14036attachment=38399)
-

::: C4/Serials.pm
@@ +2386,4 @@
  if ($freqdata-{'unit'}) {
  my ( $year, $month, $day ) = split /-/, $publisheddate;
  
 +return unless check_date($year, $month, $day);

Not necessary, because:
return unless $subscription and $publisheddate;

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

--- Comment #2 from M. Tompsett mtomp...@hotmail.com ---
Comment on attachment 38399
  -- http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=38399
Patch that adds date validation

Review of attachment 38399:
 -- 
(http://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.htmlbug=14036attachment=38399)
-

::: C4/Serials.pm
@@ +2246,5 @@
  my $expirationdate = GetExpirationDate($subscriptionid);
  my ($res) = $dbh-selectrow_array('select max(planneddate) from 
 serial where subscriptionid = ?', undef, $subscriptionid);
  my $nextdate = GetNextDate($subscription, $res);
 +
 +return unless ($nextdate and $expirationdate);

See also bug 13109.

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

   See Also||http://bugs.koha-community.
   ||org/bugzilla3/show_bug.cgi?
   ||id=13109
 CC||mtomp...@hotmail.com

-- 
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 14036] Date::Calc::Add_Delta_YM(): not a valid date error when accessing subscription detail

2015-04-23 Thread bugzilla-daemon
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14036

M. Tompsett mtomp...@hotmail.com changed:

   What|Removed |Added

 Status|Needs Signoff   |RESOLVED
 Resolution|--- |DUPLICATE

--- Comment #4 from M. Tompsett mtomp...@hotmail.com ---


*** This bug has been marked as a duplicate of bug 13109 ***

-- 
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/