[Catalyst] new Catalyst::Component::ACCEPT_CONTEXT

Jonathan Rockway jon at jrock.us
Fri Jan 18 08:16:00 GMT 2008


Hi all,

A few people on IRC have reported that using
Catalyst::Component::ACCEPT_CONTEXT causes extremely weird things to
happen.  They're right.  The cause is NEXT skipping
Catalyst::Controller::new when you do something like this:

  package MyApp::Controller::ACCEPT_CONTEXT;
  use base qw/Catalyst::Component::ACCEPT_CONTEXT Catalyst::Controller/;
  ...

If you reverse the order of A_C and C::C, then it works OK. 

However, the latest version (0.05; just released moments ago) fixes this
bug:

  file:
$CPAN/authors/id/J/JR/JROCKWAY/Catalyst-Component-ACCEPT_CONTEXT-0.05.tar.gz
  size: 22033 bytes
   md5: 95fd36fa91716db99dbb4e488b6ff573


It also adds some new documentation about how to do what ACCEPT_CONTEXT
does cleanly with InstancePerContext.  That section is worth a read if
you prefer clean solutions to quick hacks.

Anyway, I recommend that you update immediately.  If you weren't having
problems before, it was due to pure luck :)

Regards,
Jonathan Rockway
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://lists.scsys.co.uk/pipermail/catalyst/attachments/20080118/b36780f2/attachment.pgp


More information about the Catalyst mailing list