Bug 14152

Summary: Check for required dependencies during upgrades
Product: Koha Reporter: Chris Nighswonger <cnighswonger>
Component: Installation and upgrade (web-based installer)Assignee: Chris Nighswonger <cnighswonger>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: dcook, gmcharlt, katrin.fischer, kyle, mtompset, tomascohen
Version: master   
Hardware: All   
OS: All   
See Also: http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14103
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: Bug 14152: Re-check required dependencies during upgrade process
Bug 14152: Re-check required dependencies during upgrade process
[PASSED QA] Bug 14152: Re-check required dependencies during upgrade process

Description Chris Nighswonger 2015-05-05 19:03:27 UTC
When performing upgrades, the code should re-check for required dependencies. This is particularly important for those installations which are not package-based.
Comment 1 Chris Nighswonger 2015-05-05 19:12:07 UTC Comment hidden (obsolete)
Comment 2 Mark Tompsett 2015-05-05 19:49:46 UTC Comment hidden (obsolete)
Comment 3 Mark Tompsett 2015-05-05 20:19:46 UTC
With libxml-libxslt-perl, there is no kaboom, but somehow it let's you proceed.
Once the patch is applied, it is properly caught.

Don't let the test case I gave with PDF::FromHTML stop this from passing QA. :)
Comment 4 Tomás Cohen Arazi 2015-05-05 20:39:11 UTC
Thanks for taking cara of this, Chris.
Comment 5 Mark Tompsett 2015-05-05 20:42:01 UTC
(In reply to M. Tompsett from comment #3)
> With libxml-libxslt-perl, there is no kaboom,

-- the staff client, but OPAC will barf nicely when you try to search for something.

> but somehow it lets you proceed.
> Once the patch is applied, it is properly caught.

YAY! Please Pass QA this. :)
Comment 6 Kyle M Hall 2015-05-08 12:29:28 UTC
Created attachment 38973 [details] [review]
[PASSED QA] Bug 14152: Re-check required dependencies during upgrade process

This code causes the installer to re-check dependencies during the
upgrade process.

Test Plan
---------
1) Log in to staff client
2) Koha Administration -> Global system preferences -> Local
3) Change Version to previous version -- DO NOT HIT SAVE YET!
4) In command line: sudo apt-get purge libpdf-fromhtml-perl
   NOTE: This could be ANY required library. I chose
         PDF::FromHTML, because it has been a thorn in my side.
5) NOW! Hit the 'Save' button.
6) Log in, etc. etc...
   -- Blows up on redirect to log in.
7) In command line, add it back (I had to compile my own so,
   I used sudo dpkg -i /path/to/libpdf-fromhtml-perl...)
8) Apply patch
9) Edit the C4/Installer/PerlDependencies.pm to make
   PDF::FromHTML required. See also bug 14103.
10) Log in to staff client
11) Koha Administration -> Global system preferences -> Local
12) Change Version to previous version -- DO NOT HIT SAVE YET!
13) In command line: sudo apt-get purge libpdf-fromhtml-perl
14) NOW! Hit the 'Save' button.
15) Log in, etc. etc...
16) Once warned you are missing it, add it back at the command line.
17) Click 'Recheck'
    -- Proceeds as expected now.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 7 Tomás Cohen Arazi 2015-05-18 15:14:36 UTC
Patch pushed to master.

Thanks Chris!