Bug 20693 - Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed
Summary: Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed
Status: Pushed to Master
Alias: None
Product: Koha
Classification: Unclassified
Component: Packaging (show other bugs)
Version: master
Hardware: All All
: P5 - low blocker (vote)
Assignee: Mirko Tietgen
QA Contact: Tomás Cohen Arazi
URL:
Whiteboard:
Keywords: dependency
Depends on:
Blocks:
 
Reported: 2018-05-01 21:19 UTC by Mason James
Modified: 2018-05-16 14:56 UTC (History)
5 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:


Attachments
Bug 20693: Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed (1.36 KB, patch)
2018-05-01 21:25 UTC, Mason James
Details | Diff | Splinter Review
Bug 20693: Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed (879 bytes, patch)
2018-05-15 12:01 UTC, Mirko Tietgen
Details | Diff | Splinter Review
Bug 20693: Update control file (1.05 KB, patch)
2018-05-15 12:01 UTC, Mirko Tietgen
Details | Diff | Splinter Review
Bug 20693: Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed (941 bytes, patch)
2018-05-15 16:59 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review
Bug 20693: Update control file (1.11 KB, patch)
2018-05-15 16:59 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Mason James 2018-05-01 21:19:36 UTC
more info to come...
Comment 1 Mason James 2018-05-01 21:25:44 UTC
Created attachment 74958 [details] [review]
Bug 20693: Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed

to test patch...

 1/ build koha package from souce, install package

 2/ test plack, see following error...

   Error while loading /etc/koha/plack.psgi: Can't locate CGI/Emulate/PSGI.pm
   in @INC (you may need to install the CGI::Emulate::PSGI module)

 3/ apply patch

 4/ build koha package from souce, install package

 5/ test plack, see no error and observe plack is working
Comment 2 Mason James 2018-05-01 21:39:22 UTC
(In reply to Mason James from comment #1)
> Created attachment 74958 [details] [review] [review]
> Bug 20693: Plack fails, because 'libcgi-emulate-psgi-perl' package is not
> installed
> 
> to test patch...
> 
>  1/ build koha package from souce, install package
> 
>  2/ test plack, see following error...
> 
>    Error while loading /etc/koha/plack.psgi: Can't locate CGI/Emulate/PSGI.pm
>    in @INC (you may need to install the CGI::Emulate::PSGI module)
> 
>  3/ apply patch
> 
>  4/ build koha package from souce, install package
> 
>  5/ test plack, see no error and observe plack is working


aah, false alarm... 

# aptitude why  libcgi-emulate-psgi-perl
i   koha-common   Depends    starman
i A starman       Depends    libplack-perl
i A libplack-perl Recommends libcgi-emulate-psgi-perl
Comment 3 David Cook 2018-05-02 03:11:06 UTC
(In reply to Mason James from comment #2)
> aah, false alarm... 
> 
> # aptitude why  libcgi-emulate-psgi-perl
> i   koha-common   Depends    starman
> i A starman       Depends    libplack-perl
> i A libplack-perl Recommends libcgi-emulate-psgi-perl

That still seems like a problem to me? If it's not in the PerlDependencies.pm, then any non-package install will run into dependency problems?
Comment 4 Jonathan Druart 2018-05-03 13:41:26 UTC
Reopening:
% aptitude why libcgi-emulate-psgi-perl
Unable to find a reason to install libcgi-emulate-psgi-perl.

% more /etc/debian_version
8.10


With 9.1 I get:
% aptitude why libcgi-emulate-psgi-perl
i   libplack-middleware-fixmissingbodyinredirect-perl Depends    libplack-perl
i A libplack-perl                                     Recommends libcgi-emulate-psgi-perl
Comment 5 Jonathan Druart 2018-05-03 13:51:15 UTC
From Magnuse on IRC, Ubuntu 16.04 returns:

i   libcgi-compile-perl Recommends libcgi-emulate-psgi-per
Comment 6 Mirko Tietgen 2018-05-15 11:09:00 UTC
Mason: What OS did you install on, and does it have special apt configuration? The package is recommended by a dependency, it should be installed unless you changed the apt config to ignore recommended packages.

Jonathan: Is Koha actually installed on the 8.10 system you tried? I get on 8.10

>aptitude why libcgi-emulate-psgi-perl
>i   koha-common   Depends    starman                 
>i A starman       Depends    libplack-perl           
>i A libplack-perl Recommends libcgi-emulate-psgi-perl

Anyway, recommended packages are installed by default in Debian. This can be disabled though, eg. if you are very low on disk space. If Koha relies on libcgi-emulate-psgi-perl to work, it should be a direct dependency.

The patch is not the way to do it. CGI::Emulate::PSGI should added to PerlDependencies.pm instead and I will add an updated control file.

Plack is a dependency of starman, both for Debian packages and on CPAN, adding Plack to PerlDependencies.pm is not necessary.
Comment 7 Mirko Tietgen 2018-05-15 12:01:29 UTC
Created attachment 75327 [details] [review]
Bug 20693: Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed

Add CGI::Emulate::PSGI to PerlDependencies.pm

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Comment 8 Mirko Tietgen 2018-05-15 12:01:42 UTC
Created attachment 75328 [details] [review]
Bug 20693: Update control file

Auto-generated file.

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Comment 9 Mirko Tietgen 2018-05-15 12:06:13 UTC
I chose the version number available in Jessie.

Not really anything to test here, forwarding to QA. Take a look at the first patch to see it makes sense, you can see the effect in the second patch.
Comment 10 Tomás Cohen Arazi 2018-05-15 16:59:47 UTC
Created attachment 75338 [details] [review]
Bug 20693: Plack fails, because 'libcgi-emulate-psgi-perl' package is not installed

Add CGI::Emulate::PSGI to PerlDependencies.pm

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 11 Tomás Cohen Arazi 2018-05-15 16:59:54 UTC
Created attachment 75339 [details] [review]
Bug 20693: Update control file

Auto-generated file.

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 12 Jonathan Druart 2018-05-15 18:04:22 UTC
Pushed to master for 18.05, thanks to everybody involved!