open-ils.storage fails to start with perl >= 5.24
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Evergreen |
Fix Released
|
High
|
Unassigned |
Bug Description
Platform: Gentoo Hardened
OpenSRF: Master
Evergreen: 2.12.4
PostgreSQL: 9.5.7
Perl: 5.24.1
The open-ils.storage OpenSRF module fails to start when using perl >= 5.24.
Logs report the following error:
[2017-07-31 10:28:57] OpenSRF Listener [open-ils.storage] [ERR :18779:
[2017-07-31 10:28:57] OpenSRF Listener [open-ils.storage] [ERR :18779:EX.pm:66:] Exception: OpenSRF::EX::ERROR 2017-07-31T10:28:57 OpenILS:
[2017-07-31 10:28:57] OpenSRF Listener [open-ils.storage] [ERR :18779:
[2017-07-31 10:28:57] OpenSRF Listener [open-ils.storage] [ERR :18779:EX.pm:66:] Exception: OpenSRF::EX::PANIC 2017-07-31T10:28:57 OpenILS:
I found the following extra information with a quick search (though I couldn't find the original source):
"Experimental %s on scalar is now forbidden (F) An experimental feature added in Perl 5.14 allowed each, keys, push, pop, shift, splice, unshift, and values to be called with a scalar argument. This experiment is considered unsuccessful, and has been removed. The postderef feature may meet your needs better."
Changed in evergreen: | |
milestone: | none → 2.12.5 |
status: | New → Confirmed |
importance: | Undecided → High |
assignee: | Mike Rylander (mrylander) → Galen Charlton (gmc) |
Changed in evergreen: | |
status: | Fix Committed → Fix Released |
Ah, well, at least that's a simple one to fix:
--- a/Open- ILS/src/ perlmods/ lib/OpenILS/ Application/ Storage/ Publisher/ metabib. pm ILS/src/ perlmods/ lib/OpenILS/ Application/ Storage/ Publisher/ metabib. pm fts_wrapper { org_unit- >search( { parent_ou => undef } )->next;
+++ b/Open-
@@ -3186,7 +3186,7 @@ sub query_parser_
$top_org ||= actor::
my $base_query = $args{query} || ''; keys($args{ searches} ))) { searches} ) && scalar( keys(%{ $args{searches} }))) {
$log- >debug( "Constructing QueryParser query from staged search hash ...", DEBUG);
$ log->debug( " --> staged search key: $sclass --> term: $args{searches} {$sclass} {term}" , DEBUG);
- if (scalar(
+ if (ref($args{
for my $sclass ( keys %{$args{searches}} ) {
Thanks, Graham!
I'll push a branch soon.