[Catalyst] What is correct way to re-check user password for authenticated user?
Hello subscribers, On some pages I need to re-check user password (to be more concrete - each time when user change any settings on "user settings" page). I can't compare passwords directly (something like: $form->{password} eq $c->user->password()), because in DB I have only hashed passwords. Seems that I can try to authenticate user again, by calling $c->authenticate(name=>$c->user->name, pass=>$form->{password}), but I concerned is this acceptable - calling authenticate, when user is already authenticated. And what will be if provided password is incorrect - user will be auto-logout'ed or not? May be there is some other way, that is not obvious to me? Any thoughts is welcome, Thanks. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] IE6 shows page cannot be displayed
2009/10/14 Ascii King : > # Redirect to the list_prior page > $c->response->redirect($c->uri_for('list_prior')); Long time ago I have problems with calling uri_for, using string as first argument. For me solution was to use action argument, and now I use only this way. May be, this help you to: $c->response->redirect($c->uri_for($self->action_for('list_prior'))); HTH -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] [ANNOUNCE] Catalyst-Runtime 5.80016
2009/12/14 Alexander Hartmaier : > All app errors result in this cat error with the new version for me: > > [error] Caught exception in engine "Can't use string > ("508706d1a94648443fa31ffc8b2b5ccb") as a HASH ref while "strict refs" > in use at /home/ahartmai/perl5/lib/perl5/Catalyst/Engine.pm line 117." Try update scripts with "catalyst.pl -scripts -force YourAppName", I had similar issue. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Using jQuery with development server
And what is your question? :) PS: anyway, this is not a jQuery list... 2010/3/24 Colin Brizell : > I have the following markup in a template list.tt2 file > > > > > > > > > > title="Remove" /> > > > > > > > > When I clink on the image the first two alerts are displayed but the third > on isn’t and > > The “list function in the Question.pm Controller is called and the page is > refreshed. > > > > If I remove the following jQuery code:- > > > > $('#row_1_1').remove(); > > > > The event is not propagated > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] What to upload
http://search.cpan.org/dist/Catalyst-Manual/lib/Catalyst/Manual/Cookbook.pod#Deployment http://wiki.catalystframework.org/wiki/faq#Deployment 2010/4/1 Paul Falbe : > > > I'm getting close to uploading my first Catalyst App from my laptop > to our website which is hosted for us. What directories need > to be uploaded to this machine? I understand I also have to create > a .htaccess file so my app uses FastCGI and properly redirects. > Where is this file normally located? > > Thanks again. > > -Paul > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Distributing and updating Cat apps
2010/3/30 Bill Moseley : > > .. > The applications have separate YAML files for different environments. There > might be "dev.yml", "testing.yml", "qa.yml", and "produciton.yml". Each > machine has a file in /etc/<$app_name> that sets what environment the > application should start in (i.e. what YAML config file to use). Push to > testing and the app starts and uses the testing database as configured in > testing.yml. Catalyst already have such possibility: read end of "DESCRIPTION" in Catalyst::Plugin::ConfigLoader, and more details in description of get_config_local_suffix(). -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] What to upload
I think, you should use: FastCgiServer /www/DpklNotes/script/dpklnotes_fastcgi.pl -processes 3 Alias /dpklnotes/ /www/DpklNotes/script/dpklnotes_fastcgi.pl/ Alias /dpklnotes/static /www/DpklNotes/root/static SetHandler default-handler Just try and then write your experience at wiki. 2010/4/5 Paul Falbe : > > > do I need to add both of these? And do I add them to Apache conf or can they > be added .htaccess? > I'm a little confused about /static. > > DocumentRoot /www/DpklNotes/root > Alias /static /www/DpklNotes/root/static > > FastCgiServer /www/DpklNotes/script/dpklnotes_fastcgi.pl -processes 3 > Alias /dpklnotes/ /www/DpklNotes/script/dpklnotes_fastcgi.pl/ > > > On Mon, Apr 05, 2010 at 12:21:04PM +0300, Oleg Kostyuk wrote: >> http://search.cpan.org/dist/Catalyst-Manual/lib/Catalyst/Manual/Cookbook.pod#Deployment >> http://wiki.catalystframework.org/wiki/faq#Deployment >> >> 2010/4/1 Paul Falbe : >> > >> > >> > I'm getting close to uploading my first Catalyst App from my laptop >> > to our website which is hosted for us. What directories need >> > to be uploaded to this machine? I understand I also have to create >> > a .htaccess file so my app uses FastCGI and properly redirects. >> > Where is this file normally located? >> > >> > Thanks again. >> > >> > -Paul >> > >> >> -- >> Sincerely yours, >> Oleg Kostyuk (CUB-UANIC) >> >> ___ >> List: Catalyst@lists.scsys.co.uk >> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst >> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ >> Dev site: http://dev.catalyst.perl.org/ > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] What to upload
Did you ever tried any of them? This is not so hard. If you adding Catalyst app as part of other site, try to place directives above into same config file where your site is defined. This could be as main Apache config, as well as separate config. Finally, you should have something like this: # # This is about your main site # Site content is living under /www/somesite.com/ # ServerName somesite.com ServerAlias www.somesite.com DocumentRoot/www/somesite.com/ # # This is about your Catalyst app # App content is living under /www/DpklNotes/ # FastCgiServer /www/DpklNotes/script/dpklnotes_fastcgi.pl -processes 3 Alias /dpklnotes/ /www/DpklNotes/script/dpklnotes_fastcgi.pl/ Alias /dpklnotes/static /www/DpklNotes/root/static SetHandler default-handler Just try to do instead of asking :) 2010/4/5 Paul Falbe : > > > And that goes into .htaccess or apache2 conf file? Sorry for repeated > questions > this is not familiar territory... > > On Mon, Apr 05, 2010 at 03:28:47PM +0300, Oleg Kostyuk wrote: >> I think, you should use: >> >> >> FastCgiServer /www/DpklNotes/script/dpklnotes_fastcgi.pl -processes 3 >> Alias /dpklnotes/ /www/DpklNotes/script/dpklnotes_fastcgi.pl/ >> >> Alias /dpklnotes/static /www/DpklNotes/root/static >> >> SetHandler default-handler >> >> >> >> Just try and then write your experience at wiki. >> >> >> 2010/4/5 Paul Falbe : >> > >> > >> > do I need to add both of these? And do I add them to Apache conf or can >> > they be added .htaccess? >> > I'm a little confused about /static. >> > >> > DocumentRoot /www/DpklNotes/root >> > Alias /static /www/DpklNotes/root/static >> > >> > FastCgiServer /www/DpklNotes/script/dpklnotes_fastcgi.pl -processes 3 >> > Alias /dpklnotes/ /www/DpklNotes/script/dpklnotes_fastcgi.pl/ >> > >> > >> > On Mon, Apr 05, 2010 at 12:21:04PM +0300, Oleg Kostyuk wrote: >> >> http://search.cpan.org/dist/Catalyst-Manual/lib/Catalyst/Manual/Cookbook.pod#Deployment >> >> http://wiki.catalystframework.org/wiki/faq#Deployment >> >> >> >> 2010/4/1 Paul Falbe : >> >> > >> >> > >> >> > I'm getting close to uploading my first Catalyst App from my laptop >> >> > to our website which is hosted for us. What directories need >> >> > to be uploaded to this machine? I understand I also have to create >> >> > a .htaccess file so my app uses FastCGI and properly redirects. >> >> > Where is this file normally located? >> >> > >> >> > Thanks again. >> >> > >> >> > -Paul >> >> > >> >> >> >> -- >> >> Sincerely yours, >> >> Oleg Kostyuk (CUB-UANIC) >> >> >> >> ___ >> >> List: Catalyst@lists.scsys.co.uk >> >> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst >> >> Searchable archive: >> >> http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ >> >> Dev site: http://dev.catalyst.perl.org/ >> > >> > ___ >> > List: Catalyst@lists.scsys.co.uk >> > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst >> > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ >> > Dev site: http://dev.catalyst.perl.org/ >> > >> >> >> >> -- >> Sincerely yours, >> Oleg Kostyuk (CUB-UANIC) >> >> ___ >> List: Catalyst@lists.scsys.co.uk >> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst >> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ >> Dev site: http://dev.catalyst.perl.org/ > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] What to upload
> My site does FastCGI and I can do a .htaccess file but I haven't gotten that > to work yet > either Would have a sample .htaccess file I can try? Very interested, how they does FastCGI, if you don't have access to server config? You should ask them every time, when you need to change configuration? May be this is acceptable for you, but as for me, such hosting should be changed to some better. AFAIK, FastCGI /require/ access to server config, and start of FastCGI servers from .htaccess is not possible. Try to check in docs at http://www.fastcgi.com/. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] What to upload
http://www.fastcgi.com/drupal/node/25 Both FastCgiServer and FastCgiConfig directives can't be used in htaccess file. AddHandler can be used in htaccess, but with AddHandler you will get "dynamic" FastCGI. As for me, it don't have any benefits comparing to plain old CGI. If this is what you want, then just forget about FastCGI, and configure your app as usual CGI. 2010/4/6 Paul Falbe : > On Tue, Apr 06, 2010 at 04:07:01PM +0300, Oleg Kostyuk wrote: >> > My site does FastCGI and I can do a .htaccess file but I haven't gotten >> > that to work yet >> > either Would have a sample .htaccess file I can try? >> >> Very interested, how they does FastCGI, if you don't have access to >> server config? You should ask them every time, when you need to change >> configuration? May be this is acceptable for you, but as for me, such >> hosting should be changed to some better. >> >> AFAIK, FastCGI /require/ access to server config, and start of FastCGI >> servers from .htaccess is not possible. Try to check in docs at >> http://www.fastcgi.com/. > > Below is what they said. I tried everything I found by googling which is why > I thought > I must not be reading something correctly... > > "Hello Paul, > > mod_fastcgi is available. You would need to setup the appropriate fast cgi > hooks in your .htaccess file so that it processes the scripts. For example, > the following would parse fcg, fcgi, and fpl files as fast cgi scripts: > > AddHandler fastcgi-script fcg fcgi fpl" > > > > > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Catalyst::Model::DBIC::Schema and dbh_maker
2010/5/25 Bill Moseley : > I would like my Catalyst::Model::DBIC::Schema model class to be able to > inspect the configuration and modify connect_info. Specifically, based on a > flag in the config either pass connect_info unmodified or replace > dsn/user/password with a dbh_maker sub. Take a look at Catalyst::TraitFor::Model::DBIC::Schema::ConnectInfo::Several -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Catalyst-Plugin-Params-Nested rt 59604
You also could look at Catalyst::TraitFor::Request::Params::Hashed 2010/7/28 David Schmidt : > On Wed, Jul 28, 2010 at 1:40 AM, Evan Carroll wrote: >> Is C:P:P:N still maintained? I filed a bug on CPAN, next day I heard a >> request for a patch. I provided a patch, and I haven't heard anything >> back. If any one is maintaining it? Can I get co-maint to apply my >> patch. >> >> Find more information about the issue and the patch set here: >> https://rt.cpan.org/Public/Bug/Display.html?id=59604 >> >> -- >> Evan Carroll - m...@evancarroll.com >> System Lord of the Internets >> web: http://www.evancarroll.com >> ph: 281.901.0011 >> >> ___ >> List: Catalyst@lists.scsys.co.uk >> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst >> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ >> Dev site: http://dev.catalyst.perl.org/ >> > > Tomas Doran (the maintainer according to > http://search.cpan.org/dist/Catalyst-Plugin-Params-Nested/lib/Catalyst/Plugin/Params/Nested.pm) > is very active and im convinced he will apply the patch at due time if > it is sane. > > He reads the mailinglist aswell. Just give it some more time. > > david > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] C::V::Email::Template - "no sender" error
This is part of example from Catalyst::View::Email::Template: = $c->stash->{email} = { to => 'jshir...@gmail.com', cc => 'abra...@cpan.org', bcc => 'hid...@secret.com hidd...@foobar.com', from=> 'no-re...@foobar.com', .. = Your stash have "to" key/value pair, but don't have "from". Also: # grep -nr 'no sender' /usr/**/perl/ /usr/local/share/perl/5.10.1/Email/Sender/Manual/QuickStart.pm:67:those fields. Similarly, if no sender is specified, it will use the first /usr/local/share/perl/5.10.1/Email/Sender/Simple.pm:106: Email::Sender::Failure::Permanent->throw("no sender") if ! defined $from; HTH 2010/7/30 Ollie : > > Hi everyone, > > I'm new here, forgive my transgressions. I'm having an issue with > Catalyst::View::Email::Template. I've posted the full details to > perlmonks.org hoping to get a quick answer, but nothing yet. Here is a link > to the posting: > > http://perlmonks.org/?node_id=852027 > > I will copy the text of the posting for your convenience, though the > formatting might suffer. > > For future reference, is the PM link enough or should I continue to post the > full text for the archives? > > Thanks in advance! > > -Ollie > > > === > I keep getting a "no sender" error when trying to send email via > Catalyst::View::Email::Template. I'm pretty sure it's some sort of config > error, but I have tried everything I can think of with no resolution. Please > take a gander at my config and code and tell me what you think I should do. > Thanks! > > Here's the code that sends the email: > > my $to = $user->email; > $c->stash->{email_out} = { > to => $to, > subject => "XXX.com Membership Activation ($enc_string)", > template => 'activation.tt', > }; > > $c->forward($c->view('Email::Template')); > > if (not scalar @{$c->error}) { > $c->log->debug("*** Email sent! $to ($enc_string) ***"); > } > >> From MyApp.pm (not its real name, but the equivalent): > > __PACKAGE__->config->{'View::Email::Template'} = { > template_prefix => 'emails', > stash_key => 'email_out', > default => { > view => 'TT', > content_type => 'text/plain', > charset => 'utf-8', > }, > sender => { > mailer => 'SMTP', > mailer_args => { > host => 'mail..com', > sasl_username => '', > sasl_password => '', > ssl => 1, > } > }, > }; > > I have no config for View::Email because I don't plan on sending any > non-templated emails. I've tried it with and without, no change. I also have > no config directly in either my View::Email or View::Email::Template > modules. I tried putting some in there but it didn't resolve the issue. > Here's some of the debug output from Catalyst: > > [debug] Path is "send_activation_email" > [debug] Arguments are "" > [debug] *** Manually sending activation email *** > [debug] *** Sending activation email *** > [debug] *** Found existing activation, 3 *** > [debug] C::V::Email::Template uses default view > XXX::View::TT=HASH(0x10238e1c0) for rendering. > [debug] C::V::Email uses default content_type text/plain. > [debug] Rendering template "emails/activation.tt" > [debug] C::V::Email uses specified content_type text/plain. > [error] no sender > > I will post more debug output upon request, but there's nothing in there > that appears useful, to my eyes. > === > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] request for feedback : Catalyst-TraitFor-Component-ConfigPerSite
Hello, Thank you for your work! I have several questions. Why do you use Cache::Cache and not CHI? Even POD of Cache::Cache told: "The authors recommend the use of CHI going forward". What will be if I use KiokuDB and TT:Alloy - your work will be not usable without writing additional traits, correct? Also, I will be thankful, if you could add examples of config files for multi-site mode, and more documentation in general. PS: don't forget to clean debug code, like "use Data::Dumper" ;) 2010/11/18 Aaron Trevena : > I'm using ShinyCMS for several sites on a single bytemark VM and want > to be able to run them in a single starman or mod_perl server without > massively wasting memory duplicating everything.. > > Following a chat with mst on irc and a bit of evening hacking I give you : > https://github.com/hashbangperl/Catalyst-TraitFor-Component-ConfigPerSite > > No bits not on CPAN yet, once I've used it in anger onh a live box > I'll feel confident enough about uploading it. > > Cheers > > A > > -- > Aaron J Trevena, BSc Hons > http://www.aarontrevena.co.uk > LAMP System Integration, Development and Consulting > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Multiple chain sources?
2010/11/23 Eden Cardim : > No, that's currently not possible with chained. Matt and I, howeever, > are working on a grammar-based dispatcher that will allow easy > expression of those types of constructs. I would like to get more details about this. Is it possible to get repo url, please? > You'll have to declare something like: > > sub my :Chained('base') CaptureArgs(0) { > my($self, $c) = @_; > $c->forward(user => [$c->user->id]); > } > > and then chain onto that. Could you please explain, what is this? As I see in Catalyst POD, for now we have two signatures for forward method: $c->forward( $action [, \...@arguments ] ) $c->forward( $class, $method, [, \...@arguments ] ) As I think, $c->forward(user => [$c->user->id]) isn't one of them. So, what this should mean? Thanks in advance. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] How receive signals from FCGI::ProcManager?
May be better to ask on kiev.pm? ;) 2010/12/22 rimas rimas : > > Hello! > > Some components of my application require accurate de-initialization to > avoid resource leaks. I using Catalyst which running under > FastCGI(ProcManager) and looking for possibility get notification that > application is restarting or shutting down to perform specific cleanup > actions. > Seems to me ProcManager have required callbacks to notify application about > events(e.g. pm_die) but is it possible to subscribe on such events without > serious Catalyst hacking? > > Serg Gulko > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Problem with CHI in Catalyst application
Hello guys, Sorry for posting in several groups/mainling list, but seems all of them are (or may be) related to this problem. I have problem with CHI. Seems, it independent from used CHI Driver. Here is error message that I get: === [error] Caught exception in RVI::Bonvoyage::Web::Controller::Search->show_search_result "Can't call method "constructor_params" on an undefined value at /home/cub/share/perl/lib/perl5/CHI/Driver/Metacache.pm line 17." === I tried to solve it on IRC, but this was deep night, and too few peoples was online. But I did several pastes: 1) http://paste.scsys.co.uk/83116 - this is method in model class, contain call to CHI->compute() 2) http://paste.scsys.co.uk/83117 - this is beginning of CHI/Driver/Metacache.pm, with mark on line 17 3) http://paste.scsys.co.uk/83118 - this is config of CHI, changing driver to "Null" doesn't solve problem, and get exact same error 4) http://paste.scsys.co.uk/83119 - this is backtrace, up to first line of CHI::Driver::Metacache::_build_meta_cache() 5) http://paste.scsys.co.uk/83129 - this is variables dump, right before line 17 Error occurs only on first call to $self->cache->compute() for given args. Next calls with same args working fine, and don't throw any errors. Restarting app lead to error on first call again. Seems, this is related to CHI::set() only? Nevertheless, even with error, value in cache IS set. After exception call stack return control to Catalyst, and he ready to accept next request, and on next request I'm not only don't have error, but CHI::compute() give me correct value from cache. Will be glad to get any help or ideas. Thanks in advance, Good luck! -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Suddenly Failing with Moose and MOP Errors
/usr/local/share/perl/5.10.0/Catalyst.pm line 2523 > Catalyst::setup_component('GLR', 'GLR::Model::DB') called at > /usr/local/share/perl/5.10.0/Catalyst.pm line 2450 > Catalyst::setup_components('GLR') called at > /usr/local/share/perl/5.10.0/Catalyst.pm line 1179 > Catalyst::setup('GLR') called at > /var/www/sites/gordonlegalresearch.com/GLR-0.01/script/../lib/GLR.pm line > 120 > require GLR.pm called at /usr/local/lib/perl/5.10.0/Class/MOP.pm line 114 > Class::MOP::__ANON__() called at /usr/local/share/perl/5.10.0/Try/Tiny.pm > line 71 > eval {...} called at /usr/local/share/perl/5.10.0/Try/Tiny.pm line 67 > Try::Tiny::try('CODE(0x9b450e0)', 'Try::Tiny::Catch=REF(0xa52b128)') > called at /usr/local/lib/perl/5.10.0/Class/MOP.pm line 125 > Class::MOP::load_first_existing_class('GLR') called at > /usr/local/lib/perl/5.10.0/Class/MOP.pm line 137 > Class::MOP::load_class('GLR') called at > /usr/local/share/perl/5.10.0/Catalyst/ScriptRole.pm line 48 > > Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa54c678)') > called at /usr/local/share/perl/5.10.0/Catalyst/Script/Server.pm line 179 > Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa54c678)') > called at /usr/local/share/perl/5.10.0/Catalyst/ScriptRunner.pm line 20 > Catalyst::ScriptRunner::run('Catalyst::ScriptRunner', 'GLR', 'Server') > called at script/glr_server.pl line 8"Compilation failed in require at > /usr/local/lib/perl/5.10.0/Class/MOP.pm line 114. > at /usr/local/lib/perl/5.10.0/Class/MOP.pm line 120 > Class::MOP::__ANON__('Couldn\'t instantiate component "GLR::Model::DB", > "Couldn\'t ...') called at /usr/local/share/perl/5.10.0/Try/Tiny.pm line 100 > Try::Tiny::try('CODE(0x9b450e0)', 'Try::Tiny::Catch=REF(0xa52b128)') > called at /usr/local/lib/perl/5.10.0/Class/MOP.pm line 125 > Class::MOP::load_first_existing_class('GLR') called at > /usr/local/lib/perl/5.10.0/Class/MOP.pm line 137 > Class::MOP::load_class('GLR') called at > /usr/local/share/perl/5.10.0/Catalyst/ScriptRole.pm line 48 > > Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa54c678)') > called at /usr/local/share/perl/5.10.0/Catalyst/Script/Server.pm line 179 > Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa54c678)') > called at /usr/local/share/perl/5.10.0/Catalyst/ScriptRunner.pm line 20 > Catalyst::ScriptRunner::run('Catalyst::ScriptRunner', 'GLR', 'Server') > called at script/glr_server.pl line 8 > > > > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Suddenly Failing with Moose and MOP Errors
Yes, I know - but what if Eric used 0.7002 to generate files, as I did? ;) 2011/1/31 Justin Hunter : > if your DBIC schema is using Moose/MooseX::NonMoose, remove 'use > MooseX::NonMoose' from your base schema class. > http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=dbsrgits/DBIx-Class-Schema-Loader.git;a=commitdiff;h=49643e1dff62e16331c30f51953d548d94da1d30 addressed > this and any release beyond 0.07003 should generate properly. > > Justin > On Mon, Jan 31, 2011 at 1:36 PM, Oleg Kostyuk wrote: >> >> Seems, I had same problem. >> If your db schema classe (GLR::Schema) use Moose and MooseX::NonMoose, >> try to convert your schema classes to use strict/warning/base. >> If your schema class what generated by DBIx::Class::Schema::Loader, >> then upgrade it to latest and re-generate your classes. >> >> >> 2011/1/31 Eric Berg : >> > All of a sudden my application stopped working and started spewing >> > these >> > errors. This same code has been running for many days, then kblam! >> > Suddenly died. >> > >> > I've been looking and I can't seem to figure out what's going on. >> > >> > I suspect that it was an underlying Perl module that somehow blew up, >> > but >> > I'm not sure. >> > >> > Can anyone see anything in here that indicates what the problem is? >> > >> > Thanks. >> > >> > Eric >> > >> > Couldn't load class (GLR) because: Couldn't instantiate component >> > "GLR::Model::DB", "Couldn't load class (GLR::Schema) because: Can't call >> > method "isa" on an undefined value at >> > /usr/local/share/perl/5.10.0/MooseX/NonMoose/Meta/Role/Class.pm line 40. >> > Compilation failed in require at /usr/local/lib/perl/5.10.0/Class/MOP.pm >> > line 114. >> > at /usr/local/lib/perl/5.10.0/Class/MOP.pm line 120 >> > Class::MOP::__ANON__('Can\'t call method "isa" on an undefined value >> > at >> > /usr/local/...') called at /usr/local/share/perl/5.10.0/Try/Tiny.pm line >> > 100 >> > Try::Tiny::try('CODE(0xba03570)', 'Try::Tiny::Catch=REF(0xb9f52b8)') >> > called at /usr/local/lib/perl/5.10.0/Class/MOP.pm line 125 >> > Class::MOP::load_first_existing_class('GLR::Schema') called at >> > /usr/local/lib/perl/5.10.0/Class/MOP.pm line 137 >> > Class::MOP::load_class('GLR::Schema') called at >> > /usr/local/share/perl/5.10.0/Catalyst/Model/DBIC/Schema/Types.pm line 21 >> > Catalyst::Model::DBIC::Schema::Types::__ANON__('GLR::Schema') called >> > at >> > /usr/local/lib/perl/5.10.0/Moose/Meta/TypeCoercion.pm line 63 >> > Moose::Meta::TypeCoercion::__ANON__('GLR::Schema') called at >> > /usr/local/lib/perl/5.10.0/Moose/Meta/TypeCoercion.pm line 97 >> > >> > >> > Moose::Meta::TypeCoercion::coerce('Moose::Meta::TypeCoercion=HASH(0xae9a500)', >> > 'GLR::Schema') called at >> > /usr/local/lib/perl/5.10.0/Moose/Meta/TypeConstraint.pm line 90 >> > >> > >> > Moose::Meta::TypeConstraint::coerce('Moose::Meta::TypeConstraint=HASH(0xae8fb38)', >> > 'GLR::Schema') called at >> > /usr/local/share/perl/5.10.0/MooseX/Types/TypeDecorator.pm line 206 >> > eval {...} called at >> > /usr/local/share/perl/5.10.0/MooseX/Types/TypeDecorator.pm line 205 >> > >> > >> > MooseX::Types::TypeDecorator::AUTOLOAD('MooseX::Types::TypeDecorator=HASH(0xaea7520)', >> > 'GLR::Schema') called at >> > /usr/local/lib/perl/5.10.0/Moose/Meta/Attribute.pm >> > line 880 >> > >> > >> > Moose::Meta::Attribute::_coerce_and_verify('Moose::Meta::Attribute=HASH(0xaecb070)', >> > 'GLR::Schema', 'GLR::Model::DB=HASH(0xb9b20a0)') called at >> > /usr/local/lib/perl/5.10.0/Moose/Meta/Attribute.pm line 483 >> > >> > >> > Moose::Meta::Attribute::initialize_instance_slot('Moose::Meta::Attribute=HASH(0xaecb070)', >> > 'Moose::Meta::Instance=HASH(0xba1d3d0)', >> > 'GLR::Model::DB=HASH(0xb9b20a0)', >> > 'HASH(0xb9a4a90)') called at >> > /usr/local/lib/perl/5.10.0/Class/MOP/Class.pm >> > line 603 >> > >> > >> > Class::MOP::Class::_construct_instance('Moose::Meta::Class=HASH(0xadfb790)', >> > 'HASH(0xb9a4a90)') calle
Re: [Catalyst] Suddenly Failing with Moose and MOP Errors
I think, reading manuals for DBIx::Class::Schema::Loader and Catalyst::Manual::Tutorial::03_MoreCatalystBasics (#Create_Static_DBIx::Class_Schema_Files) also could be helpful. 2011/2/1 Peter Edwards : > On 1 February 2011 02:00, Eric Berg wrote: >> >> I used 5.80030 to generate my files..it's a pretty new app. >> >> Just removing MooseX::NonMoose from just my Schema.pm did the trick. >> >> How do we edit these generated classes (such as MyApp::Schema) considering >> the MD5 checks? Is there a protocol for making that kind of change? >> > I guess you would need to change the deploy files generated by > http://search.cpan.org/perldoc?DBIx::Class::Storage::DBI > Regards, Peter > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Something wrong in Catalyst::Model::DBIC::Schema?
el::Db', > 'PTest', 'HASH(0x8048a54f8)') called at > /usr/local/lib/perl5/site_perl/5.12.3/CatalystX/Component/Traits.pm line 145 > CatalystX::Component::Traits::COMPONENT('PTest::Model::Db', 'PTest', > 'HASH(0x80489d780)') called at > /usr/local/lib/perl5/site_perl/5.12.3/mach/Class/MOP/Method/Wrapped.pm line > 48 > Class::MOP::Method::Wrapped::__ANON__('PTest::Model::Db', 'PTest', > 'HASH(0x80489d780)') called at > /usr/local/lib/perl5/site_perl/5.12.3/mach/Class/MOP/Method/Wrapped.pm line > 89 > Catalyst::Model::DBIC::Schema::COMPONENT('PTest::Model::Db', 'PTest', > 'HASH(0x80489d780)') called at > /usr/local/lib/perl5/site_perl/5.12.3/Catalyst.pm line 2523 > eval {...} called at > /usr/local/lib/perl5/site_perl/5.12.3/Catalyst.pm line 2523 > Catalyst::setup_component('PTest', 'PTest::Model::Db') called at > /usr/local/lib/perl5/site_perl/5.12.3/Catalyst.pm line 2450 > Catalyst::setup_components('PTest') called at > /usr/local/lib/perl5/site_perl/5.12.3/Catalyst.pm line 1179 > Catalyst::setup('PTest') called at > /usr/home/tarkhil/work/PTest/script/../lib/PTest.pm line 45 > require PTest.pm called at > /usr/local/lib/perl5/site_perl/5.12.3/mach/Class/MOP.pm line 114 > Class::MOP::__ANON__() called at > /usr/local/lib/perl5/site_perl/5.12.3/Try/Tiny.pm line 71 > eval {...} called at > /usr/local/lib/perl5/site_perl/5.12.3/Try/Tiny.pm line 67 > Try::Tiny::try('CODE(0x801039690)', > 'Try::Tiny::Catch=REF(0x803b65780)') called at > /usr/local/lib/perl5/site_perl/5.12.3/mach/Class/MOP.pm line 125 > Class::MOP::load_first_existing_class('PTest') called at > /usr/local/lib/perl5/site_perl/5.12.3/mach/Class/MOP.pm line 137 > Class::MOP::load_class('PTest') called at > /usr/local/lib/perl5/site_perl/5.12.3/Catalyst/ScriptRole.pm line 48 > > Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0x8025654f8)') > called at /usr/local/lib/perl5/site_perl/5.12.3/Catalyst/Script/Server.pm > line 179 > > Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0x8025654f8)') > called at /usr/local/lib/perl5/site_perl/5.12.3/Catalyst/ScriptRunner.pm > line 20 > Catalyst::ScriptRunner::run('Catalyst::ScriptRunner', 'PTest', > 'Server') called at ./script/ptest_server.pl line 8"Compilation failed in > require at /usr/local/lib/perl5/site_perl/5.12.3/mach/Class/MOP.pm line 114. > at /usr/local/lib/perl5/site_perl/5.12.3/mach/Class/MOP.pm line 120 > Class::MOP::__ANON__('Couldn\'t instantiate component > "PTest::Model::Db", "Couldn\'...') called at > /usr/local/lib/perl5/site_perl/5.12.3/Try/Tiny.pm line 100 > Try::Tiny::try('CODE(0x801039690)', > 'Try::Tiny::Catch=REF(0x803b65780)') called at > /usr/local/lib/perl5/site_perl/5.12.3/mach/Class/MOP.pm line 125 > Class::MOP::load_first_existing_class('PTest') called at > /usr/local/lib/perl5/site_perl/5.12.3/mach/Class/MOP.pm line 137 > Class::MOP::load_class('PTest') called at > /usr/local/lib/perl5/site_perl/5.12.3/Catalyst/ScriptRole.pm line 48 > > Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0x8025654f8)') > called at /usr/local/lib/perl5/site_perl/5.12.3/Catalyst/Script/Server.pm > line 179 > > Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0x8025654f8)') > called at /usr/local/lib/perl5/site_perl/5.12.3/Catalyst/ScriptRunner.pm > line 20 > Catalyst::ScriptRunner::run('Catalyst::ScriptRunner', 'PTest', > 'Server') called at ./script/ptest_server.pl line 8 > > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Moose Upgrade
2011/4/18 Oleg A. Mamontov : > > On Apr 18, 2011, at 6:55 AM, Dave Rolsky wrote: > >> On Sun, 17 Apr 2011, John M. Dlugosz wrote: >> >>> I just updated Moose to 2, on my development system, prepatory to doing >>> some Moose explorations. >>> Catalyst didn't like it one bit. I'm still installing other updates based >>> on things mentioned in errors, when I try and run script/myapp_server. >>> >>> Any specific advice? >> >> You probably have a bunch of conflicting MooseX modules installed. >> Unfortunately, the warnings from Moose's Makefile.PL are easy to miss (and I >> think cpanm hides them entirely :( >> >> Running "moose-outdated | cpanm" should upgrade everything that needs >> upgrading. > > Probably you meant "cpan-outdated | cpanm" ? Most probably, no. See http://search.cpan.org/~doy/Moose-2./lib/Moose/Manual/Delta.pod#2., "Moose's conflict checking is more robust and useful" for more details. > >> >>> I see the latest Catalyst::Runtime is marked TRIAL. Should I use a >>> different one on the server? >> >> I've been using this one for dev for a while, and it works fine. If by >> "server" you mean "production", then conservatism is not a bad thing. >> >> >> -dave >> >> /* >> http://VegGuide.org http://blog.urth.org >> Your guide to all that's veg House Absolute(ly Pointless) >> */ >> >> ___ >> List: Catalyst@lists.scsys.co.uk >> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst >> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ >> Dev site: http://dev.catalyst.perl.org/ > > > -- > Cheers, > Oleg A. Mamontov > > mailto: o...@mamontov.net > > jabber: lon...@charla.mamontov.net > icq uin: 79-521-617 > cell: +7-903-798-1352 > > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] DBIx::HA
2011/10/13 clara resende : > > > On Thu, Oct 13, 2011 at 4:31 PM, Peter Edwards > wrote: >> >> >I need to be able to failover between two database backends. >> If you are using DBIx::Class it will reconnect stale database handles, so >> as long as your failover uses the same DSN hostname it should just work. > > That would be nice, but unfortunately it does not work like that over here Why? Impropely configured DNS? > (and I cannot do anything about that). It's not true. Even if your DNS server working not as you need - you always can setup your own local BIND, configure it to use round-robin, configure new zone in it, add all your database hosts under same hostname, and everything will be fine. But I think such details are out of scope this mailing list. >>> The DBIx::HA seems to be the right tool to that, but how to use it with >>> Catalyst? >>> >> You can use any database backend you like with Catalyst, check out the >> Model configuration part of the Catalyst manual. >> That particular module needs Apache::DBI so won't be compatible with >> DBIx::Class though. > > Isn't there another way achieve this, with DBIx-Class, similar to what the > HA module does? May be, DBIx::Class::Storage::DBI::Replicated ?... -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] [ANNOUNCE] Catalyst-Runtime-5.90005
I looked at diff to previous version via CPAN (http://goo.gl/BlHhv), and part that is related to lib/Catalyst.pm seems like not finished, as for me. May be, this is because I'm not native English speaker? Here is relevant part: @@ -1429,6 +1385,30 @@ You can use: and it will create the URI /users/the-list. +=item \@captures_and_args? + +Optional array reference of Captures (i.e. C<req->captures>) +and arguments to the request. Usually used with L +to interpolate all the parameters in the URI. + +=item @args? + +Optional list of extra arguments - can be supplied in the C<< \@captures_and_args? >> +array ref, or here - whichever is easier for your code.. + +If your action may have a zero, a fixed or a variable number of args (e.g. C<< Args(1) >> +for a fixed number or C<< Args() >> for a variable number).. + +=item \%query_values? Looks, like in "=item @args?" description, in second paragraph should be "If your action ..., then ...". But there is no "then", and there are two points at the end - what this should mean? Thanks for as always great release! 2011/10/23 Tomas Doran : > I'm pleased to announce the latest maintenance release of Catalyst-Runtime: > 5.90005 > > This release contains a couple of new features, and a number of > documentation improvements. Thanks to all the contributors for all the the > patches which make up this release. > > Full changelog is included below. > > Cheers > t0m > > 5.90005 - 2011-10-22 13:35:00 > > New features: > > - $c->uri_for_action can now take an array of CaptureArgs and Args > If you have an action which has both, then you can now say: > $c->uri_for_action('/myaction', [@captures, @args]); > whereas before you had to say: > $c->uri_for_action('/myaction', [@captures], @args); > The previous form is still supported, however in many cases it is > easier for the application code to not have to differentiate between > the two. > > - Catalyst::ScriptRunner has been enhanced so that it will now > load and apply traits, making it easier to customise. > - MyApp::TraitFor::Script (if it exists) will be applied to all > scripts in the application. > - MyApp::TraitFor::Script:: will be applied to the relevant script > (for example MyApp::TraitFor::Script::Server will be applied to > MyApp::Script::Server if it exists, or Catalyst::Script::Server > otherwise). > > Documentation: > > - Document how to get the vhost of the request in $c->req->hostname > to avoid confusion > - Remove documentation showing Global / Regex / Private actionsi > as whilst these still exist (and work), they are not recommended. > - Remove references to the -Engine flag. > - Remove references to the deprecated Catalyst->plugin method > - Spelling fixed (and tested) throughout the documentation > - Note that wrapping the setup method will not work with method modifiers > and provide an alternative. > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ > -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] New catalystframework.org
Looks good, thanks! But I have several notes :) 1) it don't fit into 1600x1200 (by height) - and so, it will not fit into smaller screens. I think, main page should be bit smaller, and should fit into 1280x1024 at max. I think it will look even better, if information will be a bit more condensed. 2) phrase "fun, rewarding and quick" looks like link, but this is just text - compare with "Download", "Install", "Tutorial" on right. 3) image deployment_os_logos.png looks very strange, as for me. why Windows get more space than all others? :) Give more space for Linux and FreeBSD! :)) Also, seems Solaris is RIP and so not actual anymore?.. 4) Would you like to switch to use Bootstrap, and implement responsive page? For now, content width seems to be fixed at 960px, and I think it should be not very good on smartphones. Thanks for your effort! 13 марта 2012 г. 18:59 пользователь Devin Austin написал: > On Tue, Mar 13, 2012 at 10:19 AM, Len Jaffe wrote: >> Pretty sweet. >> Nice work. >> Thank you for doing the heavy lifting. >> >> L. >> -- >> lenja...@jaffesystems.com 614-404-4214 >> Proprietor: http://www.theycomewithcheese.com/ - An Homage to Fromage >> Greenbar: Grubmaster: 2012, 2011, 2010, 2009, Grub Asst: 2008, Trained: >> 2007. >> >> >> ___ >> List: Catalyst@lists.scsys.co.uk >> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst >> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ >> Dev site: http://dev.catalyst.perl.org/ >> > > I like it. Checked it out on my iPhone and it all looks pretty good. Well > done! > > -- > Devin Austin > http://www.dhoss.net > 9702906669 - Cell > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] New catalystframework.org
Bwt, guys - would you like to switch to GitHub? If nobody have time for this - I can do repo conversion. 13 марта 2012 г. 20:29 пользователь Oleg Kostyuk написал: > Looks good, thanks! > > But I have several notes :) > > 1) it don't fit into 1600x1200 (by height) - and so, it will not fit > into smaller screens. I think, main page should be bit smaller, and > should fit into 1280x1024 at max. I think it will look even better, if > information will be a bit more condensed. > > 2) phrase "fun, rewarding and quick" looks like link, but this is just > text - compare with "Download", "Install", "Tutorial" on right. > > 3) image deployment_os_logos.png looks very strange, as for me. why > Windows get more space than all others? :) Give more space for Linux > and FreeBSD! :)) Also, seems Solaris is RIP and so not actual > anymore?.. > > 4) Would you like to switch to use Bootstrap, and implement responsive > page? For now, content width seems to be fixed at 960px, and I think > it should be not very good on smartphones. > > Thanks for your effort! > > > 13 марта 2012 г. 18:59 пользователь Devin Austin > написал: >> On Tue, Mar 13, 2012 at 10:19 AM, Len Jaffe >> wrote: >>> Pretty sweet. >>> Nice work. >>> Thank you for doing the heavy lifting. >>> >>> L. >>> -- >>> lenja...@jaffesystems.com 614-404-4214 >>> Proprietor: http://www.theycomewithcheese.com/ - An Homage to Fromage >>> Greenbar: Grubmaster: 2012, 2011, 2010, 2009, Grub Asst: 2008, Trained: >>> 2007. >>> >>> >>> ___ >>> List: Catalyst@lists.scsys.co.uk >>> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst >>> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ >>> Dev site: http://dev.catalyst.perl.org/ >>> >> >> I like it. Checked it out on my iPhone and it all looks pretty good. Well >> done! >> >> -- >> Devin Austin >> http://www.dhoss.net >> 9702906669 - Cell >> >> _______ >> List: Catalyst@lists.scsys.co.uk >> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst >> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ >> Dev site: http://dev.catalyst.perl.org/ > > > > -- > Sincerely yours, > Oleg Kostyuk (CUB-UANIC) -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] New catalystframework.org
14 марта 2012 г. 12:19 пользователь Tomas Doran написал: > > On 13 Mar 2012, at 18:33, Oleg Kostyuk wrote: > >> Bwt, guys - would you like to switch to GitHub? >> If nobody have time for this - I can do repo conversion. > > To git, sure. Things are being slowly converted as people care - if you care > please push a conversion up to github (we've got a fairly comprehensive > authors file already) for review, I'd be happy to review / push it into the > catalyst git cluster when we're all happy. Ok, but you know - for conversion I need this authors file. How I can get it? It is in the public domain? > > Assuming that the people working on the site are happy with / would like to > move to git. Toby? > > To github - not so much, other than as a mirror. There's already a Catalyst > git cluster :) > > Cheers > t0m > > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] New catalystframework.org
Hello Tomas, Seems these accounts are in SVN history, but absent in authors file: andyg dnm dwc hobbs jhannah jrockway jshirley kixx marcus matthewt mdk phaylon soulchild sri t0m tom_m yacoob zarquon Some of them are well-know developers, and most probably I can add them into authors file without your help. But only some, not all. And so I have to ask you - could you please update authors file? Thanks! 15 марта 2012 г. 11:47 пользователь Tomas Doran написал: > > On 14 Mar 2012, at 13:20, Oleg Kostyuk wrote: > >> 14 марта 2012 г. 12:19 пользователь Tomas Doran >> написал: >>> >>> On 13 Mar 2012, at 18:33, Oleg Kostyuk wrote: >>> >>>> Bwt, guys - would you like to switch to GitHub? >>>> If nobody have time for this - I can do repo conversion. >>> >>> To git, sure. Things are being slowly converted as people care - if you >>> care please push a conversion up to github (we've got a fairly >>> comprehensive authors file already) for review, I'd be happy to review / >>> push it into the catalyst git cluster when we're all happy. >> >> Ok, but you know - for conversion I need this authors file. How I can >> get it? It is in the public domain? >> > > http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits/gitosis-admin.git;a=blob;f=authors;h=9b63ce4a81c7e7fc4703519cc248bfc221d508bb;hb=HEAD > > Could do with a little updating - all the entries being used are confirmed. > > Cheers > t0m > > > ___ > List: Catalyst@lists.scsys.co.uk > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ > Dev site: http://dev.catalyst.perl.org/ -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Patch for Catalyst-Action-REST-0.63 distro
Hello! I just experienced problems with upgrading Catalyst::Action::REST to 0.63: ... *** Module::AutoInstall configuration finished. ERROR: perl: Version 5.008008 is installed, but we need version >= 5.8 at inc/Module/Install/Makefile.pm line 172. Following patch fixes this error: tux# diff -u inc/Module/Install/Makefile.pm.orig inc/Module/Install/Makefile.pm --- inc/Module/Install/Makefile.pm.orig 2008-08-13 16:39:22.0 +0300 +++ inc/Module/Install/Makefile.pm 2008-08-13 16:47:23.0 +0300 @@ -170,7 +170,7 @@ } if ( my $perl_version = $self->perl_version ) { - eval "use $perl_version; 1" + eval "use v$perl_version; 1" or die "ERROR: perl: Version $] is installed, " . "but we need version >= $perl_version"; } tux# -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Patch for Catalyst-Action-REST-0.63 distro
Created ticket in RT for Module::Install distro: http://rt.cpan.org/Ticket/Display.html?id=38443 -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Patch for Catalyst/Engine/FastCGI.pm
Little POD update - tux ~ # diff -u /usr/lib/perl5/vendor_perl/5.8.8/Catalyst/Engine/FastCGI.pm* --- /usr/lib/perl5/vendor_perl/5.8.8/Catalyst/Engine/FastCGI.pm 2008-07-31 03:45:35.0 +0300 +++ /usr/lib/perl5/vendor_perl/5.8.8/Catalyst/Engine/FastCGI.pm.new 2008-09-19 01:44:08.0 +0300 @@ -44,7 +44,9 @@ =item leave_umask -Set to 1 to disable setting umask to 0 for socket open =item nointr +Set to 1 to disable setting umask to 0 for socket open + +=item nointr Do not allow the listener to be interrupted by Ctrl+C - -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Conditional GET with Catalyst::Controller::REST
> Short version is that everything works beautifully when > doing a HEAD, and my 304 is happily returned, but the same > code on a GET causes a 500, with nothing helpful logged. > Code snippet is: > > sub index_GET { >my ($self, $c) = @_; >my $sset = $c->stash->{sset} or return; Probably, when "return" is executed - you'll get unexpected result. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Re: Feature Request: Parameter Junctions
2008/10/22 Aristotle Pagaltzis <[EMAIL PROTECTED]>: > I outlined a proposal a long time ago of two different methods > like the current `param`, one which always returned a single > value (the last one if there are multiple) and one which always > returned an arrayref. Then there could be no confusion and code > would always get exactly what it was written to expect. Matt > agreed but punted to volunteers, and none stepped up, me > included, so it has yet to happen. Could you please give link to your original thread ? -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] [Announce] Catalyst::Runtime 5.7099_04. IMPORTANT; PLEASE TEST!
Hello, here is 2 cents from me: 1) release directory is not cleaned from *.rej files: Catalyst-Runtime-5.7099_04 % find . | fgrep .rej | wc -l 5 2) added ru and ua translations (see in attachment) -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) Index: lib/Catalyst/Engine.pm === --- lib/Catalyst/Engine.pm (revision 9082) +++ lib/Catalyst/Engine.pm (working copy) @@ -158,6 +158,8 @@ (dk) Venligst prov igen senere (pl) Prosze sprobowac pozniej (pt) Por favor volte mais tarde +(ru) ÐопÑобÑйÑе еÑе Ñаз позже +(ua) СпÑобÑйÑе Ñе Ñаз пÑзнÑÑе $name = ''; ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] [Announce] Catalyst::Runtime 5.7099_04. IMPORTANT; PLEASE TEST!
2009/1/14 Andrew Rodland : > On Tuesday 13 January 2009 08:31:07 pm Greg Matheson wrote: >> On Tue, 13 Jan 2009, Oleg Kostyuk wrote: >> > 2) added ru and ua translations (see in attachment) >> > >> So that's where those messages are! >> Here's some non-native Chinese and Japanese ones. > > I don't know if it was a mistake or a really subtle joke, but all non-Latin > text in your email was sent as question-marks. You mean my email also, or only email from Greg? -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] [Announce] Catalyst::Runtime 5.7099_04. IMPORTANT; PLEASE TEST!
Here is another my 2 cents (in attachment). This patch allow to use more than 80 chars in tables output, like list of loaded components or actions - width will be auto-selected based on terminal width or on enviroment variable. Useful and convenient for debugging, imho. Feel free to correct either POD and code. Some explanation about selected values for constants: 1) use constant WIDTH_MAX => 110; I tried to use wider values, and as for me it looks worse - too wide :) May be, 120... Anyway, this value should not be more that 130, imho. Probably, you'll want to try change it by yourself and find more appropriate value. 2) use constant WIDTH_MIN => 70; For some reason with too narrow screens I got 99% CPU load O_o Seems like minor bug with Text::SimpleTable, when calculated width (my $column_width) is 0 or negative. Imho, in such case Text::SimpleTable should assume width with value 1, but it don't. I don't looked into it really, this is only assumption. And having WIDTH_MIN is simplest way to avoid such cases, I think. Will be glad to hear some feedback :) -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) diff -ur 1/usr/local/share/perl/5.10.0/Catalyst/Dispatcher.pm 2/usr/local/share/perl/5.10.0/Catalyst/Dispatcher.pm --- 1/usr/local/share/perl/5.10.0/Catalyst/Dispatcher.pm 2009-01-05 23:41:35.0 +0200 +++ 2/usr/local/share/perl/5.10.0/Catalyst/Dispatcher.pm 2009-01-06 08:30:16.0 +0200 @@ -8,6 +8,7 @@ use Catalyst::ActionContainer; use Catalyst::DispatchType::Default; use Catalyst::DispatchType::Index; +use Catalyst::Utils (); use Text::SimpleTable; use Tree::Simple; use Tree::Simple::Visitor::FindByPath; @@ -474,10 +475,11 @@ return unless $c->debug; +my $column_width = Catalyst::Utils::term_width() - 20 - 36 - 12; my $privates = Text::SimpleTable->new( [ 20, 'Private' ], [ 36, 'Class' ], -[ 12, 'Method' ] +[ $column_width, 'Method' ] ); my $has_private = 0; diff -ur 1/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Chained.pm 2/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Chained.pm --- 1/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Chained.pm 2009-01-06 07:40:14.0 +0200 +++ 2/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Chained.pm 2009-01-06 08:30:25.0 +0200 @@ -4,6 +4,7 @@ use base qw/Catalyst::DispatchType/; use Text::SimpleTable; use Catalyst::ActionChain; +use Catalyst::Utils (); use URI; # please don't perltidy this. hairy code within. @@ -43,8 +44,10 @@ return unless $self->{endpoints}; +my $column_width = Catalyst::Utils::term_width() - 35 - 9; my $paths = Text::SimpleTable->new( -[ 35, 'Path Spec' ], [ 36, 'Private' ] +[ 35, 'Path Spec' ], +[ $column_width, 'Private' ] ); ENDPOINT: foreach my $endpoint ( diff -ur 1/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Path.pm 2/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Path.pm --- 1/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Path.pm 2009-01-06 07:39:05.0 +0200 +++ 2/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Path.pm 2009-01-06 08:30:45.0 +0200 @@ -3,6 +3,7 @@ use strict; use base qw/Catalyst::DispatchType/; use Text::SimpleTable; +use Catalyst::Utils (); use URI; =head1 NAME @@ -25,7 +26,11 @@ sub list { my ( $self, $c ) = @_; -my $paths = Text::SimpleTable->new( [ 35, 'Path' ], [ 36, 'Private' ] ); +my $column_width = Catalyst::Utils::term_width() - 35 - 9; +my $paths = Text::SimpleTable->new( +[ 35, 'Path' ], +[ $column_width, 'Private' ] +); foreach my $path ( sort keys %{ $self->{paths} } ) { my $display_path = $path eq '/' ? $path : "/$path"; foreach my $action ( @{ $self->{paths}->{$path} } ) { diff -ur 1/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Regex.pm 2/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Regex.pm --- 1/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Regex.pm 2009-01-06 07:41:13.0 +0200 +++ 2/usr/local/share/perl/5.10.0/Catalyst/DispatchType/Regex.pm 2009-01-06 08:30:55.0 +0200 @@ -3,6 +3,7 @@ use strict; use base qw/Catalyst::DispatchType::Path/; use Text::SimpleTable; +use Catalyst::Utils (); use Text::Balanced (); =head1 NAME @@ -25,7 +26,11 @@ sub list { my ( $self, $c ) = @_; -my $re = Text::SimpleTable->new( [ 35, 'Regex' ], [ 36, 'Private' ] ); +my $column_width = Catalyst::Utils::term_width() - 35 - 9; +my $re = Text::SimpleTable->new( +[ 35, 'Regex' ], +[ $column_width, 'Private' ] +); for my $regex ( @{ $self->{compiled} } ) { my $action = $regex->{actio
[Catalyst] [PATCH] Catalyst::DispatchType::Chained (5.7101, 5.80001)
This bug is present in 5.7101: created Text::SimpleTable with 3 columns, while we need only two. == --- Catalyst/DispatchType/Chained.pm.orig 2009-04-20 04:48:31.0 +0300 +++ Catalyst/DispatchType/Chained.pm2009-04-20 04:57:43.0 +0300 @@ -46,7 +46,7 @@ my $column_width = Catalyst::Utils::term_width() - 35 - 9; my $paths = Text::SimpleTable->new( - [ 35, 'Path Spec' ], [ 36, 'Private' ], [ $column_width, 'Private' ] + [ 35, 'Path Spec' ], [ $column_width, 'Private' ] ); ENDPOINT: foreach my $endpoint ( == As I see, we don't have this error in 5.80001, but we have other error nearly to same place: == --- Chained.pm.orig 2009-04-20 05:10:24.0 +0300 +++ Chained.pm 2009-04-20 05:11:17.0 +0300 @@ -86,7 +86,7 @@ my $has_unattached_actions; my $unattached_actions = Text::SimpleTable->new( -[ 35, 'Private' ], [ 36, 'Missing parent' ], +[ 35, 'Private' ], [ $column_width, 'Missing parent' ], ); ENDPOINT: foreach my $endpoint ( == PS: probably, it's needed to check all other places, that use Text::SimpleTable -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] [PATCH] Catalyst::DispatchType::Chained (5.7101, 5.80001)
2009/4/20 Matt S Trout : > On Mon, Apr 20, 2009 at 05:16:55AM +0300, Oleg Kostyuk wrote: >> PS: probably, it's needed to check all other places, that use >> Text::SimpleTable > > That'd be well worth doing. Please send us a patch if you find any more when > you check them :) Sure, why not :) New patch attached. We need one more dependency to get this working, Text::SimpleTable::AutoWidth. Feel free to patch my patch :) by changing fixed_width to max_width and vice versa, if you think that that will looks better. Tables that created with "max_width" will be not wider than needed, and tables that created with "fixed_width" will be always all terminal wide. Any feedback welcome. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) diff -ru cat.orig/Catalyst/Dispatcher.pm cat.new/Catalyst/Dispatcher.pm --- cat.orig/Catalyst/Dispatcher.pm 2009-04-20 06:42:26.0 +0300 +++ cat.new/Catalyst/Dispatcher.pm 2009-04-20 21:52:01.0 +0300 @@ -11,7 +11,7 @@ use Catalyst::DispatchType::Default; use Catalyst::DispatchType::Index; use Catalyst::Utils; -use Text::SimpleTable; +use Text::SimpleTable::AutoWidth; use Tree::Simple; use Tree::Simple::Visitor::FindByPath; @@ -605,9 +605,9 @@ sub _display_action_tables { my ($self, $c) = @_; -my $column_width = Catalyst::Utils::term_width() - 36 - 36 - 12; -my $privates = Text::SimpleTable->new( -[ 36, 'Private' ], [ 36, 'Class' ], [ $column_width, 'Method' ] +my $privates = Text::SimpleTable::AutoWidth->new( +max_width => Catalyst::Utils::term_width(), +captions => ['Private', 'Class', 'Method'], ); my $has_private = 0; diff -ru cat.orig/Catalyst/DispatchType/Chained.pm cat.new/Catalyst/DispatchType/Chained.pm --- cat.orig/Catalyst/DispatchType/Chained.pm 2009-04-20 06:31:47.0 +0300 +++ cat.new/Catalyst/DispatchType/Chained.pm 2009-04-20 21:50:05.0 +0300 @@ -3,7 +3,7 @@ use Moose; extends 'Catalyst::DispatchType'; -use Text::SimpleTable; +use Text::SimpleTable::AutoWidth; use Catalyst::ActionChain; use Catalyst::Utils; use URI; @@ -79,14 +79,15 @@ return unless $self->_endpoints; -my $column_width = Catalyst::Utils::term_width() - 35 - 9; -my $paths = Text::SimpleTable->new( - [ 35, 'Path Spec' ], [ $column_width, 'Private' ], +my $paths = Text::SimpleTable::AutoWidth->new( +max_width => Catalyst::Utils::term_width(), +captions => ['Path Spec', 'Private'], ); my $has_unattached_actions; -my $unattached_actions = Text::SimpleTable->new( -[ 35, 'Private' ], [ $column_width, 'Missing parent' ], +my $unattached_actions = Text::SimpleTable::AutoWidth->new( +max_width => Catalyst::Utils::term_width(), +captions => ['Private', 'Missing parent'], ); ENDPOINT: foreach my $endpoint ( diff -ru cat.orig/Catalyst/DispatchType/Path.pm cat.new/Catalyst/DispatchType/Path.pm --- cat.orig/Catalyst/DispatchType/Path.pm 2009-04-18 12:09:56.0 +0300 +++ cat.new/Catalyst/DispatchType/Path.pm 2009-04-20 21:51:41.0 +0300 @@ -3,7 +3,7 @@ use Moose; extends 'Catalyst::DispatchType'; -use Text::SimpleTable; +use Text::SimpleTable::AutoWidth; use Catalyst::Utils; use URI; @@ -47,9 +47,9 @@ sub list { my ( $self, $c ) = @_; -my $column_width = Catalyst::Utils::term_width() - 35 - 9; -my $paths = Text::SimpleTable->new( - [ 35, 'Path' ], [ $column_width, 'Private' ] +my $paths = Text::SimpleTable::AutoWidth->new( +max_width => Catalyst::Utils::term_width(), +captions => ['Path', 'Private'], ); foreach my $path ( sort keys %{ $self->_paths } ) { my $display_path = $path eq '/' ? $path : "/$path"; diff -ru cat.orig/Catalyst/DispatchType/Regex.pm cat.new/Catalyst/DispatchType/Regex.pm --- cat.orig/Catalyst/DispatchType/Regex.pm 2009-04-18 12:09:56.0 +0300 +++ cat.new/Catalyst/DispatchType/Regex.pm 2009-04-20 21:51:32.0 +0300 @@ -3,7 +3,7 @@ use Moose; extends 'Catalyst::DispatchType::Path'; -use Text::SimpleTable; +use Text::SimpleTable::AutoWidth; use Catalyst::Utils; use Text::Balanced (); @@ -47,8 +47,10 @@ sub list { my ( $self, $c ) = @_; -my $column_width = Catalyst::Utils::term_width() - 35 - 9; -my $re = Text::SimpleTable->new( [ 35, 'Regex' ], [ $column_width, 'Private' ] ); +my $re = Text::SimpleTable::AutoWidth->new( +max_width => Catalyst::Utils::term_width(), +captions => ['Regex', 'Private'], +); for my $regex ( @{ $self->_compiled } ) { my $acti
Re: [Catalyst] [PATCH] Catalyst::DispatchType::Chained (5.7101, 5.80001)
> I don't think that was what Matt asked for. Anyways, > 1) Why can't your changes be a patch to Text::SimpleTable? I think that new module will be better in this case, because someone else can be needed unchanged Text::SimpleTable. > 2) Text::SimpleTable::AutoWidth uses Moose and Text::SimpleTable without > declaring so in the Makefile.PL Will be fixed now, thanks. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Problem with reloading in fresh project (5.80001)
Hello, all. I found problem after upgrading to 5.80001. Here is steps to reproduce it: - create new application, for example "catalyst.pl Test" - run dev server in one terminal, "./script/test_server.pl -r" - in other terminal make "touch test.conf" in application directory, and server will restart without problems - in other terminal try "touch ./lib/Test.pm", and you will see following error: File "/tmp/tt/Test/lib/Test.pm" modified, not restarting Inconsistent hierarchy during C3 merge of class 'Test': merging failed on parent 'Catalyst' at /usr/share/perl/5.10/mro.pm line 26. Compilation failed in require at (eval 481) line 1. Really, I not write any new code, but server can't restart. I'm sure that this is not expected behaviour. Is this known bug? Unfortunately, I'm not familiar with C3 and/or MRO, so can't create patch for this - hope someone else can do. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] [PATCH] Catalyst::DispatchType::Chained (5.7101, 5.80001)
2009/4/20 Lars Balker Rasmussen : > On Mon, Apr 20, 2009 at 9:58 PM, Oleg Kostyuk wrote: > > May I suggest: > > my $t1 = Text::SimpleTable->new( 5, 10 ); > my $t2 = Text::SimpleTable->new( [ 5, 'Foo' ], [ 10, 'Bar' ] ); > my $t3 = Text::SimpleTable::AutoWidth->new( { > max_width => 40, > captions => [qw/Foo Bar Baz/], > } ); > > Backwards compatible, easy to test for. Not sure that understood what you mean here. Please, explain little bit more. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] [PATCH] Catalyst::DispatchType::Chained (5.7101, 5.80001)
2009/4/20 Lars Balker Rasmussen : > On Mon, Apr 20, 2009 at 10:19 PM, Oleg Kostyuk wrote: > I meant, it's easy to extend the Text::SimpleTable API without breaking > backwards compatibility. Well, I did it that way because it's seems more logical to me, and definitely not break any compatibility, isn't? :) Anyway, this question is not really directly related to my patch in this topic. I just give you idea and provide working patch. You like it - you apply it. You not like it - you rewrite or just drop it. Fell free to reimplement same functionality as patch to Text::SimpleTable, if you want and have time :) -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Catalyst::Manual v5.8000 Now On CPAN
Hi all, http://search.cpan.org/dist/Catalyst-Manual/lib/Catalyst/Manual/Cookbook.pod#Authentication_(logging_in) have link to old Catalyst::Manual::Tutorial::Authorization from Catalyst-Manual-5.7014 -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Typo in Catalyst::Helper pod, patch included
==cut== --- /usr/local/share/perl/5.10.0/Catalyst/Helper.pm 2009-06-29 00:56:35.0 +0300 +++ /tmp/Helper.pm 2009-07-29 19:59:57.0 +0300 @@ -604,7 +604,7 @@ This method is called by L to make new components for your application. -=head3 mk_dir ($path) +=head2 mk_dir ($path) Surprisingly, this function makes a directory. ==cut== -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
[Catalyst] Possible error in DBIx::Class::TimeStamp
Hello guys, I'm looking at this part of DBIx/Class/TimeStamp.pm : = cut = sub add_columns { my ($self, @cols) = @_; my @columns; while (my $col = shift @cols) { my $info = ref $cols[0] ? shift @cols : {}; if ( delete $info->{set_on_create} ) { $info->{dynamic_default_on_create} = 'get_timestamp'; } if ( delete $info->{set_on_update} ) { $info->{dynamic_default_on_update} = 'get_timestamp'; # !!! (1) if ( defined $info->{dynamic_default_on_create} and $info->{dynamic_default_on_create} eq 'get_timestamp' ) { $info->{dynamic_default_on_update} = 'get_timestamp'; # !!! (2) } } push @columns, $col => $info; } return $self->next::method(@columns); } = cut = And can't understood, why we need (2), if we already did exactly same thing in (1) ? May be, there is some error? As for me, following code have more sence: = cut = if ( delete $info->{set_on_update} ) { $info->{dynamic_default_on_update} = 'get_timestamp'; unless ( defined $info->{dynamic_default_on_create} and $info->{dynamic_default_on_create} eq 'get_timestamp' ) { $info->{dynamic_default_on_create} = 'get_timestamp'; } } = cut = I'm using: % pmvers DBIx::Class 0.08108 Could anyone explain me, what going on here? Thanks in advance. -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/
Re: [Catalyst] Possible error in DBIx::Class::TimeStamp
Sorry, this was accidentally -- Sincerely yours, Oleg Kostyuk (CUB-UANIC) ___ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/