[Bug 8190] New: Koha does not have a logging module
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Priority: P5 - low Change sponsored?: --- Bug ID: 8190 Assignee: gmcharlt@gmail.com Summary: Koha does not have a logging module Severity: enhancement Classification: Unclassified OS: All Reporter: jonathan.druart@biblibre.com Hardware: All Status: NEW Version: unspecified Component: Architecture, internals, and plumbing Product: Koha I would be great to specify a log level (to differentiate production and development environment for example). -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|gmcharlt@gmail.com |jonathan.druart@biblibre.co | |m -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #1 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 9921 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=9921&action=edit Bug 8190: C4::Logger, Logging module How it works: use C4::Logger qw/$log/; $log = C4::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable LOG in your virtual host: SetEnv LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |In Discussion -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Dobrica Pavlinusic <dpavlin@rot13.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dpavlin@rot13.org --- Comment #2 from Dobrica Pavlinusic <dpavlin@rot13.org> --- Should we also wrap warn(s) to emit debug output like this? $SIG{__WARN__} = sub { C4::Logger->new->debug( @_ ); } Right now every warn in code makes patch fail QA (I know that first hand ;-) and it seems to me it's easier to just put warn instead of C4::Logger->new->debug( "this used to be warn" ); -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|In Discussion |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #3 from Jared Camins-Esakov <jcamins@cpbibliography.com> --- I had a thought about this. Would it be possible to have the logging module serve dual purposes, for both debug logging and for action_logs logging? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |chris@bigballofwax.co.nz --- Comment #4 from Chris Cormack <chris@bigballofwax.co.nz> --- Perhaps also take a look at Log4Perl http://search.cpan.org/~mschilli/Log-Log4perl-1.37/lib/Log/Log4perl.pm -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #9921|0 |1 is obsolete| | --- Comment #5 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 10996 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=10996&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable LOG in your virtual host: SetEnv LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Move C4::Logger to Koha::Utils::Logger -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #6 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to comment #2)
Right now every warn in code makes patch fail QA (I know that first hand ;-) and it seems to me it's easier to just put warn instead of
C4::Logger->new->debug( "this used to be warn" );
I had a thought about this. Would it be possible to have the logging module serve dual purposes, for both debug logging and for action_logs logging? Hum, I had already this idea and I think it is not a good one :) First, it would take a lot of disk space. To process the results, we will have to grep a huge number of lines of data. Then, we oblige users to keep all of their Koha log. We will depend of an other
Just $log->debug("my debug message"); In fact, a lot of warn in Koha are not a debug message. I think each warn have to be replaced with his right level. But your are right, we can have a thought about this. (A simple method is to map into your favorite editor the string "warn" with a call to the debug method of Logger ;) (In reply to comment #3) source of data (currently, we only have the DB). Imo processing time would be very increased. (In reply to comment #4)
Perhaps also take a look at Log4Perl http://search.cpan.org/~mschilli/Log-Log4perl-1.37/lib/Log/Log4perl.pm I had a look at several perl logging modules. My conclusion is LogLite is the easier for what we need into Koha. In any case, since we have a Koha::Utils::Logger used in Koha, it is easy to replace this module with another ;)
-- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |julian.maurice@biblibre.com -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #10996|0 |1 is obsolete| | --- Comment #7 from Mason James <mtj@kohaaloha.com> --- Created attachment 12257 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12257&action=edit Bug 8190: C4::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable LOG in your virtual host: SetEnv LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off CC| |mtj@kohaaloha.com --- Comment #8 from Mason James <mtj@kohaaloha.com> ---
Signed-off-by: Mason James <mtj@kohaaloha.com>
1/installed loglite package $ sudo apt-get install liblog-loglite-perl 2/ ran test successfully $ LOG="/tmp/t1.log" perl t/Logger.t 1..15 ok 1 - use Koha::Utils::Logger; ok 2 - Check LogLevel syspref ok 3 - Check $log is undef ok 4 - Check $log is not undef ok 5 - check error string with level 3 ok 6 - check normal string with level 3 ok 7 - check error string with level 5 ok 8 - check normal string with level 5 ok 9 - check calledby string with level 5 ok 10 - check WARN string with dump ok 11 - check VAR1 string with dump ok 12 - check values aaaaa string with dump ok 13 - check log level return ok 14 - check error string with level 3 ok 15 - check normal string with level 3 Jonathon. looks good, signing-off... -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #9 from Mason James <mtj@kohaaloha.com> ---
Jonathan. looks good, signing-off...
but, perlcritic errors... Koha/Utils/Logger.pm FAIL Loop iterator is not lexical at line 168, column 5. See page 108 of PBP. t/Logger.t FAIL Two-argument "open" used at line 56, column 1. See page 207 of PBP. Bareword file handle opened at line 80, column 5. See pages 202,204 of PBP. Bareword file handle opened at line 69, column 5. See pages 202,204 of PBP. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #10 from Mason James <mtj@kohaaloha.com> ---
Prerequisite: - set an environment variable LOG in your virtual host: SetEnv LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file
hmm, just a little suggestion, too... change SetEnv from LOG, to KOHA_LOG? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12257|0 |1 is obsolete| | --- Comment #11 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 12264 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12264&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #12 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 12265 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12265&action=edit Bug 8190: Followup Logger: FIX perlcritic -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Needs Signoff --- Comment #13 from Jonathan Druart <jonathan.druart@biblibre.com> --- First patch replace LOG with KOHA_LOG Second patch fixes perlcritic errors -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12265|0 |1 is obsolete| | --- Comment #14 from Mason James <mtj@kohaaloha.com> --- Created attachment 12270 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12270&action=edit Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off --- Comment #15 from Mason James <mtj@kohaaloha.com> --- (In reply to comment #9)
Jonathan. looks good, signing-off...
but, perlcritic errors...
errors fixed, signing-off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12264|0 |1 is obsolete| | --- Comment #16 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 12282 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12282&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12270|0 |1 is obsolete| | --- Comment #17 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 12283 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12283&action=edit Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #18 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 12284 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12284&action=edit Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kyle@bywatersolutions.com --- Comment #19 from Kyle M Hall <kyle@bywatersolutions.com> --- (In reply to comment #18)
Created attachment 12284 [details] Bug 8190 - Followup - Add cached logger, output messages to template
* Add C4::Context->logger * Embed logged messageds to a comment in the template html
I forget to add that I ran perltidy on Logger.pm. I think this followup could be very useful. It may be better to have it controlled by a system preference, rather than always on though. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12284|0 |1 is obsolete| | --- Comment #20 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 12287 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12287&action=edit Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #21 from Jonathan Druart <jonathan.druart@biblibre.com> --- Hi Kyle, Thanks for your followup ! 2 small remarks about your patch: * you commited mainpage.pl unfortunately * the added block of code in Logger::write is not perltidied Else all seems good but we have to pull together on how we will use the logger. Your idea to add a global var in C4::Context is what I had at the beginning of my work. But after thinking, on this way, we canot change the loglevel for 1 script ! And it is a regression (indeed currently we can do that, changing the DEBUG var). My idea was to add use C4::Logger qw/$log/; $log = C4::Logger->new({level => C4::Context->preference("LogLevel")}); on each page. Like that we could change the log level easily. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jared Camins-Esakov <jcamins@cpbibliography.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|unspecified |rel_3_12 --- Comment #22 from Jared Camins-Esakov <jcamins@cpbibliography.com> --- Changing target version so this bug report will show up in the list of 3.12-targeted features and doesn't get lost in the shuffle during feature freeze. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12282|0 |1 is obsolete| | --- Comment #23 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 12743 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12743&action=edit [SIGNED-OFF] Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12283|0 |1 is obsolete| | --- Comment #24 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 12744 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12744&action=edit [SIGNED-OFF] Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12287|0 |1 is obsolete| | --- Comment #25 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 12745 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12745&action=edit Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #26 from Kyle M Hall <kyle@bywatersolutions.com> --- (In reply to comment #21)
Hi Kyle, Thanks for your followup ! 2 small remarks about your patch: * you commited mainpage.pl unfortunately Fixed!
* the added block of code in Logger::write is not perltidied Fixed!
Else all seems good but we have to pull together on how we will use the logger.
I think it would be simple enough to replace all existing warns with the logger. I can volunteer some time to do this.
Your idea to add a global var in C4::Context is what I had at the beginning of my work. But after thinking, on this way, we canot change the loglevel for 1 script ! And it is a regression (indeed currently we can do that, changing the DEBUG var).
Would it be possible to add support for the DEBUG variable to the logger?
My idea was to add use C4::Logger qw/$log/; $log = C4::Logger->new({level => C4::Context->preference("LogLevel")}); on each page. Like that we could change the log level easily.
That would work, but it would be nice to follow the DRY principle. However, if you think it is not possible to place it in C4::Context, then I will believe you. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12745|0 |1 is obsolete| | --- Comment #27 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 12746 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12746&action=edit Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |paul.poulain@biblibre.com Patch complexity|--- |Small patch Summary|Koha does not have a |Add a logging module to |logging module |Koha, that can report log | |message to staff interface | |(for developer use) QA Contact| |paul.poulain@biblibre.com --- Comment #28 from Paul Poulain <paul.poulain@biblibre.com> --- QA comment: * I was enthusiastic about setting this patch to passed QA, because that's a large enhancement. * passes koha-qa.pl, except for a warning about merge marker in t/Logger.t that is irrelevant * the new Koha/Utils/Logger.pm has no PODDOC at all. there must be one (that should be easy to write) * I really love the LogToHtmlComments addition, it will be very userful * i've updated the bug title (for future 3.12 release notes) Please provide a follow-up to my signed-off & squashed patch with a POD and i'll be more than happy to pass QA on it ! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12743|0 |1 is obsolete| | Attachment #12744|0 |1 is obsolete| | Attachment #12746|0 |1 is obsolete| | --- Comment #29 from Paul Poulain <paul.poulain@biblibre.com> --- Created attachment 13739 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=13739&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #13739|0 |1 is obsolete| | --- Comment #30 from Paul Poulain <paul.poulain@biblibre.com> --- Created attachment 13740 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=13740&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> Bug 8190 follow-up moving updatedatabase part at the right place -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #31 from Paul Poulain <paul.poulain@biblibre.com> --- (In reply to comment #30) Forget patch updated in comment 29, I forgot to squash the updatedatabase changes:
Bug 8190 follow-up moving updatedatabase part at the right place
the comment 30 patch is OK ! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #32 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 13762 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=13762&action=edit Bug 8190: Follow Add some POD Add POD and prefix private methods with _ -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #13762|0 |1 is obsolete| | --- Comment #33 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 13763 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=13763&action=edit Bug 8190: Follow Add some POD Add POD and prefix private methods with _ -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #13740|0 |1 is obsolete| | --- Comment #34 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 13925 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=13925&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> Bug 8190 follow-up moving updatedatabase part at the right place Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #13763|0 |1 is obsolete| | --- Comment #35 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 13926 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=13926&action=edit Bug 8190: Follow Add some POD Add POD and prefix private methods with _ Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de Version|3.12 |master QA Contact|paul.poulain@biblibre.com |katrin.fischer@bsz-bw.de -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #36 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- I have started testing this. I notice, that when you have liblog-loglite-perl not installed, Koha is unusable. And instead of giving you an error indicating what's going wrong, it explodes with: Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. I think this will cause a lot of questions - can we make this fail a bit more gracefully? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #37 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to comment #36)
I have started testing this. I notice, that when you have liblog-loglite-perl not installed, Koha is unusable. And instead of giving you an error indicating what's going wrong, it explodes with:
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
I think this will cause a lot of questions - can we make this fail a bit more gracefully?
I think this is the case for all non installed package. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #38 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Often the perl error message is more helpful, indicating that there is a missing dependency. I think the way this explodes now is going to make us answer lots of questions. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #39 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 14294 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14294&action=edit Bug 8190: raise an error if the Log::LogLite module is not installed -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #40 from Jonathan Druart <jonathan.druart@biblibre.com> --- The patch displays a specific message if the module Koha::Utils::Logger raises an error. It is not a clean way but I don't know how to do this differently. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #41 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Hi Jonathan, thx for looking into this. I have continued testing and found another problem. When you don't have the new environment variable set, the test suite fails. The tests need to pass without additional 'developer configuration'. Can you please change the test? Maybe you can set the environment variable in the test and use a writeable temporary file. I am going set 'Failed QA' for this reason - please switch back to Signed Off when the tests pass. There is also a little typo (Logguer) when you run the test with prove t/Logger.t: | You must call this test with a KOHA_LOG env var like: | | KOHA_LOG="/tmp/t1.log" prove t/Logguer.t | I was also wondering about the 7 levels - do we have some more documentation how the different levels are supposed to be used? Maybe this is a standard Perl/Logging thing I am not aware of, but I think some more pointers in the POD or on a wiki page would be really helpful before we start using this all over Koha. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #42 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 14296 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14296&action=edit Bug 8190: FIX Unit test Set the KOHA_LOG environment variable in the test -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off --- Comment #43 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to comment #41)
I was also wondering about the 7 levels - do we have some more documentation how the different levels are supposed to be used? Maybe this is a standard Perl/Logging thing I am not aware of, but I think some more pointers in the POD or on a wiki page would be really helpful before we start using this all over Koha.
It is not easy to deal correctly with each level. debug, warning and error are easy. But how to differentiate an error from a critical message? The choice is made from personal point of view and can vary for each kind of bug. It is not easy to do an exhaustive wiki page for such stuff. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #44 from Jonathan Druart <jonathan.druart@biblibre.com> --- A quick start: http://wiki.koha-community.org/wiki/Logger -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #45 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Hi Jonathan, thx for your work - still testing. :) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #46 from Jared Camins-Esakov <jcamins@cpbibliography.com> --- (In reply to comment #44)
A quick start: http://wiki.koha-community.org/wiki/Logger
It seems to me that ->debug calls *should* be included in code committed to Master. Isn't the entire point of the logger that it's possible to change your log level so that you can get all the debug information/all the warnings/info and errors/just errors/just critical errors? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #47 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to comment #46)
(In reply to comment #44)
A quick start: http://wiki.koha-community.org/wiki/Logger
It seems to me that ->debug calls *should* be included in code committed to Master. Isn't the entire point of the logger that it's possible to change your log level so that you can get all the debug information/all the warnings/info and errors/just errors/just critical errors?
Yes maybe. But developpers must be aware that too many debug message are not relevant because logs would become too big and then unreadable. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #48 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- I can't get debug to show up. My LogLevel is set to the highest level 7. I verified this is also the value in the systempreferences table. I added following code to the mainpage.pl file: use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->unusable("This is an unusable thing"); $log->critical("This is critical!"); $log->error("This is an error !"); $log->warning("This is only a warning."); $log->normal("This nothing to worry about."); $log->info("This is an information"); $log->debug("This is a debug message"); With LogToHtmlComments set to Embed I can see following in the HTML source code of the main page: <!-- LOG MESSAGES [Thu Dec 27 17:54:44 2012] UNUS : This is an unusable thing [Thu Dec 27 17:54:44 2012] CRIT : This is critical! [Thu Dec 27 17:54:44 2012] ERROR : This is an error ! [Thu Dec 27 17:54:44 2012] WARN : This is only a warning. [Thu Dec 27 17:54:44 2012] NORMAL: This nothing to worry about. [Thu Dec 27 17:54:44 2012] INFO : This is an information --> My log files shows: [27/12/2012 17:54:44] UNUS : This is an unusable thing [27/12/2012 17:54:44] CRIT : This is critical! [27/12/2012 17:54:44] ERROR : This is an error ! [27/12/2012 17:54:44] WARN : This is only a warning. [27/12/2012 17:54:44] NORMAL: This nothing to worry about. [27/12/2012 17:54:44] INFO : This is an information My test plan so far was: 1) Apply patches and try to access Koha. Verify useful error message is shown. 2) Install new dependency: Log::LogLite sudo apt-get install liblog-loglite-perl 3) Run database update Verify database update works correctly 4) Run t/Logger.t Verify all tests pass 5) Do some searches in OPAC. Verify Koha does not explode and all is acting normal. Verify debug message is not showing up in HTML source. Look for <!-- LOG MESSAGES Verify nothing has changed and no messages show up. 6) Set environment variables in your Apache configuration files I added following line to the OPAC and Intranet <virtualhost> sections: SetEnv KOHA_LOG "/home/<user>/koha-dev/var/log/opac.log" SetEnv KOHA_LOG "/home/<user>/koha-dev/var/log/intranet.log" Make sure log file is writeable for your Apache user. 7) Repeat 5). Check that the searches show up in the OPAC log file. 8) Change one of the intranet files and add some messages/warns etc. to be logged. 9) Set LogToHtmlComments to 'Embed' and check output in log file and for the debug messages in the source code. Looks for <!-- LOG MESSAGES ALSO: With bug 7167 pushed, the update database part on this should be rewritten. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #49 from Jonathan Druart <jonathan.druart@biblibre.com> --- Hi Katrin, Yes it is normal. Try with : my $log = C4::Context->logger; the constructor Koha::Utils::Logger->new takes a level parameter. If it does not exist, the normal level is used. C4::Context->logger uses the level from the syspref LogLevel. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #50 from Chris Cormack <chris@bigballofwax.co.nz> --- Created attachment 14318 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14318&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> Bug 8190 follow-up moving updatedatabase part at the right place Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #13925|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #13926|0 |1 is obsolete| | --- Comment #51 from Chris Cormack <chris@bigballofwax.co.nz> --- Created attachment 14319 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14319&action=edit Bug 8190: Follow Add some POD Add POD and prefix private methods with _ Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #14294|0 |1 is obsolete| | --- Comment #52 from Chris Cormack <chris@bigballofwax.co.nz> --- Created attachment 14320 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14320&action=edit Bug 8190: raise an error if the Log::LogLite module is not installed -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #14296|0 |1 is obsolete| | --- Comment #53 from Chris Cormack <chris@bigballofwax.co.nz> --- Created attachment 14321 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14321&action=edit Bug 8190: FIX Unit test Set the KOHA_LOG environment variable in the test -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |ASSIGNED --- Comment #54 from Chris Cormack <chris@bigballofwax.co.nz> --- Patches rebased so they all apply on master. Tests pass. However it is currently not plack safe, follow up to come. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #55 from Chris Cormack <chris@bigballofwax.co.nz> --- I started trying to tidy it, but didn't get super far, attached is the patch, for interest sake. I might try another approach if time allows. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #56 from Chris Cormack <chris@bigballofwax.co.nz> --- Created attachment 14324 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14324&action=edit DO NOT USE - Partial rewrite of Logger -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #57 from Jared Camins-Esakov <jcamins@cpbibliography.com> --- I think I favor Log4Perl over LogLite, since it allows us to cut down dramatically on the amount of code that we are maintaining. However, I do not have a strong opinion on that. There are five issues that absolutely must be fixed: 1) The ->debug() level needs to work. 2) Private variable need to be eliminated from the module level and the code made thread-safe. 3) The unit test must be changed to not require the database. 4) The $log package variable should not be in Koha::Utils::Logger. Any static configuration should be handled entirely in C4::Context. 5) If Koha::Utils::Logger is object-oriented, it must not be an Exporter. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |In Discussion --- Comment #58 from Chris Cormack <chris@bigballofwax.co.nz> --- If we are going to always access the logger object via C4::Context, we could do this all without the need of a new module. if in C4::Context we added something very similar to use Log::Log4perl qw(:levels get_logger); my $layout_class = "Log::Log4perl::Layout::PatternLayout"; my $layout_pattern = "[%d] %p - %M - %m - %T%n"; my $config = <<"END"; log4perl.logger = INFO, Logfile, Screen log4perl.appender.Logfile = Log::Log4perl::Appender::File log4perl.appender.Logfile.filename = $ENV{KOHA_LOG} log4perl.appender.Logfile.mode=append log4perl.appender.Logfile.layout = $layout_class log4perl.appender.Logfile.layout.ConversionPattern=$layout_pattern log4perl.appender.Screen = Log::Log4perl::Appender::Screen log4perl.appender.Screen.layout = $layout_class log4perl.appender.Screen.layout.ConversionPattern = $layout_pattern END Log::Log4perl->init( \$config ); and then in there a sub sub logger { my $self = shift; if ( defined( $context->{"logger"} ) ) { return $context->{"logger"}; } $context->{"logger"} = Log::Log4perl->get_logger('C4::Context'); $context->{"logger"}->level(C4::Context->preference("LogLevel")); return $context->{"logger"}; } We would have a logger logging to stderr and to the file defined. We would need to change our numeric loglevels to strings, like FATAL, WARN etc but that is easily done. And if we did want our 2 extra ones, we can add these 2 lines # set up our custom log leves CRIT and NORMAL Log::Log4perl::Logger::create_custom_level( 'CRIT', 'FATAL'); Log::Log4perl::Logger::create_custom_level( 'NORMAL', 'WARN' ); Before we do the init. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #59 from Jared Camins-Esakov <jcamins@cpbibliography.com> --- (In reply to comment #58)
If we are going to always access the logger object via C4::Context, we could do this all without the need of a new module.
That seems reasonable to me. Is there a downside to that method of handling the logging? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #60 from Chris Cormack <chris@bigballofwax.co.nz> --- (In reply to comment #59)
(In reply to comment #58)
If we are going to always access the logger object via C4::Context, we could do this all without the need of a new module.
That seems reasonable to me. Is there a downside to that method of handling the logging?
Hmm I think when working with Koha you always need a context object, so that having a logging object seems good to me. If you did want to log without context (no access to db or conf) you would have to make your own object. If you want to provide a dump mechanism like the original patch you can define a filter in the configuration to do that. I may have missed something though -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #61 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 14388 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14388&action=edit Bug 8190: QA Followup - Remove the private variables - Remove the use of C4::Context in the UT - Remove the Exporter -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #62 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to comment #57)
There are five issues that absolutely must be fixed: 1) The ->debug() level needs to work.
It has always worked, see comment #49
2) Private variable need to be eliminated from the module level and the code made thread-safe.
Done, tested with Plack
3) The unit test must be changed to not require the database.
Done, removed the C4::Context requirement
4) The $log package variable should not be in Koha::Utils::Logger. Any static configuration should be handled entirely in C4::Context. 5) If Koha::Utils::Logger is object-oriented, it must not be an Exporter.
Done -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|In Discussion |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #14320|0 |1 is obsolete| | --- Comment #63 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 14703 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14703&action=edit Bug 8190: raise an error if the Log::LogLite module is not installed Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #14321|0 |1 is obsolete| | --- Comment #64 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 14704 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14704&action=edit Bug 8190: FIX Unit test Set the KOHA_LOG environment variable in the test Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #14388|0 |1 is obsolete| | --- Comment #65 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 14705 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14705&action=edit Bug 8190: QA Followup - Remove the private variables - Remove the use of C4::Context in the UT - Remove the Exporter Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #14324|0 |1 is obsolete| | --- Comment #66 from Kyle M Hall <kyle@bywatersolutions.com> --- Comment on attachment 14324 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14324 DO NOT USE - Partial rewrite of Logger Obsoleting this patch for now as the rest are signed off and this one isn't meant to be used. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #67 from Paul Poulain <paul.poulain@biblibre.com> --- Joubu, I can't apply those patches, I get a : fatal: sha1 information is lacking or useless (C4/Context.pm). Repository lacks necessary blobs to fall back on 3-way merge. Cannot fall back to three-way merge. Patch failed at 0001 Bug 8190: raise an error if the Log::LogLite module is not installed on the 3rd patch. Please fix & set back to signed off. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #14318|0 |1 is obsolete| | Attachment #14319|0 |1 is obsolete| | Attachment #14703|0 |1 is obsolete| | Attachment #14704|0 |1 is obsolete| | Attachment #14705|0 |1 is obsolete| | --- Comment #68 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 16426 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=16426&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> Bug 8190 follow-up moving updatedatabase part at the right place Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #69 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 16427 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=16427&action=edit Bug 8190: Follow Add some POD Add POD and prefix private methods with _ Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #70 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 16428 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=16428&action=edit Bug 8190: raise an error if the Log::LogLite module is not installed Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #71 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 16429 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=16429&action=edit Bug 8190: FIX Unit test Set the KOHA_LOG environment variable in the test Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #72 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 16430 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=16430&action=edit Bug 8190: QA Followup - Remove the private variables - Remove the use of C4::Context in the UT - Remove the Exporter Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #16426|0 |1 is obsolete| | Attachment #16427|0 |1 is obsolete| | Attachment #16428|0 |1 is obsolete| | Attachment #16429|0 |1 is obsolete| | Attachment #16430|0 |1 is obsolete| | --- Comment #73 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18799 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18799&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> Bug 8190 follow-up moving updatedatabase part at the right place Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #74 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18800 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18800&action=edit Bug 8190: Follow Add some POD Add POD and prefix private methods with _ Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #75 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18801 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18801&action=edit Bug 8190: raise an error if the Log::LogLite module is not installed Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #76 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18802 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18802&action=edit Bug 8190: FIX Unit test Set the KOHA_LOG environment variable in the test Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #77 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18803 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18803&action=edit Bug 8190: QA Followup - Remove the private variables - Remove the use of C4::Context in the UT - Remove the Exporter Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl --- Comment #78 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Trivial rebase. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #79 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- QA Comment: Looks quite promising! Some questions on details: You (almost) follow common levels like: LOG_EMERG system is unusable LOG_ALERT action must be taken immediately LOG_CRIT critical conditions LOG_ERR error conditions LOG_WARNING warning conditions LOG_NOTICE normal, but significant, condition LOG_INFO informational message LOG_DEBUG debug-level message Why no alert level? Note that LogLite also supports 8 levels (0=unusable, 1=close to unusable) Displaying 1-Unusable is not intuitively clear (in the prefs)? If you include html comments in staff doc-head-open, why not in opac side? Note that you add a test in opac-search (info statement). Is the eval require+die for Koha::Utils::Logger in the third patch really an improvement? I am no packaging expert :) But is adding this module in install_misc/debian.packages enough? Changing status to reflect need for clarification (or adjustment). -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off --- Comment #80 from Jonathan Druart <jonathan.druart@biblibre.com> --- Hi Marcel, thanks for your comments! (In reply to comment #79)
Why no alert level? Note that LogLite also supports 8 levels (0=unusable, 1=close to unusable)
I will propose a new patch adding the "alert" level.
Displaying 1-Unusable is not intuitively clear (in the prefs)?
I created a wiki page, maybe should we add a link to this page in the syspref description?
If you include html comments in staff doc-head-open, why not in opac side? Note that you add a test in opac-search (info statement).
Kyle wrote this part (patch in comment 27), so I don't really why but I think it could be a security issue to display the Koha logs at the OPAC.
Is the eval require+die for Koha::Utils::Logger in the third patch really an improvement?
It was asked by Katrin in order to avoid an "internal server error" (see comment 36).
I am no packaging expert :) But is adding this module in install_misc/debian.packages enough?
I think so, but not really sure. Switch back to "Signed Off" -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #81 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 18819 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18819&action=edit Bug 8190 - Add a logging module to Koha - Followup - Add html embedded logs to OPAC -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #82 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 18820 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18820&action=edit Bug 8190: Add the 'alert' level. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #83 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to comment #81)
Created attachment 18819 [details] [review] Bug 8190 - Add a logging module to Koha - Followup - Add html embedded logs to OPAC
I understand the changes for opac and using the Koha plugin logic. But I still cannot see the log message in the opac document. (Just empty for opac-search) Are you sure that the statement Logger.get_messages works this way? I tried logger lc too without results. It seems not to work.. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Kyle M Hall <kyle.m.hall@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kyle.m.hall@gmail.com --- Comment #84 from Kyle M Hall <kyle.m.hall@gmail.com> --- Did you add any logging code to an opac script to test it? I just added this to my opac-main.pl to test: C4::Context->logger->debug("This is a debug message"); C4::Context->logger->error("This is an error !"); With the default error level only the latter message will display in the embedded logs comment. (In reply to comment #83)
(In reply to comment #81)
Created attachment 18819 [details] [review] [review] Bug 8190 - Add a logging module to Koha - Followup - Add html embedded logs to OPAC
I understand the changes for opac and using the Koha plugin logic. But I still cannot see the log message in the opac document. (Just empty for opac-search) Are you sure that the statement Logger.get_messages works this way? I tried logger lc too without results. It seems not to work..
-- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #85 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to comment #84)
Did you add any logging code to an opac script to test it? I just added this to my opac-main.pl to test:
C4::Context->logger->debug("This is a debug message"); C4::Context->logger->error("This is an error !");
Found what happened: In opac-search Jonathan creates a logger object in opac-search (that's the one I was looking for). But C4/Auth also initialized a logger ALREADY. So the second logger got my message, but the template asked it to the first logger and got nothing. Still following? Will send a small followup for this. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18799|0 |1 is obsolete| | Attachment #18800|0 |1 is obsolete| | Attachment #18801|0 |1 is obsolete| | Attachment #18802|0 |1 is obsolete| | Attachment #18803|0 |1 is obsolete| | Attachment #18819|0 |1 is obsolete| | Attachment #18820|0 |1 is obsolete| | --- Comment #86 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18870 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18870&action=edit Bug 8190: Koha::Utils::Logger, Logging module use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; $log->debug("This is a debug message"); $log->info("This is an information"); $log->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190: Followup Logger: FIX perlcritic Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messageds to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> Bug 8190 follow-up moving updatedatabase part at the right place Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #87 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18871 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18871&action=edit Bug 8190: Follow Add some POD Add POD and prefix private methods with _ Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #88 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18872 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18872&action=edit Bug 8190: raise an error if the Log::LogLite module is not installed Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #89 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18873 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18873&action=edit Bug 8190: FIX Unit test Set the KOHA_LOG environment variable in the test Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #90 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18874 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18874&action=edit Bug 8190: QA Followup - Remove the private variables - Remove the use of C4::Context in the UT - Remove the Exporter Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #91 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18875 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18875&action=edit Bug 8190 - Add a logging module to Koha - Followup - Add html embedded logs to OPAC Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #92 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18876 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18876&action=edit Bug 8190: Add the 'alert' level. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #93 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18877 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18877&action=edit Bug 8190: Followup for opac-search Script should not create a second logger object, but use the one that the Auth module already made. Works fine now. Only question is: Should we leave it here. This is somewhat of a debug statement. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|Small patch |Medium patch QA Contact|katrin.fischer@bsz-bw.de |m.de.rooy@rijksmuseum.nl -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Add a logging module to |Add a logging module to |Koha, that can report log |Koha |message to staff interface | |(for developer use) | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #94 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Some QA observations: The first patch commit message should preferably be edited. Since we initialize the logger in Auth.pm, you do not need: use Koha::Utils::Logger qw/$log/; $log = Koha::Utils::Logger->new; Just say: $log= C4::Context->logger; (This was actually the reason for the last followup.) Will take the liberty now to edit these comments. Forgive me for that.. The first patch seems to delete a SetVersion line in updatedatabase for an older dbrev (3.9.0.45?). This is a blocker. Will amend this one if nothing more follows. The hardcoded 5 in Koha::Utils::Logger in new routine is not very nice :) Strange, because it was a constant in earlier patch than patch 5. Thanks for adding the alert level. When looking trough the code I still noticed a mention of 7 levels instead of 8 now. Another set of patches coming.. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18870|0 |1 is obsolete| | --- Comment #95 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18880 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18880&action=edit Bug 8190: Koha::Utils::Logger, Logging module Use the logger like: $logger= C4::Context->logger; $logger->debug("This is a debug message"); $logger->info("This is an information"); $logger->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Includes (apparently from squashed patches): Bug 8190: Followup Logger: FIX perlcritic Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messages to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql Bug 8190 follow-up moving updatedatabase part at the right place Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Amended the patch for a updatedatabase problem. Edited the commit message. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18871|0 |1 is obsolete| | Attachment #18872|0 |1 is obsolete| | Attachment #18873|0 |1 is obsolete| | Attachment #18874|0 |1 is obsolete| | --- Comment #96 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18881 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18881&action=edit Bug 8190: Follow Add some POD Add POD and prefix private methods with _ Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #97 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18882 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18882&action=edit Bug 8190: raise an error if the Log::LogLite module is not installed Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #98 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18883 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18883&action=edit Bug 8190: FIX Unit test Set the KOHA_LOG environment variable in the test Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #99 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18884 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18884&action=edit Bug 8190: QA Followup - Remove the private variables - Remove the use of C4::Context in the UT - Remove the Exporter Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18875|0 |1 is obsolete| | --- Comment #100 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18886 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18886&action=edit Bug 8190: Followup - Add html embedded logs to OPAC Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18876|0 |1 is obsolete| | Attachment #18877|0 |1 is obsolete| | --- Comment #101 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18887 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18887&action=edit Bug 8190: Add the 'alert' level. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #102 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 18888 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18888&action=edit Bug 8190: Followup for opac-search Script should not create a second logger object, but use the one that the Auth module already made. Works fine now. Only question is: Should we leave it here. This is somewhat of a debug statement. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA --- Comment #103 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- 'final' comment for RM: Code looks good to me now. (See QA comments before.) I am wondering if we should by default put the level to 5 (normal) at install or upgrade. When someone does not want to use it, we could set it to zero (emerge or unusable level) and have around zero messages. Robin should still have a look for the packaging stuff. Jonathan will probably send a few trivial followups for housekeeping (e.g. correcting 7->8 levels; also in pref desc in db). Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #104 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 18890 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18890&action=edit Bug 8190: FIX description and values for the LogLevel pref -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #105 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to comment #95)
Amended the patch for a updatedatabase problem. Edited the commit message.
Thanks for that Marcel! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gmcharlt@gmail.com --- Comment #106 from Galen Charlton <gmcharlt@gmail.com> --- (In reply to comment #6)
Perhaps also take a look at Log4Perl http://search.cpan.org/~mschilli/Log-Log4perl-1.37/lib/Log/Log4perl.pm I had a look at several perl logging modules. My conclusion is LogLite is
(In reply to comment #4) the easier for what we need into Koha.
That begs a question, though -- what do we need in Koha? One part of the answer to that question, for me, and I suspect for most folks who administer more than one Koha database or who administer services in addition to Koha, is syslog support. Log::LogLite doesn't provide such support, whereas Log4Perl does in addition to supporting appending to traditional log files. Also, Chris in comment 58 all but proposed a counter-patch. Would the original patch submitter respond to that comment, please? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #107 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to comment #106)
That begs a question, though -- what do we need in Koha?
One part of the answer to that question, for me, and I suspect for most folks who administer more than one Koha database or who administer services in addition to Koha, is syslog support. Log::LogLite doesn't provide such support, whereas Log4Perl does in addition to supporting appending to traditional log files.
Also, Chris in comment 58 all but proposed a counter-patch. Would the original patch submitter respond to that comment, please?
This development was written 1 year ago for BibLibre branches. We need a logger with different levels (like many softwares). I provided a simple module which does what we want. Since this is a simple class, it could be rewritten easily by someone having a better idea. The patch proposed by Chris was not working but it could be the second step to this development. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #108 from Chris Cormack <chris@bigballofwax.co.nz> --- (In reply to comment #107)
(In reply to comment #106)
That begs a question, though -- what do we need in Koha?
One part of the answer to that question, for me, and I suspect for most folks who administer more than one Koha database or who administer services in addition to Koha, is syslog support. Log::LogLite doesn't provide such support, whereas Log4Perl does in addition to supporting appending to traditional log files.
Also, Chris in comment 58 all but proposed a counter-patch. Would the original patch submitter respond to that comment, please?
This development was written 1 year ago for BibLibre branches. We need a logger with different levels (like many softwares). I provided a simple module which does what we want. Since this is a simple class, it could be rewritten easily by someone having a better idea. The patch proposed by Chris was not working but it could be the second step to this development.
The point of my counter proposal was that we do not need another module, we can add some lines to context.pm using Log4perl and not have another module to maintain ourselves. Pushing this now as it is, would mean we would just have to remove it again if we wanted to do it the Log4perl way. IE if people think that is a good idea, then I can write a working patch for that, however if this is pushed, I won't. I also won't be happy that we have yet another module we have to maintain instead. I maintain we dont need a new logging module, we just need to add logging to C4::Context. I don't like suggesting people abandon the work they have done, but I have real reservations about adding yet another module we have to maintain. The fact that it is a class doesn't really affect this point at all My point was you don't need another module, we can simply do use Log::Log4perl qw(:levels get_logger); my $layout_class = "Log::Log4perl::Layout::PatternLayout"; my $layout_pattern = "[%d] %p - %M - %m - %T%n"; my $config = <<"END"; log4perl.logger = INFO, Logfile, Screen log4perl.appender.Logfile = Log::Log4perl::Appender::File log4perl.appender.Logfile.filename = $ENV{KOHA_LOG} log4perl.appender.Logfile.mode=append log4perl.appender.Logfile.layout = $layout_class log4perl.appender.Logfile.layout.ConversionPattern=$layout_pattern log4perl.appender.Screen = Log::Log4perl::Appender::Screen log4perl.appender.Screen.layout = $layout_class log4perl.appender.Screen.layout.ConversionPattern = $layout_pattern END Log::Log4perl->init( \$config ); and then in there a sub sub logger { my $self = shift; if ( defined( $context->{"logger"} ) ) { return $context->{"logger"}; } $context->{"logger"} = Log::Log4perl->get_logger('C4::Context'); $context->{"logger"}->level(C4::Context->preference("LogLevel")); return $context->{"logger"}; } (Or something very similar in C4::Context) Then anywhere we want to log C4::Context->logger() gives us a logger -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #109 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to comment #108) Hi Chris,
The point of my counter proposal was that we do not need another module, we can add some lines to context.pm using Log4perl and not have another module to maintain ourselves.
Humm, I don't think it is a good argument. A module with unit tests is easiest to maintain than a module like C4::Context (~1000l) :)
Pushing this now as it is, would mean we would just have to remove it again if we wanted to do it the Log4perl way. IE if people think that is a good idea, then I can write a working patch for that, however if this is pushed, I won't. I also won't be happy that we have yet another module we have to maintain instead.
I maintain we dont need a new logging module, we just need to add logging to C4::Context.
There is no problem to propose an alternative working patch, but don't loose sight of the fact that the module we propose here does something else more than just logging: - a called by trace is displayed for some levels - a get_messages method allows to return all logged messages - messages are thrown to the stdout if the logger is not defined (ie. no filepatch defined or a bad configuration somewhere) - a parameter allows to dump a variable (using Data::Dumper or something else. e.g. $logger->debug($hashref, "dump_me");) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #110 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to comment #109)
(In reply to comment #108)
The point of my counter proposal was that we do not need another module, we can add some lines to context.pm using Log4perl and not have another module to maintain ourselves.
Humm, I don't think it is a good argument. A module with unit tests is easiest to maintain than a module like C4::Context (~1000l) :)
Chris, I think that Jonathan has a point here. Maintaining a small and clear coded module will not be a pain. The maintenance problems will not be in this kind of module, but in complex modules and scripts dealing with circulation among others. But if Log4Perl is a better choice, it sounds like that it could replace LogLite rather easy? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #111 from Chris Cormack <chris@bigballofwax.co.nz> --- (In reply to comment #109)
(In reply to comment #108)
Hi Chris,
The point of my counter proposal was that we do not need another module, we can add some lines to context.pm using Log4perl and not have another module to maintain ourselves.
Humm, I don't think it is a good argument. A module with unit tests is easiest to maintain than a module like C4::Context (~1000l) :)
We still have to maintain C4::Context, and now a new module, it feels hugely like reinventing the wheel for the 13th time and I still don't like it. We probably will have to agree to disagree on this. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |rel_3_14_candidate -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |rel_3_16_candidate -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |In Discussion -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |http://bugs.koha-community. | |org/bugzilla3/show_bug.cgi? | |id=13413 -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18880|0 |1 is obsolete| | --- Comment #112 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34837 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34837&action=edit Bug 8190: Koha::Utils::Logger, Logging module Use the logger like: $logger= C4::Context->logger; $logger->debug("This is a debug message"); $logger->info("This is an information"); $logger->error("This is an error !"); The Logger constructor can take an hash reference with "file" and "level" to define a filepath or a log level. For a log level >= warning, a call stack is printed. Prerequisite: - set an environment variable KOHA_LOG in your virtual host: SetEnv KOHA_LOG /home/koha/var/log/opac.log - set a write flag for www-data on this file Please have a look at t/Logger.t for more details. Includes (apparently from squashed patches): Bug 8190: Followup Logger: FIX perlcritic Bug 8190 - Followup - Add cached logger, output messages to template * Add C4::Context->logger * Embed logged messages to a comment in the template html, controlled by the system preference LogToHtmlComments\ * Add both new system preferences to sysprefs.sql Bug 8190 follow-up moving updatedatabase part at the right place Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Amended the patch for a updatedatabase problem. Edited the commit message. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18881|0 |1 is obsolete| | --- Comment #113 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34838 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34838&action=edit Bug 8190: Follow Add some POD Add POD and prefix private methods with _ Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18882|0 |1 is obsolete| | --- Comment #114 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34839 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34839&action=edit Bug 8190: raise an error if the Log::LogLite module is not installed Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18883|0 |1 is obsolete| | --- Comment #115 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34840 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34840&action=edit Bug 8190: FIX Unit test Set the KOHA_LOG environment variable in the test Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18884|0 |1 is obsolete| | --- Comment #116 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34841 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34841&action=edit Bug 8190: QA Followup - Remove the private variables - Remove the use of C4::Context in the UT - Remove the Exporter Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18886|0 |1 is obsolete| | --- Comment #117 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34842 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34842&action=edit Bug 8190: Followup - Add html embedded logs to OPAC Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18887|0 |1 is obsolete| | --- Comment #118 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34843 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34843&action=edit Bug 8190: Add the 'alert' level. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18888|0 |1 is obsolete| | --- Comment #119 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34844 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34844&action=edit Bug 8190: Followup for opac-search Script should not create a second logger object, but use the one that the Auth module already made. Works fine now. Only question is: Should we leave it here. This is somewhat of a debug statement. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18890|0 |1 is obsolete| | --- Comment #120 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34845 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34845&action=edit Bug 8190: FIX description and values for the LogLevel pref -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 --- Comment #121 from Jonathan Druart <jonathan.druart@biblibre.com> --- Patches rebased. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |http://bugs.koha-community. | |org/bugzilla3/show_bug.cgi? | |id=14167 -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com --- Comment #122 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- I'm in general preferring the simplicity of Bug 14167 for now. Lets go with that and get this much needed feature into Koha! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8190 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|In Discussion |RESOLVED CC| |tomascohen@gmail.com Resolution|--- |DUPLICATE --- Comment #123 from Tomás Cohen Arazi <tomascohen@gmail.com> --- *** This bug has been marked as a duplicate of bug 14167 *** -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org