[Catalyst] Warnings on application startup

2007-10-29 Thread Marius Kjeldahl
Greetings, I'm developing a catalyst-based application on development machines running Gentoo linux. They're all pretty much the same machines as I update them pretty frequently. When I run the same source on two different development machines, I have lately started to get some warnings on applic

Re: [Catalyst] SOLVED: Warnings on application startup

2007-10-29 Thread Marius Kjeldahl
I managed to get rid of the warnings. I suspected there were differences in the various ways in which Catalyst modules can be installed. Initially I tried the "catinstall" script as "advertised" on the Catalyst website. When starting to work with it, I guess I needed additional modules which were

Re: [Catalyst] Warnings on application startup

2007-10-29 Thread Marius Kjeldahl
Michael Higgins wrote: > I also use Gentoo. Check out g-cpan and, more specifically, the > catalystframework overlay. > > With any luck, this will give you consistency and a Gentoo-ish way of > handling perl stuff. Thanks, I haven't looked at g-cpan yet, but I have used the catalystframework o

[Catalyst] Catalyst::Log::Log4perl log duplicates

2008-01-07 Thread Marius Kjeldahl
I'm trying to use Catalyst::Log::Log4perl with Catalyst. My "main" package is called MintApp.pm, where I do the following calls: use Catalyst::Log::Log4perl; ... __PACKAGE__->log (Catalyst::Log::Log4perl->new ('mintapp-log.conf')); The conf file looks as follows: log4perl.logger.MintApp=ERROR, S

Re: [Catalyst] Catalyst::Log::Log4perl log duplicates

2008-01-07 Thread Marius Kjeldahl
Jason Kohles wrote: > It isn't the logger that's confused. :) > > Refer to the Log::Log4perl::FAQ entry titled 'I keep getting duplicate > log messages! What's wrong?' Thanks, looks like oneMessagePerAppender is what is needed. Strangely enough, I did not encounter this problem at a previous pro

Re: [Catalyst] Catalyst::Log::Log4perl log duplicates

2008-01-07 Thread Marius Kjeldahl
ave been item number two. My apologies. Regards, Marius K. Adam Jacob wrote: > On 1/7/08, Marius Kjeldahl <[EMAIL PROTECTED]> wrote: >> I tried briefly looking into the source, when I ran into this: >> >> # I really have no idea why the correct subrout

[Catalyst] PostgreSQL quoting issues

2008-01-16 Thread Marius Kjeldahl
I've got an application where I do the following: # Look up last calculated transsum if it exists my $rsts = $c->model ('MintAppDB::TransSum')->find ({ category => $c->req->param ('category'), sentto => $c->req->param ('sentto'),

Re: [Catalyst] PostgreSQL quoting issues

2008-01-16 Thread Marius Kjeldahl
Joshua D. Drake wrote: Does anybody have an idea how I can pursuade Postgres into accepting this as just a simple string and that Postgres shouldn't try to interpret anything in it? Yeah, quote the string. You can't submit an unquoted string to PostgreSQL. As my original post demonstrated, t

Re: [Catalyst] PostgreSQL quoting issues

2008-01-16 Thread Marius Kjeldahl
Thank you for all the hints about the security issues with using the param call. I will replace those calls with accessing the parameters/params hash instead, which should solve the list context issues in the hash that my example was suffering from. Marius K. _

[Catalyst] Catalyst, utf8 in form element type text

2008-05-04 Thread Marius Kjeldahl
I'm having a small problem that I hope somebody has a simple solution to. I'm using Catalyst with TT for the view, PostgreSQL and everything set up using utf8 (in perl source "use utf8", in postgres using "enable_utf8" and in the actual templates containing utf8 encoded interational characers).

Re: [Catalyst] Re: Catalyst, utf8 in form element type text - Solved

2008-05-05 Thread Marius Kjeldahl
Problem solved. In my "View" class, like: package MyApp::View::TT; use strict; use warnings; use base 'Catalyst::View::TT'; replace the last line with: use base 'Catalyst::View::TT::ForceUTF8'; and everything works fine. I guess there was some confusion between Template Toolkit and non-utf8 s

Re: [Catalyst] Re: Catalyst, utf8 in form element type text - Solved

2008-05-05 Thread Marius Kjeldahl
Bill Moseley wrote: use base 'Catalyst::View::TT::ForceUTF8'; That seems like the wrong approach. Data should be decoded on input from the outside and encoded on output. I'm not sure when it would be advisable to force utf8 flag on items in the stash, but I have not looked at that module in a

Re: [Catalyst] Configuration of $c->log with Catalyst::Log::Log4perl

2008-05-08 Thread Marius Kjeldahl
Jochen Luig wrote: This is myapp_logger.conf: log4perl.rootLogger=DEBUG, SCREEN Not sure if it changes anything, but does changing rootLogger to logger help? Sincerely, Marius K. ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys

Re: [Catalyst] Configuration of $c->log with Catalyst::Log::Log4perl

2008-05-08 Thread Marius Kjeldahl
Jochen Luig wrote: log4perl.appender.SCREEN.layout=PatternLayout How about changing PatternLayout to Log::Log4perl::Layout::PatternLayout? (sorry, I have no real knowledge about these modules, I only compare with what I have working at my end). Marius K. __

[Catalyst] App testing with Test::WWW::Mechanize::Catalyst

2008-07-31 Thread Marius Kjeldahl
I'm trying to set up application testing the with module described in the subject. However, when my application is loaded in the testscript with: use_ok ('Test::WWW::Mechanize::Catalyst', 'CalApp'); my $u = Test::WWW::Mechanize::Catalyst->new; most of the things I've setup to be done on loadin

Re: [Catalyst] App testing with Test::WWW::Mechanize::Catalyst

2008-07-31 Thread Marius Kjeldahl
ivorw wrote: Have you tried the next step, which is usually $u->get_ok( 'http://localhost/', 'Request should succeed' ); Yes, my $APPLOC = 'http://localhost/calapp/no'; $u->get_ok ($APPLOC, 'Application startup'); fails with: Couldn't instantiate component "CalApp::Model::CalAppDB", "Ei

Re: [Catalyst] App testing with Test::WWW::Mechanize::Catalyst

2008-07-31 Thread Marius Kjeldahl
ivorw wrote: I've seen this or similar. It's usually an indication that the Catalyst code is failing to see the config file (calappdb.yml or calappdb.conf), when you are defining the DBI parameters here rather than hardcoding them inside CalApp::Model::CalAppDB.pm which the helper script does for

[Catalyst] Re: [solved] App testing with Test::WWW::Mechanize::Catalyst

2008-08-01 Thread Marius Kjeldahl
Just a final followup; removing some hardcoded "use lib ..." paths in the test framework made everything behave identical on all installed systems. The problem was that one of the systems actually had some older stuff in one of the hardcoded paths that got picked up that made it bomb out on tha

Re: [Catalyst] mod_perl converts latin1 to utf8 !?

2008-12-28 Thread Marius Kjeldahl
I've followed a similar path to yours, and the best choice eventually for my projects was to make sure everything is utf8. Having said this, the specific bug that bit me in the ass was Firefox 3.0 messing up character set encodings for anything using Ajax-style calls. Fortunately, 3.1 fixed it.