[Mojolicious] Re: Removal of render_exception and render_not_found (Mojolicious 6.0)

2014-11-28 Thread Revlin John
Is $c->reply no longer a default helper? 

Here's a dump of helpers in my mojolicious::lite app...

"helpers" => { "accepts" => sub { "DUMMY" }, "app" => sub { "DUMMY" }, "b" 
=> sub { "DUMMY" }, "c" => sub { "DUMMY" }, "check_box" => sub { "DUMMY" }, 
"color_field" => sub { "DUMMY" }, "config" => sub { "DUMMY" }, "content" => 
sub { "DUMMY" }, "content_for" => sub { "DUMMY" }, "csrf_field" => sub { 
"DUMMY" }, "csrf_token" => sub { "DUMMY" }, "current_route" => sub { 
"DUMMY" }, "date_field" => sub { "DUMMY" }, "datetime_field" => sub { 
"DUMMY" }, "delay" => sub { "DUMMY" }, "dumper" => sub { "DUMMY" }, 
"email_field" => sub { "DUMMY" }, "extends" => sub { "DUMMY" }, 
"file_field" => sub { "DUMMY" }, "flash" => sub { "DUMMY" }, "form_for" => 
sub { "DUMMY" }, "hidden_field" => sub { "DUMMY" }, "image" => sub { 
"DUMMY" }, "inactivity_timeout" => sub { "DUMMY" }, "include" => sub { 
"DUMMY" }, "input_tag" => sub { "DUMMY" }, "javascript" => sub { "DUMMY" }, 
"label_for" => sub { "DUMMY" }, "layout" => sub { "DUMMY" }, "link_to" => 
sub { "DUMMY" }, "month_field" => sub { "DUMMY" }, "myhelper" => sub { 
"DUMMY" }, "number_field" => sub { "DUMMY" }, "param" => sub { "DUMMY" }, 
"password_field" => sub { "DUMMY" }, "radio_button" => sub { "DUMMY" }, 
"range_field" => sub { "DUMMY" }, "search_field" => sub { "DUMMY" }, 
"select_field" => sub { "DUMMY" }, "session" => sub { "DUMMY" }, "stash" => 
sub { "DUMMY" }, "stylesheet" => sub { "DUMMY" }, "submit_button" => sub { 
"DUMMY" }, "t" => sub { "DUMMY" }, "tag" => 
$VAR1->{"renderer"}{"helpers"}{"t"}, "tag_with_error" => sub { "DUMMY" }, 
"tel_field" => sub { "DUMMY" }, "text_area" => sub { "DUMMY" }, 
"text_field" => sub { "DUMMY" }, "time_field" => sub { "DUMMY" }, "title" 
=> sub { "DUMMY" }, "ua" => sub { "DUMMY" }, "url_field" => sub { "DUMMY" 
}, "url_for" => sub { "DUMMY" }, "url_with" => sub { "DUMMY" }, 
"validation" => sub { "DUMMY" }, "week_field" => sub { "DUMMY" } }

If the reply helper needs to be explicitly imported, these docs are way 
out-of-date: 
http://mojolicio.us/perldoc/Mojolicious/Plugin/DefaultHelpers#reply-asset

Thanks,
Rev


On Thursday, September 11, 2014 12:09:31 PM UTC-7, sri wrote:
>
> Quick heads up, in Mojolicious 5.40 we will be introducing the two new 
> nested helpers $c->reply->exception and $c->reply->not_found, which are 
> going to replace $c->render_exception and $c->render_not_found in our next 
> major release (Mojolicious 6.0).
>
> https://github.com/kraih/mojo/issues/674
>
> --
> sebastian
>

-- 
You received this message because you are subscribed to the Google Groups 
"Mojolicious" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to mojolicious+unsubscr...@googlegroups.com.
To post to this group, send email to mojolicious@googlegroups.com.
Visit this group at http://groups.google.com/group/mojolicious.
For more options, visit https://groups.google.com/d/optout.


[Mojolicious] Re: Removal of render_exception and render_not_found (Mojolicious 6.0)

2014-11-28 Thread Revlin John
I get the same result for your one-liner,, which I found strange so I ran 
this one:
$ perl -Mojo -E "say Mojolicious->VERSION"
5.67

but when I run this simple server via `$ morbo server.pl`:

#!/usr/bin/perl
no warnings;
use Mojolicious::Lite;

our $version = Mojolicious->VERSION;

get( '/' => sub {
  my $c = shift;
my $serialized = $c->dumper(app->renderer->helpers);
$c->render( text => $version ."\n". $serialized );
} );

app->start;

... I get:

5.12
{ "accepts" => sub { "DUMMY" }, "app" => sub { "DUMMY" }, "b" => sub { 
"DUMMY" }, "c" => sub { "DUMMY" }, "check_box" => sub { "DUMMY" }, 
"color_field" => sub { "DUMMY" }, "config" => sub { "DUMMY" }, "content" => 
sub { "DUMMY" }, "content_for" => sub { "DUMMY" }, "csrf_field" => sub { 
"DUMMY" }, "csrf_token" => sub { "DUMMY" }, "current_route" => sub { 
"DUMMY" }, "date_field" => sub { "DUMMY" }, "datetime_field" => sub { 
"DUMMY" }, "delay" => sub { "DUMMY" }, "dumper" => sub { "DUMMY" }, 
"email_field" => sub { "DUMMY" }, "extends" => sub { "DUMMY" }, 
"file_field" => sub { "DUMMY" }, "flash" => sub { "DUMMY" }, "form_for" => 
sub { "DUMMY" }, "hidden_field" => sub { "DUMMY" }, "image" => sub { 
"DUMMY" }, "inactivity_timeout" => sub { "DUMMY" }, "include" => sub { 
"DUMMY" }, "input_tag" => sub { "DUMMY" }, "javascript" => sub { "DUMMY" }, 
"label_for" => sub { "DUMMY" }, "layout" => sub { "DUMMY" }, "link_to" => 
sub { "DUMMY" }, "month_field" => sub { "DUMMY" }, "number_field" => sub { 
"DUMMY" }, "param" => sub { "DUMMY" }, "password_field" => sub { "DUMMY" }, 
"radio_button" => sub { "DUMMY" }, "range_field" => sub { "DUMMY" }, 
"search_field" => sub { "DUMMY" }, "select_field" => sub { "DUMMY" }, 
"session" => sub { "DUMMY" }, "stash" => sub { "DUMMY" }, "stylesheet" => 
sub { "DUMMY" }, "submit_button" => sub { "DUMMY" }, "t" => sub { "DUMMY" 
}, "tag" => $VAR1->{"t"}, "tag_with_error" => sub { "DUMMY" }, "tel_field" 
=> sub { "DUMMY" }, "text_area" => sub { "DUMMY" }, "text_field" => sub { 
"DUMMY" }, "time_field" => sub { "DUMMY" }, "title" => sub { "DUMMY" }, 
"ua" => sub { "DUMMY" }, "url_field" => sub { "DUMMY" }, "url_for" => sub { 
"DUMMY" }, "url_with" => sub { "DUMMY" }, "validation" => sub { "DUMMY" }, 
"week_field" => sub { "DUMMY" } }

Any idea why invoking morbo gives me a different (older) version of 
mojolicious?

Thanks,
Rev


On Friday, November 28, 2014 10:47:12 AM UTC-8, sri wrote:
>
> If the reply helper needs to be explicitly imported, these docs are way 
>> out-of-date: 
>> http://mojolicio.us/perldoc/Mojolicious/Plugin/DefaultHelpers#reply-asset
>>
>
> No idea what you're talking about.
>
> $ perl -Mojo -E 'say r app->renderer->helpers'
>
> {
>
>   "accepts" => sub { "DUMMY" },
>
>   "app" => sub { "DUMMY" },
>
>   "b" => sub { "DUMMY" },
>
>   "c" => sub { "DUMMY" },
>
>   "check_box" => sub { "DUMMY" },
>
>   "color_field" => sub { "DUMMY" },
>
>   "config" => sub { "DUMMY" },
>
>   "content" => sub { "DUMMY" },
>
>   "content_for" => sub { "DUMMY" },
>
>   "csrf_field" => sub { "DUMMY" },
>
>   "csrf_token" => sub { "DUMMY" },
>
>   "current_route" => sub { "DUMMY" },
>
>   "date_field" => sub { "DUMMY" },
>
>   "datetime_field" => sub { "DUMMY" },
>
>   "delay" => sub { "DUMMY" },
>
>   "dumper" => sub { "DUMMY" },
>
>   "email_field" => sub { "DUMMY" },
>
>   "extends" => sub { "DUMMY" },
>
>   "file_field" => sub { "DUMMY" },
>
>   "flash" => sub { "DUMMY" },
>
>   "form_for" => sub { "DUMMY" },
>
>   "hidden_field" => sub { "DUMMY" },
>
>   "image" => sub { "DUMMY" },
>
>   "inactivity_timeout" => sub { "DUMMY" },
>
>   "include" => sub { "DUMMY" },
>
>   "input_tag" => sub { "DUMMY" },
>
>   "is_fresh" => sub { "DUMMY" },
>
>   "javascript" => sub { "DUMMY" },
>
>   "label_for" => sub { "DUMMY" },
>
>   "layout" => sub { "DUMMY" },
>
>   "link_to" => sub { "DUMMY" },
>
>   "month_field" => sub { "DUMMY" },
>
>   "number_field" => sub { "DUMMY" },
>
>   "param" => sub { "DUMMY" },
>
>   "password_field" => sub { "DUMMY" },
>
>   "radio_button" => sub { "DUMMY" },
>
>   "range_field" => sub { "DUMMY" },
>
>   "reply.asset" => sub { "DUMMY" },
>
>   "reply.exception" => sub { "DUMMY" },
>
>   "reply.not_found" => sub { "DUMMY" },
>
>   "reply.static" => sub { "DUMMY" },
>
>   "search_field" => sub { "DUMMY" },
>
>   "select_field" => sub { "DUMMY" },
>
>   "session" => sub { "DUMMY" },
>
>   "stash" => sub { "DUMMY" },
>
>   "stylesheet" => sub { "DUMMY" },
>
>   "submit_button" => sub { "DUMMY" },
>
>   "t" => sub { "DUMMY" },
>
>   "tag" => $VAR1->{"t"},
>
>   "tag_with_error" => sub { "DUMMY" },
>
>   "tel_field" => sub { "DUMMY" },
>
>   "text_area" => sub { "DUMMY" },
>
>   "text_field" => sub { "DUMMY" },
>
>   "time_field" => sub { "DUMMY" },
>
>   "title" => sub { "DUMMY" },
>
>   "ua" => sub { "DUMMY" },
>
>   "url_field" => sub { "DUMMY" },
>
>   "url_for" => sub { "DUMMY" },
>
>   "url_with" => sub { "DUMMY" },
>
>   "validation" => sub { "DUMMY" },
>
>   "week_field" => sub { "DUMMY" }

[Mojolicious] Re: Removal of render_exception and render_not_found (Mojolicious 6.0)

2014-12-07 Thread Revlin John
I have not figured out why the morbo command runs a version of mojolicious 
which is older than the one I've installed via cpan, but my work-around is to 
invoke my server script directly with the `daemon` option:

$ server.pl daemon

-- 
You received this message because you are subscribed to the Google Groups 
"Mojolicious" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to mojolicious+unsubscr...@googlegroups.com.
To post to this group, send email to mojolicious@googlegroups.com.
Visit this group at http://groups.google.com/group/mojolicious.
For more options, visit https://groups.google.com/d/optout.