Glurg. Okay, I went to clean up and test everything before committing this patch and discovered a initialization problem. It's trying to call $model->table for the plugin models, which calls $model->_guess_table_name, but this happens before plugin class itself is configured, which means that the table name will never be prefixed, which is undesirable. 
<br><br>I have traced it back into the class loader, which runs this snippet while loading the models around line 168, which is run while generating the model action classes (which happens automatically upon creation of a Jifty::ClassLoader instance):
<br><br>&nbsp;&nbsp;&nbsp; local $@;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; eval { $modelclass-&gt;table } ;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if(!$@) {<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return $self-&gt;return_class(<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &quot;package $module;\n&quot;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &quot;use base qw/$base\::Action::Record::$1/;\n&quot;
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &quot;sub record_class { &#39;$modelclass&#39; };\n&quot;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &quot;sub autogenerated { 1 };\n&quot;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; );<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br><br>If I understand what&#39;s going on here, it&#39;s checking to see if the model provides a valid and non-failing implementation of the table() method to determine whether or not to actually build the action classes. A similar check is in place for creating the model event class too.
<br><br>Is this necessary? If so, I can look for another way to short-circuit the process until the plugins are initialized. If not, what other check would suffice? I&#39;m not certain as for the purpose of this at all, so I&#39;m not sure what to do about it.
<br><br><br><div><span class="gmail_quote">On 7/16/07, <b class="gmail_sendername">Jesse Vincent</b> &lt;<a href="mailto:jesse@bestpractical.com">jesse@bestpractical.com</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div style="">
<br><div><span class="q"><div>On Jul 16, 2007, at 3:21 PM, Andrew Sterling Hanenkamp wrote:</div><br><blockquote type="cite">Done. It required the addition I already mentioned to Jifty::Plugin as well as a modification to Jifty::Record to improve _guess_table_name().
<br><br>I&#39;ve attached an updated patch.</blockquote><div><br></div></span><div>+1. I&#39;m good with this.</div><br><blockquote type="cite"><span class="q"><br><br><div><span class="gmail_quote"> On 7/16/07, <b class="gmail_sendername">
Jesse Vincent</b> &lt;<a href="mailto:jesse@bestpractical.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">jesse@bestpractical.com</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
 <br>On Jul 16, 2007, at 2:52 PM, Andrew Sterling Hanenkamp wrote:<br><br>&gt; Sorry, I make my emails too long. As the dorky consultants around<br>&gt; the office say, quoting my Kolbe score, my red line is too long.<br>
&gt; <br>&gt; This little nugget was the last line of my original message:<br>&gt;<br>&gt; &gt; I also wonder if each plugin might want to supply a prefix to the<br>&gt; table names to avoid collisions.<br>&gt;<br>&gt; My patch doesn&#39;t include that. It was a thought I had as I finished 
<br>&gt; the email. It should be pretty easy to add by adding something like<br>&gt; &quot;table_prefix()&quot; to the Jifty::Plugin that could be overridden and<br>&gt; just calculates a preset table prefix from the plugin&#39;s name. 
<br><br>I suspect that&#39;s probably the right thing.<br><br>_______________________________________________<br>jifty-devel mailing list<br><a href="mailto:jifty-devel@lists.jifty.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
jifty-devel@lists.jifty.org</a><br> <a href="http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel
</a><br><br><br></blockquote></div><br></span><span>&lt;plugin-models2.patch&gt;</span><span class="q"><div style="margin: 0px;">_______________________________________________</div><div style="margin: 0px;">jifty-devel mailing list
</div><div style="margin: 0px;"><a href="mailto:jifty-devel@lists.jifty.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">jifty-devel@lists.jifty.org</a></div><div style="margin: 0px;"><a href="http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel</a></div> </span></blockquote></div><br></div><br>_______________________________________________<br>jifty-devel mailing list<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:jifty-devel@lists.jifty.org">
jifty-devel@lists.jifty.org</a><br><a onclick="return top.js.OpenExtLink(window,event,this)" href="http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel" target="_blank">http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel
</a><br><br><br clear="all"></blockquote></div><br>