Recently in Catalyst Integration Category

Time to get rolling again. I started writing 'live' (Test::WWW::Mechanize::Catalyst) tests for force myself to focus on the web side of things and get my nose out of the base class details. I was bogging myself down with all of the things to remember and the possibilities of re factoring. Spent some time patching Catalyst::Action::REST to deal with some issues that were biting me in the ass.

My goal this week is to get an _07 out the door by the end of the weekend that at least has a working quickstart, cart, wishlists and the admin stuff tested. Still way behind. :-(

Back on the wagon again.

  • Fixed Template->share when Mango has never been installed
  • Stripped action from yml forms, now get path_prefix on the fly
  • Base Controllers have form_directory set to cope with subclass rename
  • Cart Controller works with add/update/clear/save/delete
  • Added Forms plugin companion to Forms controller
  • Cart forms is not build from sub-forms
  • Form->render now localizes field labels/submit
  • Views now fall back to auto/Mango/templates
  • Added Form/FormFile attributes to Form controller

In general, I think I finally have things the way I want them in terms of forms, base controllers and the various plugins and custom authentication. Next step is wishlist view/restore support and merging the various plugins into on [thing to load] Mango::Catalyst::Plugin::Application.

Day 99? Yeah, I'm a damn slacker. What can I say. But, I'm back to making progress again it seems. I've been spending most of the time lately on the admin controllers and such, which means I had to get the generic stuff somewhat solid. That mostly consisted of:

  • Base Controller for Mango::Form loading/mapping/validating
  • Models wrapping Providers
  • Plugin for I18N merging Mango+MyApp Lexicons
  • Plugin for Authorization+user carts/profiles using new Auth API
  • Views for XHTML/HTML/Text/Atom/RSS
  • File::ShareDir directory with base forms/templates
  • Template views use share first, then fallback to MyApp local templates

Now that most of the busy work is done, I'm back to converting what I'd hacked together for Handel back into Mango. It looks ugly as hell, but the admin user/roles/profiles/products/attribute CRUD works and the cart load/update works using the custom auth user objects. I'll probably finish fixing the cart tomorrow and move on to the wishlists.

Yeah, day 26. Long time no post, but at least I have been working on Mango.

At some point, I had enough untested, undocumented Catalyst code floating around Mango that it was time get that under control. With a little help from Chuck Norris Controller Testing and some ideas from Angerwhale, I managed to throw together some test context classes and whip up some model/view/plugin tests.

Now that those are done, time to move on to the base controller code. After that, the last big piece left will be the 'mango MyApp' Module::Starter parts, and of course some "live" catalyst Mech tests.

I may be slow. I maybe be late. But when it's finished, it will certainly be very well tested.

After a lot of cursing, tinkering, fixing, breaking, fixing, breaking and fixing, I've finally got most of the Auth/User bits converted to the new Catalyst Authentication API. when it's working, it means that people can reference common user elements for both authenticated and anonymous users in the same way:

## current users cart pre/post authenticate()
$c->user->cart;

## 'anonymous' before authenticate()
$c->user->username;

## 'Anonymous' before authenticate()
$c->user->profile->first_name;

## 'claco' after authenticate()
$c->authenticate(...);
$c->user->username;

## 'Christopher' after authenticate()
$c->user->profile->first_name;

In addition to a common way to reference user information, the Mango store also takes care of caching that user information, including roles, in session after authentication so we're no hitting the database every time we check roles, display profile information, etc.

The one thing I seem to be constantly fighting is that either Catalyst, or Authentication bits just eat errors in certain situations. Things like misnamed classes, classes not loading due to syntax errors, errors down in DBI just go into the ether. I'd say it's some SIG{DIE}/Error/Exception stuff somewhere just being too greedy. I don't think I'm alone either.

Now that the core api is "done", time to start working on the Catalyst bits. I've re added what I started with to trunk and I've started converting it to a name namespace and to the as yet released updated Catalyst::Plugin::Authorization.

Hopefully I can get everything back to a working state with pod by the end of the weekend.

February 2008

Sun Mon Tue Wed Thu Fri Sat
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29  

Planet Catalyst News

About this Archive

This page is a archive of recent entries in the Catalyst Integration category.

Announcements is the previous category.

Core API is the next category.

Find recent content on the main index or look in the archives to find all content.

Powered by Movable Type 4.1