Warning: Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.

Ticket #157 (closed defect: duplicate)

Opened 14 years ago

Last modified 12 years ago

validators in expose cripple arguments

Reported by: anonymous Owned by: anonymous
Priority: high Milestone:
Component: TurboGears Version: 0.8
Severity: major Keywords:


@turbogears.expose(validators=dict(Unit=validators.Number())) def newRow(self, submit, startIndex, kw):

newrow = Row(kw) ##SQLObject

If Unit is a valid Number, viola everything works, but if Unit is invalid or associated with Null the entry gets removed and the call to newRow always comes crashing down with

TypeError?: init() takes at least 4 arguments (2 given)

how can that be prevented? did I miss something? SQLObject uses default values, so if the thing is invalid I want to use the SQLObject default and not have thing come crashing down on me.

Change History

comment:1 Changed 14 years ago by kevin

  • Status changed from new to closed
  • Resolution set to duplicate

dupe of #44, which is fixed in svn.

Note: See TracTickets for help on using tickets.