> Kenneth: how did you happen to notice this? How did the extra
trailing slash get there in the first place?
I was testing an application and was using
http://domain/controller/applications/2 when I decided to start from the
begining with http://domain/controller/applications but I only removed
the number not the slash. And as my program was checking the length of
request.args and determined that length was 1. It took arg1 and tried to
use it as an number and gave me Internal ticket. I could not understand
what was wrong with my code until I found what I thought was as bug in
web2py.
I understand both sides but would still consider this a bug. Maybe bug
is a bit too strong word for it.
Kenneth
#2 follows the expectation that .../arg1 and .../arg1/ are the same, but it
does so at the expense of treating '' differently from all other arg values.
#3 takes a different approach, flatly declaring that trailing slashes are never
significant. The downside is that trailing empty args ('') cannot be made
explicit in the URL (though in fairness, in current web2py they're illegal,
so...).
We should get this resolved before Massimo releases the next stable version.
Massimo, do you have a preference? I'm leaning toward #1 at the moment, but not
very strongly.