Hi Neil!

On Thu, Dec 7, 2017 at 6:48 AM, Neil Redgate <nredg...@ndres.co.uk> wrote:
> On Wed, 2017-12-06 at 12:46 -0500, Robert J. Clay wrote:
>
> As a reminder;  the title of the bug you opened was changed to the
> following to better reflect the issue with the sql-ledger package:
>
> sql-ledger: Can't locate bin/mozilla/login.pl in @INC
>
> Thank you for changing the title.
>
>> On Sun, Jul 30, 2017 at 4:09 AM, Neil Redgate <nredg...@ndres.co.uk> wrote:
>
> ....
>> I have contacted the developer of sql-ledger and he has given me a couple of
>> suggestions - which I hope to look into later today.
>
>
>    And did any of those suggestions help?
>
>    Since there is going to be the same issue with any of the more
> recent versions of Perl, I've been wondering if he was going to
> release a new version that fixed the issue...
>
> I contacted the developer, and he offered the following advice -
>
>
> SQL-Ledger code is generic. There is an
>
> eval  { require "sql-ledger.conf"; };
>
> which may call @INC.
>
> comment the line and see if it works.
>
>
> Unfortunately there was no improvement, I did the following -
>
> A) commented out the eval line in admin.pl and login.pl only
> launched admin and login pages separately.
> Both returned 500: Internal Server Error message
> My browser's debugging page states this page "failed to load the resource
> 'favicon.ico' (http://localhost/faviocn.ico)
> favicon.ico is only mentioned in the admin.pl and login.pl files in the
> directory /bin : $form->{favicon} = "favicon.ico";
> In these files, the line immediately preceding it is $form->{stylesheet} =
> "sql-ledger.css";

   That quite likely was due to not being able to find it, which is
part of the problem when the code (like in SQL-Ledgers) assumes that
the 'current directory' is included in the search path in @INC.


>
> B) commented out the eval line in all 26 .pl files in the parent directory
> (including admin and login)
> The same error result occurred: 500: Internal Server Error message
> My browser's debugging page states this page "failed to load the resource"
> 'admin.pl' or 'login.pl' depending on which action I took.

   Possibly the same issue, with it not being able found the scripts...

>
> On my debian system, when perl5.24 was installed, there was a temporary
> workaround to allow apache2 and postgresql to work with perl.
> This involved commenting out the only line (below) in the file
> /etc/perl/sitecustomize.pl -
>
> pop @INC if $INC[-1] eq '.' and !$ENV{PERL_USE_UNSAFE_INC};
>
> If this line was left uncommented, postgresql failed to work through a web
> browser and gave the same message - 500 Internal Server Error
> I understand that perl 5.26 removes the insecurity associated with '.'

   Yes, with Perl 5.26 they dropped having the current directory (".")
in the @INC array altogether, as well as dropping the site customize
line (or even checking for it). that was an option to add it back in
the a sys admin wanted to.


> While investigating the perl-postgresql connection, I came across a bug
> report in debian that the current postgresql 9.6 version could not be
> built/complied against perl 5.26.
> A solution has been targeted for release in "August"
>
> I do not know if this has been achieved?

 I do believe it was  (and since then made it to Testing...) but as I
mentioned then and Gregor also confirmed, that is not something that
was relevant to this issue with SQL-Ledger.


> .... Hence, waiting to try again, with a fresh
> testing install and install/configuration of sql-ledger.

   I am most interested in how that goes for you, especially if you
add the same kind of block of code that I did, with the appropriate
path for your install of SQL-Ledger of course.  (Although I'm mostly
interested in the package, and in fact am working on adopting it, I
may try a manual install of a newer version as well...)


> I can access phppgadmin; pgadmin3; phpmyadmin, so I do not think there is a
> problem with a webbrowser interface, postgresql or php

  No, I agree; it's not an issue at the browser end.


> However there is a problem with this - when I try and backup (save to file
> or email) I get the error message -
>
> Wide character in print at SL/AM.pm line 2012 (this is repeated 4 times)
> and a screen of "random text" in lines and no spaces, but beginning with
> Content-Type: application/file: Content-Disposition: attachment;
> filename=ndres-3.2.4-20171207.sql.gz........
>
> I have never had this issue when I was able to run 3.24 on my PC
> Have you come across this problem in your experience with sql-ledger?

  No, I haven't;  at least not yet...   Is SQL-Ledger utf-8 safe?
IIRC, postgresql defaults to using utf-8 in it's more recent versions
in new installs...



> Once I have a fresh testing installed, I will let you know how I fared with
> installing and setting up of sql-ledger and whether I can launch the
> package.

> I trust this is acceptable to you?

   Of course it is and I am very interested in how it goes for you.



-- 
Robert J. Clay
rjc...@gmail.com

Reply via email to