Hello community,

here is the log from the commit of package perl-Mojolicious for 
openSUSE:Factory checked in at 2020-03-18 12:43:11
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-Mojolicious (Old)
 and      /work/SRC/openSUSE:Factory/.perl-Mojolicious.new.3160 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "perl-Mojolicious"

Wed Mar 18 12:43:11 2020 rev:124 rq:786004 version:8.34

Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-Mojolicious/perl-Mojolicious.changes        
2020-02-13 10:11:57.432355341 +0100
+++ 
/work/SRC/openSUSE:Factory/.perl-Mojolicious.new.3160/perl-Mojolicious.changes  
    2020-03-18 12:48:25.273068234 +0100
@@ -1,0 +2,23 @@
+Tue Mar 17 03:14:21 UTC 2020 -  <[email protected]>
+
+- updated to 8.34
+   see /usr/share/doc/packages/perl-Mojolicious/Changes
+
+  8.34  2020-03-16
+    - Removed experimental status from proxy->get_p, proxy->post_p and
+      proxy->start_p helpers in Mojolicious::Plugin::DefaultHelpers.
+    - Removed experimental status from compress and min_compress_size 
attributes
+      in Mojolicious::Renderer.
+    - Removed experimental status from high_water_mark attribute in
+      Mojo::IOLoop::Stream.
+    - Removed experimental status from respond method in Mojolicious::Renderer.
+    - Removed experimental status from bytes_waiting and can_write methods in
+      Mojo::IOLoop::Stream.
+    - Removed experimental status from dehop method in Mojo::Headers.
+    - Removed experimental status from scope_guard function in Mojo::Util.
+    - Improved size check in Mojolicious::Validator to only require one 
argument.
+    - Fixed Mojolicious::Validator to also validate empty string values 
instead of
+      ignoring them. This behaviour had caused a lot of confusion in the past.
+    - Fixed plugin generator not to use an __END__ section.
+
+-------------------------------------------------------------------

Old:
----
  Mojolicious-8.33.tar.gz

New:
----
  Mojolicious-8.34.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ perl-Mojolicious.spec ++++++
--- /var/tmp/diff_new_pack.lwF5QG/_old  2020-03-18 12:48:33.021072861 +0100
+++ /var/tmp/diff_new_pack.lwF5QG/_new  2020-03-18 12:48:33.021072861 +0100
@@ -17,7 +17,7 @@
 
 
 Name:           perl-Mojolicious
-Version:        8.33
+Version:        8.34
 Release:        0
 %define cpan_name Mojolicious
 Summary:        Real-time web framework

++++++ Mojolicious-8.33.tar.gz -> Mojolicious-8.34.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/Changes new/Mojolicious-8.34/Changes
--- old/Mojolicious-8.33/Changes        2020-02-11 13:00:49.000000000 +0100
+++ new/Mojolicious-8.34/Changes        2020-03-16 16:52:00.000000000 +0100
@@ -1,4 +1,21 @@
 
+8.34  2020-03-16
+  - Removed experimental status from proxy->get_p, proxy->post_p and
+    proxy->start_p helpers in Mojolicious::Plugin::DefaultHelpers.
+  - Removed experimental status from compress and min_compress_size attributes
+    in Mojolicious::Renderer.
+  - Removed experimental status from high_water_mark attribute in
+    Mojo::IOLoop::Stream.
+  - Removed experimental status from respond method in Mojolicious::Renderer.
+  - Removed experimental status from bytes_waiting and can_write methods in
+    Mojo::IOLoop::Stream.
+  - Removed experimental status from dehop method in Mojo::Headers.
+  - Removed experimental status from scope_guard function in Mojo::Util.
+  - Improved size check in Mojolicious::Validator to only require one argument.
+  - Fixed Mojolicious::Validator to also validate empty string values instead 
of
+    ignoring them. This behaviour had caused a lot of confusion in the past.
+  - Fixed plugin generator not to use an __END__ section.
+
 8.33  2020-02-11
   - Added EXPERIMENTAL humanize_bytes function to Mojo::Util. (kraih, coolo)
   - Added EXPERIMENTAL humanize_bytes method to Mojo::ByteStream.
@@ -2229,8 +2246,8 @@
 4.49  2013-10-17
   - Added tls_ciphers option to Mojo::IOLoop::Server::listen.
   - Added ciphers parameter to Mojo::Server::Daemon::listen.
-  - Removed experimental status from Mojolicioua::Validator.
-  - Removed experimental status from Mojolicioua::Validator::Validation.
+  - Removed experimental status from Mojolicious::Validator.
+  - Removed experimental status from Mojolicious::Validator::Validation.
   - Removed experimental status from validation method in
     Mojolicious::Controller.
   - Removed experimental status from validator attribute in Mojolicious.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/META.json 
new/Mojolicious-8.34/META.json
--- old/Mojolicious-8.33/META.json      2020-02-11 21:24:26.000000000 +0100
+++ new/Mojolicious-8.34/META.json      2020-03-16 18:26:07.000000000 +0100
@@ -62,6 +62,6 @@
       },
       "x_IRC" : "irc://irc.freenode.net/#mojo"
    },
-   "version" : "8.33",
+   "version" : "8.34",
    "x_serialization_backend" : "JSON::PP version 4.04"
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/META.yml 
new/Mojolicious-8.34/META.yml
--- old/Mojolicious-8.33/META.yml       2020-02-11 21:24:26.000000000 +0100
+++ new/Mojolicious-8.34/META.yml       2020-03-16 18:26:06.000000000 +0100
@@ -34,5 +34,5 @@
   homepage: https://mojolicious.org
   license: http://www.opensource.org/licenses/artistic-license-2.0
   repository: https://github.com/mojolicious/mojo.git
-version: '8.33'
+version: '8.34'
 x_serialization_backend: 'CPAN::Meta::YAML version 0.018'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/lib/Mojo/Headers.pm 
new/Mojolicious-8.34/lib/Mojo/Headers.pm
--- old/Mojolicious-8.33/lib/Mojo/Headers.pm    2020-01-14 20:58:35.000000000 
+0100
+++ new/Mojolicious-8.34/lib/Mojo/Headers.pm    2020-03-04 01:26:11.000000000 
+0100
@@ -409,10 +409,9 @@
 
 =head2 dehop
 
-  $heders = $headers->dehop;
+  $headers = $headers->dehop;
 
-Remove hop-by-hop headers that should not be retransmitted. Note that this
-method is B<EXPERIMENTAL> and might change without warning!
+Remove hop-by-hop headers that should not be retransmitted.
 
 =head2 dnt
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/lib/Mojo/IOLoop/Stream.pm 
new/Mojolicious-8.34/lib/Mojo/IOLoop/Stream.pm
--- old/Mojolicious-8.33/lib/Mojo/IOLoop/Stream.pm      2020-01-14 
20:58:36.000000000 +0100
+++ new/Mojolicious-8.34/lib/Mojo/IOLoop/Stream.pm      2020-03-04 
01:20:11.000000000 +0100
@@ -244,8 +244,7 @@
   $msg     = $msg->high_water_mark(1024);
 
 Maximum size of L</"write"> buffer in bytes before L</"can_write"> returns
-false, defaults to C<1048576> (1MiB). Note that this attribute is
-B<EXPERIMENTAL> and might change without warning!
+false, defaults to C<1048576> (1MiB).
 
 =head2 reactor
 
@@ -271,8 +270,7 @@
   my $num = $stream->bytes_waiting;
 
 Number of bytes that have been enqueued with L</"write"> and are waiting to be
-written. Note that this method is B<EXPERIMENTAL> and might change without
-warning!
+written.
 
 =head2 bytes_written
 
@@ -284,8 +282,7 @@
 
   my $bool = $stream->can_write;
 
-Returns true if calling L</"write"> is safe. Note that this method is
-B<EXPERIMENTAL> and might change without warning!
+Returns true if calling L</"write"> is safe.
 
 =head2 close
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/lib/Mojo/UserAgent/Server.pm 
new/Mojolicious-8.34/lib/Mojo/UserAgent/Server.pm
--- old/Mojolicious-8.33/lib/Mojo/UserAgent/Server.pm   2020-01-14 
20:58:25.000000000 +0100
+++ new/Mojolicious-8.34/lib/Mojo/UserAgent/Server.pm   2020-02-28 
11:16:13.000000000 +0100
@@ -104,9 +104,9 @@
 
 =head2 nb_url
 
-  my $url = $ua->nb_url;
-  my $url = $ua->nb_url('http');
-  my $url = $ua->nb_url('https');
+  my $url = $server->nb_url;
+  my $url = $server->nb_url('http');
+  my $url = $server->nb_url('https');
 
 Get absolute L<Mojo::URL> object for server processing non-blocking requests
 with L</"app"> and switch protocol if necessary.
@@ -119,9 +119,9 @@
 
 =head2 url
 
-  my $url = $ua->url;
-  my $url = $ua->url('http');
-  my $url = $ua->url('https');
+  my $url = $server->url;
+  my $url = $server->url('http');
+  my $url = $server->url('https');
 
 Get absolute L<Mojo::URL> object for server processing blocking requests with
 L</"app"> and switch protocol if necessary.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/lib/Mojo/Util.pm 
new/Mojolicious-8.34/lib/Mojo/Util.pm
--- old/Mojolicious-8.33/lib/Mojo/Util.pm       2020-02-11 19:51:52.000000000 
+0100
+++ new/Mojolicious-8.34/lib/Mojo/Util.pm       2020-03-04 01:17:25.000000000 
+0100
@@ -811,8 +811,7 @@
   my $guard = scope_guard sub {...};
 
 Create anonymous scope guard object that will execute the passed callback when
-the object is destroyed. Note that this function is B<EXPERIMENTAL> and might
-change without warning!
+the object is destroyed.
 
   # Execute closure at end of scope
   {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/Mojolicious-8.33/lib/Mojolicious/Command/Author/generate/plugin.pm 
new/Mojolicious-8.34/lib/Mojolicious/Command/Author/generate/plugin.pm
--- old/Mojolicious-8.33/lib/Mojolicious/Command/Author/generate/plugin.pm      
2020-01-14 20:58:43.000000000 +0100
+++ new/Mojolicious-8.34/lib/Mojolicious/Command/Author/generate/plugin.pm      
2020-02-22 18:04:28.000000000 +0100
@@ -107,7 +107,6 @@
 }
 
 1;
-<% %>__END__
 
 <% %>=encoding utf8
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/Mojolicious-8.33/lib/Mojolicious/Plugin/DefaultHelpers.pm 
new/Mojolicious-8.34/lib/Mojolicious/Plugin/DefaultHelpers.pm
--- old/Mojolicious-8.33/lib/Mojolicious/Plugin/DefaultHelpers.pm       
2020-01-14 20:58:41.000000000 +0100
+++ new/Mojolicious-8.34/lib/Mojolicious/Plugin/DefaultHelpers.pm       
2020-03-04 01:15:09.000000000 +0100
@@ -554,8 +554,7 @@
 
 Perform non-blocking C<GET> request and forward response as efficiently as
 possible, takes the same arguments as L<Mojo::UserAgent/"get"> and returns a
-L<Mojo::Promise> object. Note that this helper is B<EXPERIMENTAL> and might
-change without warning!
+L<Mojo::Promise> object.
 
   # Forward with exception handling
   $c->proxy->get_p('http://mojolicious.org')->catch(sub {
@@ -570,8 +569,7 @@
 
 Perform non-blocking C<POST> request and forward response as efficiently as
 possible, takes the same arguments as L<Mojo::UserAgent/"post"> and returns a
-L<Mojo::Promise> object. Note that this helper is B<EXPERIMENTAL> and might
-change without warning!
+L<Mojo::Promise> object.
 
   # Forward with exception handling
   $c->proxy->post_p('example.com' => form => {test => 'pass'})->catch(sub {
@@ -586,7 +584,6 @@
 
 Perform non-blocking request for a custom L<Mojo::Transaction::HTTP> object and
 forward response as efficiently as possible, returns a L<Mojo::Promise> object.
-Note that this helper is B<EXPERIMENTAL> and might change without warning!
 
   # Forward with exception handling
   my $tx = $c->ua->build_tx(GET => 'http://mojolicious.org');
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/lib/Mojolicious/Renderer.pm 
new/Mojolicious-8.34/lib/Mojolicious/Renderer.pm
--- old/Mojolicious-8.33/lib/Mojolicious/Renderer.pm    2020-01-14 
20:58:40.000000000 +0100
+++ new/Mojolicious-8.34/lib/Mojolicious/Renderer.pm    2020-03-04 
01:22:45.000000000 +0100
@@ -286,8 +286,7 @@
   $renderer = $renderer->compress($bool);
 
 Try to negotiate compression for dynamically generated response content and
-C<gzip> compress it automatically, defaults to false. Note that this attribute
-is B<EXPERIMENTAL> and might change without warning!
+C<gzip> compress it automatically, defaults to false.
 
 =head2 default_format
 
@@ -335,8 +334,7 @@
   $renderer = $renderer->min_compress_size(1024);
 
 Minimum output size in bytes required for compression to be used if enabled,
-defaults to C<860>. Note that this attribute is B<EXPERIMENTAL> and might 
change
-without warning!
+defaults to C<860>.
 
 =head2 paths
 
@@ -427,8 +425,7 @@
     Mojolicious::Controller->new, $output, $format, $status);
 
 Finalize dynamically generated response content and L</"compress"> it if
-possible. Note that this method is B<EXPERIMENTAL> and might change without
-warning!
+possible.
 
 =head2 template_for
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/Mojolicious-8.33/lib/Mojolicious/Validator/Validation.pm 
new/Mojolicious-8.34/lib/Mojolicious/Validator/Validation.pm
--- old/Mojolicious-8.33/lib/Mojolicious/Validator/Validation.pm        
2020-01-14 20:58:39.000000000 +0100
+++ new/Mojolicious-8.34/lib/Mojolicious/Validator/Validation.pm        
2020-03-16 16:37:43.000000000 +0100
@@ -75,7 +75,7 @@
     @input = map { $self->$cb($name, $_) } @input;
   }
   $self->output->{$name} = ref $input eq 'ARRAY' ? \@input : $input[0]
-    if @input && !grep { !length } @input;
+    if @input && !grep { !defined } @input;
 
   return $self->topic($name);
 }
@@ -231,7 +231,7 @@
 =head2 optional
 
   $v = $v->optional('foo');
-  $v = $v->optional('foo', 'filter1', 'filter2');
+  $v = $v->optional('foo', @filters);
 
 Change validation L</"topic"> and apply filters. All filters from
 L<Mojolicious::Validator/"FILTERS"> are supported.
@@ -263,11 +263,10 @@
 =head2 required
 
   $v = $v->required('foo');
-  $v = $v->required('foo', 'filter1', 'filter2');
+  $v = $v->required('foo', @filters);
 
-Change validation L</"topic">, apply filters, and make sure a value is present
-and not an empty string. All filters from L<Mojolicious::Validator/"FILTERS">
-are supported.
+Change validation L</"topic">, apply filters, and make sure a value is present.
+All filters from L<Mojolicious::Validator/"FILTERS"> are supported.
 
   # Trim value and check size
   $v->required('user', 'trim')->size(1, 15);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/lib/Mojolicious/Validator.pm 
new/Mojolicious-8.34/lib/Mojolicious/Validator.pm
--- old/Mojolicious-8.33/lib/Mojolicious/Validator.pm   2020-01-14 
20:58:39.000000000 +0100
+++ new/Mojolicious-8.34/lib/Mojolicious/Validator.pm   2020-03-16 
16:49:57.000000000 +0100
@@ -56,10 +56,10 @@
 sub _size {
   my ($v, $name, $value, $min, $max) = @_;
   my $len = ref $value ? $value->size : length $value;
-  return $len < $min || $len > $max;
+  return (defined $min && $len < $min) || (defined $max && $len > $max);
 }
 
-sub _trim { trim $_[2] // '' }
+sub _trim { defined $_[2] ? trim $_[2] : undef }
 
 1;
 
@@ -119,6 +119,8 @@
 =head2 size
 
   $v = $v->size(2, 5);
+  $v = $v->size(2, undef);
+  $v = $v->size(undef, 5);
 
 String value length or size of L<Mojo::Upload> object in bytes needs to be
 between these two values.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/lib/Mojolicious.pm 
new/Mojolicious-8.34/lib/Mojolicious.pm
--- old/Mojolicious-8.33/lib/Mojolicious.pm     2020-02-08 20:00:06.000000000 
+0100
+++ new/Mojolicious-8.34/lib/Mojolicious.pm     2020-03-07 14:32:21.000000000 
+0100
@@ -59,7 +59,7 @@
 has validator => sub { Mojolicious::Validator->new };
 
 our $CODENAME = 'Supervillain';
-our $VERSION  = '8.33';
+our $VERSION  = '8.34';
 
 sub BUILD_DYNAMIC {
   my ($class, $method, $dyn_methods) = @_;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/lib/ojo.pm 
new/Mojolicious-8.34/lib/ojo.pm
--- old/Mojolicious-8.33/lib/ojo.pm     2020-01-14 20:58:23.000000000 +0100
+++ new/Mojolicious-8.34/lib/ojo.pm     2020-02-12 18:41:16.000000000 +0100
@@ -80,7 +80,7 @@
 On Perl 5.20+ L<subroutine signatures|perlsub/"Signatures"> will be enabled
 automatically.
 
-  $ perl -Mojo -E 'a(sub ($c) { $c->render(text => 'Hello!') })->start' get /
+  $ perl -Mojo -E 'a(sub ($c) { $c->render(text => "Hello!") })->start' get /
 
 If it is not already defined, the C<MOJO_LOG_LEVEL> environment variable will
 be set to C<fatal>.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Mojolicious-8.33/t/mojolicious/validation_lite_app.t 
new/Mojolicious-8.34/t/mojolicious/validation_lite_app.t
--- old/Mojolicious-8.33/t/mojolicious/validation_lite_app.t    2020-01-14 
20:58:05.000000000 +0100
+++ new/Mojolicious-8.34/t/mojolicious/validation_lite_app.t    2020-03-16 
16:49:48.000000000 +0100
@@ -82,6 +82,11 @@
 is_deeply $v->output, {}, 'right result';
 ok $v->has_error, 'has error';
 
+# Empty string
+$v = $t->app->validation->input({foo => ''});
+ok $v->optional('foo')->is_valid, 'valid';
+is_deeply $v->output, {foo => ''}, 'right result';
+
 # Equal to
 $v = $t->app->validation->input({foo => 'bar', baz => 'bar', yada => 'yada'});
 ok $v->optional('foo')->equal_to('baz')->is_valid, 'valid';
@@ -179,6 +184,11 @@
 is_deeply $v->output, {foo => 'bar'}, 'right result';
 ok $v->has_error, 'has error';
 is_deeply $v->error('yada'), [qw(size 1 5 10)], 'right error';
+ok $v->required('foo')->size(1, undef)->is_valid, 'valid';
+ok !$v->required('foo')->size(4, undef)->is_valid, 'not valid';
+ok $v->required('foo')->size(undef, 4)->is_valid, 'valid';
+ok $v->required('foo')->size(undef, 3)->is_valid, 'valid';
+ok !$v->required('foo')->size(undef, 2)->is_valid, 'not valid';
 
 # Upload
 $v = $t->app->validation->input({
@@ -220,8 +230,8 @@
 ok $v->optional('baz', 'trim')->like(qr/^\d$/)->is_valid, 'valid';
 is_deeply $v->output, {foo => 'bar', baz => [0, 1]}, 'right result';
 $v = $t->app->validation->input({nothing => '  ', more => [undef]});
-ok !$v->required('nothing', 'trim')->is_valid, 'not valid';
-is_deeply $v->output, {}, 'right result';
+ok $v->required('nothing', 'trim')->is_valid, 'valid';
+is_deeply $v->output, {nothing => ''}, 'right result';
 ok $v->required('nothing')->is_valid, 'valid';
 is_deeply $v->output, {nothing => '  '}, 'right result';
 ok !$v->optional('more', 'trim')->is_valid, 'not valid';
@@ -236,12 +246,13 @@
 # Multiple empty values
 $v = $t->app->validation;
 ok !$v->has_data, 'no data';
-$v->input({foo => ['', 'bar', ''], bar => ['', 'baz', '']});
+$v->input({foo => ['', 'bar', ''], bar => ['', 'baz', undef]});
 ok $v->has_data, 'has data';
-ok !$v->required('foo')->is_valid, 'not valid';
-is_deeply $v->output, {}, 'right result';
+ok $v->required('foo')->is_valid, 'valid';
+ok !$v->required('bar')->is_valid, 'not valid';
+is_deeply $v->output, {foo => ['', 'bar', '']}, 'right result';
 ok $v->has_error, 'has error';
-is_deeply $v->error('foo'), ['required'], 'right error';
+is_deeply $v->error('bar'), ['required'], 'right error';
 
 # "0"
 $v = $t->app->validation->input({0 => 0});


Reply via email to