Hi.
I have problem with routing in Mojolicious > 5.15.
my $r = $self->routes;
$r->get('/tags/:tag.rss')->to('router#tags_tag_rss');
$r->get('/tags/:tag')->to('router#tags_tag');
In M 5.15
% ./script/mojo_twist routes --verbose
...
/tags/:tag.rss .... GET tagstagrss ^/tags/([^\/\.]+)\.rss(?:\.([^/]+)$)?
/tags/:tag .... GET tagstag ^/tags/([^\/\.]+)(?:\.([^/]+)$)?
In M 5.16
% ./script/mojo_twist routes --verbose
...
/tags/:tag.rss .... GET tagstagrss ^/tags/([^\/\.]+)(?:\.([^/]+)$)?
/tags/:tag .... GET tagstag ^/tags/([^\/\.]+)(?:\.([^/]+)$)?
I think this happened after Mojolicious::Routes::Pattern::_tokenize has been changed
I tried to fix my problem with:
1. $r->get('/tags/:tag', format => 'rss')->to('router#tags_tag_rss');
routes --verbose
/tags/:tag .C.. GET tagstag ^/tags/([^\/\.]+)(?:\.([^/]+)$)?
2. $r->get('/tags/:tag', tag => qr/rss$/)->to('router#tags_tag_rss');
routes --verbose
/tags/:tag .C.. GET tagstag ^/tags/([^\/\.]+)(?:\.([^/]+)$)?
None of these solutions work. App always trying call router#tags_tag.
How to fix a problem with routing if this behavior is normal?