Not providing an argument for show crashes the server

Bug #502003 reported by Matt Jones
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Rootin Tootin
Fix Released
Critical
Unassigned

Bug Description

If you try to go to a url that requires an argument, and you leave it off like:
http://localhost:3000/users/show/

The server crashes with the stupid error:
FIXME: inner loop threw

Revision history for this message
Matt Jones (workhorsy) wrote :

The problem is we are doing this to get the argument:

_user = User.find(to_ulong(_request._params["id"]));

Which is stupid and verbose. It should say something like "id argument required".

Changed in rester:
importance: Undecided → Critical
status: New → Confirmed
Revision history for this message
Matt Jones (workhorsy) wrote :

So these things need to be fixed:

1. The server should send the error to the browser when an unhandled exception is thrown.
2. Argument parsing should throw a "missing argument 'id'" exception

Revision history for this message
Matt Jones (workhorsy) wrote :

Fixed in trunk,

We now print the exception message, file, and line.

Changed in rester:
status: Confirmed → Fix Committed
Matt Jones (workhorsy)
Changed in rester:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.