Path::AttrRouterを使うのに、 package MyController; use Any::Moose; extends 'Path::AttrRouter::Controller'; sub index :Path Args(0) { } 1; みたいに書くと「Error while loading app.psgi: Invalid CODE attributes:」とか怒られてどうすればいいんだろう。 と思って#perl-casualで聞いてみたら、JPAの牧さんがあっさり「それBEGIN {}でできるよ」と解決してくれました。 package MyController; use Any::Moose; BEGIN { extends 'Path::AttrRouter::Controller' } のように、extendsをBEGINでくくってやれば無問題。use