Reputation: 1584
I'm trying to use strict slash with webapp2 redirect route and I'm getting this value error -
ValueError: Routes with strict_slash must have a name.
This is an example of one of my routes -
RedirectRoute(r'/',handler=IndexHandler,strict_slash=True)
It works fine if I don't have the strict_slash bit.
Upvotes: 3
Views: 480
Reputation: 806
I don't know why routes with a strict_slash need to have a name, but the following should work:
RedirectRoute(r'/',handler=IndexHandler,strict_slash=True,name='some_name')
Upvotes: 5