Bug #45

Feature #1: Properly balanced registration system

The server crashes when updating the details of "old users"

Added by Luis Figueira about 14 years ago. Updated almost 14 years ago.

Status:ClosedStart date:2010-12-08
Priority:UrgentDue date:
Assignee:-% Done:

0%

Category:-
Target version:-

Description

When updating the details of an user w/o description, the server crashes

History

#1 Updated by Luis Figueira about 14 years ago

  • Status changed from New to In Progress

Ok, been thinking about the solution for this bug. This bug only affects the show "views" (not the edit, update, etc). What do you think we should do:

  1. test in the buggy view for the lack of model (and print something)
  2. in the migration that is responsible for creating the new model, update all the existing users so that their description (and other fields) is filled with default info.

I'd go for the second one. What is your opinion?

#2 Updated by Chris Cannam about 14 years ago

Both.

It looks (naively -- I don't know the code) as if the controller should set @description empty at users_controller.rb:55 if ssamr_user_detail is absent? Thus fixing option 1. I don't mind if the end result is to print an inexplicably empty description.

However, we should also ensure that the db row does actually exist, hence 2 as well.

(Sorry.)

#3 Updated by Chris Cannam about 14 years ago

btw, it would be much preferable if the database could be fixed up in an additional migration, because I'd like to do some other tests and tweaks on the existing code in the mean time (I've just merged from your branch to mine).

That is -- once a migration is made, passes its basic requirements tests, and is in a state where other users might want to use it, leave it alone, and do any extra work in further migrations. Is that reasonable?

#4 Updated by Chris Cannam almost 14 years ago

  • Status changed from In Progress to Closed

This one is fixed, merged, and live now, right?

#5 Updated by Luis Figueira almost 14 years ago

right-o.

Also available in: Atom PDF