Re: [Catalyst] Mmap of shared file Operation not permitted

2007-08-27 Thread Kiki
Dennis Daupert wrote:
 I had not changed anything on the hosted site, but noticed the
 apache2 error log statement. I upgraded the OS -- debian etch --
 upgraded all perl modules, noticed I could not install
 Catalyst-Plugin-Session-Store-FastMmap as root using CPAN.pm.
 I got same error as above:

 t/basicok 1/20Mmap of shared file
 /tmp/sessionstoretest/session_data failed: Operation not permitted at
 /usr/lib/perl5/Cache/FastMmap.pm line 496.

 I'll switch to another news group if need be, but I wanted to
 first check this list. I am not (yet) well-schooled on just
 how Cache/FastMmap works, or why he's not allowed to do that
 operation.

If /tmp is mounted with the 'noexec' option, a mmap with PROT_EXEC will
fail with EPERM which translates to the above error message. Dunno, if
that's the case for Cache::FastMmap but I would still check mount
options for /tmp


___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Template rendering error under mod_perl

2007-06-29 Thread Kiki
Richard Jones wrote:
 Having developed my application sufficiently to see it working well so
 far, I though I should configure it to run under mod_perl. I have used
 the TTSite helper to generate the templates. The app runs fine using
 myapp_server.pl, but under mod_perl I get the following:

 Couldn't render template file error - login.tt2: not found

Could be a permission issue, has the user the webserver runs under
access to that path / those files?


___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


[Catalyst] [OT] Applying patches under Win32

2007-05-10 Thread Kiki
 Thank you for this solution. I hope I will be able to apply it.

 BTW (and sorry for off topicness) do you know a way of applying the
 diff results under Windows in other way than manually editing the
 target file?

 Thanks.

 Octavian 

The fastest way is getting the Win32 port of GNU patch from
http://gnuwin32.sourceforge.net/packages/patch.htm

If command line is not an option / the way you like it I think Eclipse
has an Apply patch... command in some Team SCM menu

Cheers,
kixx


___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] [RFC] ditch svn

2007-04-18 Thread Kiki
Jonathan Rockway wrote:
 I think it's pretty clear that Subversion is a failure for our project.  We 
 use topic branches heavily, and that's just not something svn (or really svk) 
 is designed for.

 I hearby propose that we switch to git.  I envision each project in trunk to 
 be a separate repository.  That will allow us to easily manage commit 
 permissions, and keep branches sane (branching Catalyst-Runtime need not 
 affect Catalyst-Plugin-Foobar).  I'm willing to setup and administer All 
 Things Git if we decide to switch.
   
All nice and peachy, except for lack of a native win32 port... to use
git on win32 you apparently have the following alternatives:

1. recompile it with mingw
2. use a eclipse-based java implementation
3. install cygwin for the ride

everyone of these seems a bit too much trouble for just checking out
catalyst sources.

I propose Mercurial and my argument is that if it's good enough for to
be selected as a candidate for the Mozilla repository
(http://weblogs.mozillazine.org/preed/2007/04/version_control_system_shootou_1.html),
it could work for Catalyst too.

___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] putting an object in the stash

2007-03-13 Thread Kiki
Simon Wilcox wrote:
 Not necessarily, you can also bless scalars and arrays. A blessed array,
 in particular can be a very effective way of improving performance for
 certain types of data structures.
   
Strictly speaking you can bless any reference, although the most useful
are hashes and arrays.

___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


OT: Re: [Catalyst] creating binaries

2007-01-17 Thread Kiki
I know I shouldn't feed the trools, but what the heck.

Octavian Rasnita wrote:
 Yes I agree, but the customers would prefer to get the program from
 another source, and don't pay anything for it.


I would say that treating your customers as potential thieves won't get
you very far in doing business with them.



___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] 404 Not Found

2006-12-21 Thread Kiki
Octavian Rasnita wrote:
 sub bunatati : General {
my ( $self, $c ) = @_;
 $c-res-body(okokok);
 }
As far as I can see ( from
http://search.cpan.org/~jrockway/Catalyst-Manual-5.700501/lib/Catalyst/Manual/Intro.pod#Actions
) there's no such thing as a General action, but there is a Global
action ...


___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Dojo madness

2006-11-15 Thread Kiki
Toby Corkindale wrote:
 I'm totally stumped. I have two extremely simple webpages, one of which causes
 IE to crash with an error Operation aborted, and another that works fine.

 The only difference between them is the use of a base tag in the header.
 $ diff breaks.html works.html 
 5d4
  base href=http://wtf.ymogen.net/; /

 I have put the files online, in case anyone wants to test this out on their 
 own
 browsers: http://wtf.ymogen.net/
 (Note that Dojo 0.3.1 is extracted into a sub-directory called dojo, in case
 anyone wants to make their own setup. Or just wget -r the lot.)

 I'll hunt down the Dojo mailing list next and post there, but thought I'd post
 this here for your WTF confusement first.

 Toby

   
A quick google search indicates that for IE you should also add a
/base tag

http://dojotoolkit.org/pipermail/dojo-interest/2006-October/018666.html

Cheers,
Kiki

___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Advice for Catalyst::Plugin::Authentication::Store::DBIC needed

2006-10-05 Thread Kiki
Bernhard Graf wrote:
 [EMAIL PROTECTED] wrote:

   
 What you need to do is subclass C::P::A::Credential, and override the
 login() method.

 The login method is where the username and password are checked, so
 you probably want to  do something like the following (probably
 borrowing the password check form C::P::Authentication::CDBI):
 

 It works. But is not a trivial thing, because it requires knowledge of 
 the - quite complex - Catalyst authentication code.


 So may I place a feature request to the author(s):

 Offer a possibility to add custom check code to the login() method.

 Example:
 $c-login($username, $password, {post_check = \check_status})

 =head2 check_status

 Callback function for login() to do further custom checks.
 Receives context object and user object as arguments.
 Checks user status field to equal active.
 On success this function must return without any value.
 On failure returns a string describing why login fails.

 =cut

 sub check_status {
   my ($c, $user) = @_;
   return if $user-status eq 'active';
   return 'user status is not active';
 }

   

This looks more like an authorization check than an authentication check
to me,
since the purpose of authentication is just to establish an identity,
while it is the
purpose of authorization to determine if that identity is allowed to
proceed
(in your case, the identity is not allowed to do anything if it is not
active).

So it would make more sense to me to setup an active role and then
check for it with the C::P::Authz::Roles plugin 

___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


[Catalyst] Catalyst::Model minor doc patch

2006-09-19 Thread Kiki
Attatched a small patch to make Catalyst::Model POD consistent with
Catalyst::View POD.

Kiki
Index: lib/Catalyst/Model.pm
===
--- lib/Catalyst/Model.pm	(revision 4965)
+++ lib/Catalyst/Model.pm	(working copy)
@@ -15,6 +15,11 @@
 
 Catalyst Model base class.
 
+=head1 METHODS
+
+Implements the same methods as other Catalyst components, see
+LCatalyst::Component
+
 =head1 AUTHOR
 
 Sebastian Riedel, C[EMAIL PROTECTED]
___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


[Catalyst] RFC: JobQueue Job Notification

2006-09-19 Thread Kiki
Hello,

Anyone who's interested in the Catalyst::Engine::JobQueue, please
provide some feedback.

Here's the deal: you have a jobqueue running, jobs have been setup...
each job is sent as a $request to your app (auto, begin, controller
action, etc.), which deals with it and generates a response. This
response is returned to the Engine.

What should the engine do with it? It can email it and/or log it. Any
other ideas? How much of the response should get emailed/logged? The
full thing:
200 OK
X-Catalyst: 5.7002

html
...
html

Or just the body, body+headers,body+status?

Should the log level be computed from the response status (i.e. 100-399
- info level, 400+ - error level)?

___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] RFC: JobQueue Job Notification

2006-09-19 Thread Kiki
Jonathan Rockway wrote:
 I think you should have an option for both.

 Use case A, you want to run something every 5 minutes (clean sessions,
 update stock ticker, whatever).  That, you'll just want logged.

 Use case B, you want a nightly report (or something), and you will
 probably want e-mail about that.

   
So how about the engine inspects the response ... and decides based on
a  header
what to do with it (email, log or both)...

X-Job-Response-Transport: email, log

Should the other two options also be decided via headers?

X-Job-Response-Content: status, headers, body

X-Job-Response-LogByStatus: yes

(Of course there will be fallbacks for each option)

or just try to act smartly like suggested below?


 What should the engine do with it? It can email it and/or log it. Any
 other ideas? How much of the response should get emailed/logged? The
 full thing:
 200 OK
 X-Catalyst: 5.7002

 html
 ...
 html

 Or just the body, body+headers,body+status?

 Should the log level be computed from the response status (i.e. 100-399
 - info level, 400+ - error level)?
 

 Log should just log that the event ran (to info), and the $c-error if
 there was an error.  If you want warnings to be logged, I suggest having
 a plugin for that :)

 E-mail should probably log that the event ran, and then send the body
 if the response is 200 OK.  If there was an error, log the details, and
 then mail or log the error message, headers, response, probably the
 request, and maybe the contents of the stash; depending on debug levels
 of course.

 My $0.02

 Regards,
 Jonathan Rockway

   
Thx,
Kiki

___
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/