RE: [Catalyst] Sending email from a Catalyst app
*** T-Systems Austria GesmbH Rennweg 97-99, 1030 Wien Handelsgericht Wien, FN 79340b *** Notice: This e-mail contains information that is confidential and may be privileged. If you are not the intended recipient, please notify the sender and then delete this e-mail immediately. ***---BeginMessage--- winmail.dat---End Message--- ___ 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_01 - Developer Release
Agreed. I've had it on TODO for the past two weeks, but getting hammered at dayjob. Will try to do this week. Regards, Charlie On 7/19/08, Matt S Trout [EMAIL PROTECTED] wrote: On Thu, Jun 26, 2008 at 06:50:58PM -0400, Charles Bailey wrote: On Wed, Jun 25, 2008 at 4:57 PM, Marcus Ramberg [EMAIL PROTECTED] wrote: The feature to note here is 'go', which works like an internal redispatch to another action, while retaining the stash intact. Being able to do this means that in practice you don't ever need to set the template name in stash, but can depend on using go when you want to render the template of the other action, rather than the one you dispatched to. Would it make sense to include a function analogous to forward() (say, visit()) in the same way that go() is analogous to detach()? Seems like it'd be a nice way to wrap an action that uses auto() or end() in its controller to handle tasks common to several actions there. Maybe. How about doing up a patch for catalyst-dev@ ? -- Matt S Trout Need help with your Catalyst or DBIx::Class project? Technical Director http://www.shadowcat.co.uk/catalyst/ Shadowcat Systems Ltd. Want a managed development or deployment platform? http://chainsawblues.vox.com/http://www.shadowcat.co.uk/servers/ ___ 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/ -- Regards, Charles Bailey Lists: bailey _dot_ charles _at_ gmail _dot_ com Other: bailey _at_ newman _dot_ upenn _dot_ edu ___ 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-Devel Patch
J, Thanks for the detailed reply. I hadn't thought about the base class nature of this class. Catalyst and DBIC are both MAJOR development projects. This means their documentation on CPAN gets spread broadly over many pages. I admit this is not a problem for most modules on CPAN. I suppose my patch was specifically aimed at dealing with some of this. I have countless times asked questions on a list/IRC which was clearly documented on a page I'd reviewed multiple times. Once I knew where to look, the answer was easy. I am a major fan of wiki, as it's low entry barrier can make it easy for the people who most need the information (newbies) to append to the docs or clarify the docs once they get their answer. I'll take a look at the available wikis. When I'm done, I suspect my comment will be, well if this is the best place to put the docs on useability, shouldn't we point to it from the POD? This would effectivley allow us to separate the design specs related stuff (POD) from the practical use (WIKI). What are your thoughts on this approach? Todd On Sun, Jul 20, 2008 at 10:38 PM, J. Shirley [EMAIL PROTECTED] wrote: On Sun, Jul 20, 2008 at 7:49 PM, Todd Rinaldo [EMAIL PROTECTED] wrote: Hi, I still think something should go in the manual explaining how this works. I spent quite a bit of time trying to figure out how Catalyst::Helper did it's magic. If a code reference shouldn't go in, then could I recommend a link to the FAQ. I think allot of people get their start with DBIC using Catalyst::Helper and so it's the natural place they would look first. [snip] The main point is that Catalyst::Helper is specific to Catalyst, and has absolutely zero relevance to DBIx::Class. If you want something in the Catalyst::Helper space, something specific to DBIC would be the right place. As an example, Catalyst::Model::DBIC::Schema: http://search.cpan.org/~blblack/Catalyst-Model-DBIC-Schema-0.20/lib/Catalyst/Model/DBIC/Schema.pm But, again, the question you are asking is already answered in the Catalyst::Helper::Model::DBIC::Schema documents: http://search.cpan.org/~blblack/Catalyst-Model-DBIC-Schema-0.20/lib/Catalyst/Helper/Model/DBIC/Schema.pm The relevant excerpt: create=static instructs this Helper to generate the named Schema class for you, using DBIx::Class::Schema::Loader in one shot mode to create a standard, manually-defined DBIx::Class::Schema setup, based on what the Loader sees in your database at this moment. A Schema/Model pair generated this way will not require DBIx::Class::Schema::Loader at runtime, and will not automatically adapt itself to changes in your database structure. You can edit the generated classes by hand to refine them. So, what we have is documentation to use Catalyst::Helper::Model::DBIC::Schema or to use DBIx::Class directly and the make_schema_at method. If you'll note, Catalyst::Helper's pod, almost in entirety, is focused on people writing generic model, view and controller classes - and not for end users. In fact, even in Catalyst::Manual::Cookbook the only reference to DBIC is a link to Catalyst::Model::DBIC::Schema. Further reading of that page, in the description section, it hints at your question: This is a Catalyst Model for DBIx::Class::Schema-based Models. See the documentation for Catalyst::Helper::Model::DBIC::Schema for information on generating these Models via Helper scripts. The link there finally answers the specifics of the question on how to generate DBIC classes from an existing database, and in very specific detail. It's unreasonable to expect Catalyst core documentation to reference any specific model that may or may not be used. Simply because Catalyst and DBIC are most commonly used together does not mean that the Catalyst community endorses DBIC as the only ORM. If you ask our advice, we will recommend it (more in the way of, if you don't know why you should use it over others, you should use it). Now, please note I'm not saying that search.cpan.org or Pod in its current form is the best solution for documentation. I think it could use work, and that would help increase findability. As always, patches welcome and all that. I just think that your patch is a misguided attempt to help because you failed to read other relevant documentation. I don't want to discourage you from helping just because I'm saying no, because there are other ways to address your very valid issue of not finding the right information. If you agree with me in my feelings that finding this information is the issue, and not the location (and increasing where the information is found is not a solution), perhaps the right solution is to submit this on the wiki, or start a blog, or if you have one use a catalyst, perl or dbic tag, write an article and then submit your blog to be included on planet.catalystframework.org. This is always preferable than adding in more, and potentially irrelevant, documentation in
Re: [Catalyst] Catalyst::Authentication::Credential::LDAP
On Mon, Jul 21, 2008 at 11:48:39AM -0500, [EMAIL PROTECTED] wrote: Matt S Trout [EMAIL PROTECTED] wrote on 07/19/2008 07:10:28 PM: On Wed, Jun 25, 2008 at 11:27:13AM -0700, Bruce J Keeler wrote: Also, somewhat apropos, I have a C::A::{Store,Credential}::ActiveDirectory that I based on the LDAP stuff. The LDAP modules didn't work for me because they want to bind anonymously and retrieve the crypted password, whereas AD just wants to authenticate with a bind. My stuff also gets role information from AD groups. I've been meaning to get it out on CPAN one of these days, but it hasn't been a priority; I suppose I can work on it if anyone else needs it though. Sounds to me like 'auth by bind' versus 'auth by retrieve and check' should be an option in the LDAP stuff, not a separate module. Fancy doing up a patch? From the POD It authenticates users in two steps: 1) A search of the directory is performed, looking for a user object that matches the username you pass. This is done with the bind credentials supplied in the binddn and bindpw configuration options. 2) If that object is found, we then re-bind to the directory as that object. Assuming this is successful, the user is Authenticated. And the actual check password code: $self-store-ldap_bind( undef, $self-ldap_entry-dn, $password, 'forauth' ); Notice the rebind. So it does not try to retrieve the crypted password, it does bind (anon or by authorized service account if set in binddn and bindpw) to the ldap server, Next it grabs the user's dn from a search on that bind. Finally to authenticate it actually binds to the ldap server as that user's dn. This works well against AD (I use it), I don't understand what deficiency you are trying to fix with your patch. Maybe the search phase failed for the original poster? I dunno, I was just saying it should probably support both approaches :) -- Matt S Trout Need help with your Catalyst or DBIx::Class project? Technical Directorhttp://www.shadowcat.co.uk/catalyst/ Shadowcat Systems Ltd. Want a managed development or deployment platform? http://chainsawblues.vox.com/http://www.shadowcat.co.uk/servers/ ___ 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_01 - Developer Release
On Mon, Jul 21, 2008 at 07:13:37AM -0400, Charles Bailey wrote: Agreed. I've had it on TODO for the past two weeks, but getting hammered at dayjob. Will try to do this week. We're one more dev release short of shipping. Please try because otherwise it'll probably have to wait until 5.80 -- Matt S Trout Need help with your Catalyst or DBIx::Class project? Technical Directorhttp://www.shadowcat.co.uk/catalyst/ Shadowcat Systems Ltd. Want a managed development or deployment platform? http://chainsawblues.vox.com/http://www.shadowcat.co.uk/servers/ ___ 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-Devel Patch
On Sun, Jul 20, 2008 at 08:42:26AM -0500, Todd Rinaldo wrote: Hi, yesterday, I asked a question in DBIC channel about how Catalyst::Helper auto-produces schema. It was answered with purl: make_schema_at. I suggest this be put in Catalyst::Helper so people can more easily find the answer I suggested you patched Catalyst::Helper::Model::DBIC::Schema ... maybe we should have a myapp_create.pl --help Model DBIC::Schema option that invokes perldoc for the appropriate helper? -- Matt S Trout Need help with your Catalyst or DBIx::Class project? Technical Directorhttp://www.shadowcat.co.uk/catalyst/ Shadowcat Systems Ltd. Want a managed development or deployment platform? http://chainsawblues.vox.com/http://www.shadowcat.co.uk/servers/ ___ 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] Issue with Catalyst::Plugin::Authentication and updating user information (jayk, looking at you!)
Follow up for the list. This turned out to be caused by a config problem. id_field was set to the username field... which meant that the session was attempting to restore using the old username as the key. Setting the id_field to username is fine unless you change the username during the session, in which case things get confused. ;-) Once id_field was removed from the config, it defaulted back to the primary key of the table and the problems went away. Jay On Jul 21, 2008, at 12:13 PM, J. Shirley wrote: In my current application we require the feature of allowing users to change their login information. My initial attempts work, but on the next page request (which is the redirect after the POST) I get: Caught exception in EMS::Controller::Profile-setup Can't call method auth_realm on an undefined value at /home/jshirley/perl5/lib/perl5/Catalyst/Authentication/Realm.pm line 177. First step was to check out C::P::A and C::A::Store::DBIx::Class out from svn, install from there and try again. Same thing. So, I build up some tests on C::A::Store::DBIx::Class that does (functionally) the same thing (http://scsys.co.uk:8001/17020), but they all pass and the user name is being updated. I've tried adding in update_user_in_session, which doesn't seem to do anything. Before I dive too far into the guts, hoping someone has an idea or two, or perhaps point out the failing of my tests. -J ___ 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/