<div dir="ltr">The original issue (in email below) is definitely fixed (I get a nice Log::Report error from it). In a similar vein, however, there is a difference in feedback to the browser with Dancer2::Plugin::Auth::Extensible (trying to get my customised login page working).<div><br></div><div>1. With Log::Report turned on:</div><div>
<p class="gmail-p1"><span class="gmail-s1"><font color="#0000ff">Internal Server Error</font></span></p>
<p class="gmail-p1"><span class="gmail-s1"><font color="#0000ff">Can't call method "uri" on an undefined value at /Library/Perl/5.18/Dancer2/Plugin/LogReport.pm line 228.</font></span></p></div><div>2. Without Log::Report turned on:</div><div>
<p class="gmail-p1"><span class="gmail-s1"><b><font color="#0000ff">Error 500 - Internal Server Error</font></b></span></p>
<p class="gmail-p2"><span class="gmail-s1"><b><font color="#0000ff">Runtime Error</font></b></span></p>
<p class="gmail-p3"><span class="gmail-s1"><font color="#0000ff">Undefined subroutine &Dancer2::Plugin::Auth::Extensible::login called at /Library/Perl/5.18/Dancer2/Plugin/Auth/Extensible.pm line 282.</font></span></p>
<p class="gmail-p4"><span class="gmail-s1"><font color="#0000ff">/Library/Perl/5.18/Dancer2/Plugin/Auth/Extensible.pm around line 282</font></span></p>
<table cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">277</font></span></p>
</td>
<td valign="middle" class="gmail-td2">
<p class="gmail-p6"><span class="gmail-s1"><font color="#0000ff"> {</font></span></p>
</td>
</tr>
<tr>
<td valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">278</font></span></p>
</td>
<td valign="middle" class="gmail-td2">
<p class="gmail-p6"><span class="gmail-s1"><font color="#0000ff"> $app->request->parameters->set('password_code_valid' => 1),</font></span></p>
</td>
</tr>
<tr>
<td valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">279</font></span></p>
</td>
<td valign="middle" class="gmail-td2">
<p class="gmail-p6"><span class="gmail-s1"><font color="#0000ff"> }</font></span></p>
</td>
</tr>
<tr>
<td colspan="2" valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">280</font></span></p>
</td>
</tr>
<tr>
<td colspan="2" valign="middle" class="gmail-td1">
<p class="gmail-p7"><font color="#0000ff"><span class="gmail-s1"></span><br></font></p>
</td>
</tr>
<tr>
<td valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">281</font></span></p>
</td>
<td valign="middle" class="gmail-td2">
<p class="gmail-p6"><span class="gmail-s1"><font color="#0000ff"> no strict 'refs';</font></span></p>
</td>
</tr>
<tr>
<td valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">282</font></span></p>
</td>
<td valign="middle" class="gmail-td2">
<p class="gmail-p6"><span class="gmail-s1"><font color="#0000ff"> return &{ $weak_plugin->login_page_handler }($weak_plugin);</font></span></p>
</td>
</tr>
<tr>
<td valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">283</font></span></p>
</td>
<td valign="middle" class="gmail-td2">
<p class="gmail-p6"><span class="gmail-s1"><font color="#0000ff"> },</font></span></p>
</td>
</tr>
<tr>
<td valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">284</font></span></p>
</td>
<td valign="middle" class="gmail-td2">
<p class="gmail-p6"><span class="gmail-s1"><font color="#0000ff"> );</font></span></p>
</td>
</tr>
<tr>
<td colspan="2" valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">285</font></span></p>
</td>
</tr>
<tr>
<td colspan="2" valign="middle" class="gmail-td1">
<p class="gmail-p7"><font color="#0000ff"><span class="gmail-s1"></span><br></font></p>
</td>
</tr>
<tr>
<td valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">286</font></span></p>
</td>
<td valign="middle" class="gmail-td2">
<p class="gmail-p6"><span class="gmail-s1"><font color="#0000ff"> $app->add_route(</font></span></p>
</td>
</tr>
<tr>
<td valign="middle" class="gmail-td1">
<p class="gmail-p5"><span class="gmail-s2"><font color="#0000ff">287</font></span></p>
</td>
<td valign="middle" class="gmail-td2">
<p class="gmail-p6"><span class="gmail-s1"><font color="#0000ff"> method => 'get',</font></span></p>
</td>
</tr>
</tbody>
</table></div><div><br></div><div>Note that the log file does contain the full report (ie. this is a workable problem, in that I can just go to the log file for the full detail of the issue).</div><div><br></div><div>cheers,</div><div>Nathan</div><div class="gmail_extra"><br><div class="gmail_quote">On 10 February 2017 at 04:08, Andrew Beverley <span dir="ltr"><<a href="mailto:andy@andybev.com" target="_blank">andy@andybev.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Tue, 7 Feb 2017 Andrew Beverley <<a href="mailto:andy@andybev.com">andy@andybev.com</a>> wrote:<br>
> On Thu, 5 Jan 2017 Nathan Bailey <<a href="mailto:web@polynate.net">web@polynate.net</a>> wrote:<br>
> > Hi all (especially Andy :-)<br>
><br>
> Sorry for the delay on this Nathan.<br>
><br>
> > What are you supposed to put in your non-main route handlers?<br>
> > use Dancer2::Plugin::LogReport mode => 'DEBUG'; (like main route<br>
> > handler); OR<br>
> > use Log::Report; (like other modules)<br>
><br>
> I can now say that it /should/ be the same as any other route<br>
> handlers. So wherever you have:<br>
><br>
> use Dancer2;<br>
><br>
> You should also have:<br>
><br>
> use Dancer2::Plugin::LogReport ...<br>
><br>
> Although if you're using the same appname (appname => ...) then you<br>
> only need to use Log::Report.<br>
><br>
> The reason being that otherwise the required logging hook isn't<br>
> inserted into that particular app.<br>
><br>
> However, there is a problem with the way the current version of the<br>
> plugin works, which means that the correct DSL isn't always available<br>
> to it. This will cause some unexpected behaviour. I'm working on a fix<br>
> at the moment.<br>
<br>
</span>Fix included in aforementioned v1.19 Log::Report release. Let me know<br>
if you run into any other problems.<br>
<br>
Regards,<br>
<br>
Andy<br>
<div class="HOEnZb"><div class="h5">______________________________<wbr>_________________<br>
dancer-users mailing list<br>
<a href="mailto:dancer-users@dancer.pm">dancer-users@dancer.pm</a><br>
<a href="http://lists.preshweb.co.uk/mailman/listinfo/dancer-users" rel="noreferrer" target="_blank">http://lists.preshweb.co.uk/<wbr>mailman/listinfo/dancer-users</a><br>
</div></div></blockquote></div><br></div></div>