#1389: tg_error mangling *arg and **kw
------------------------+---------------------------------------------------
Reporter: ldng | Owner: anonymous
Type: defect | Status: new
Priority: normal | Milestone: 1.0.3
Component: TurboGears | Version: 1.0.2
Severity: normal | Keywords:
------------------------+---------------------------------------------------
Hi,
I have a form which can be accessed through two url :
* www.example.com/item/create
* www.example.com/item/edit/45
create was defined as is :
* def create(self, *args, **kw)
and edit was an alias to create:
* edit = create
In the body I am testing for args length to know if I need to populate
the form or not.
While adding error handling I think I came across a bug (not sure though),
when I add tg_error=None to the definition of create:
* def create(self, tg_error=None, *args, **kw)
when accessing www.example.com/item/edit/45 I don't get a populated form
as I used to, but instead an empty form that has passed through valdation.
I can tell because of the error messages for missing fields.
It looks like a bug to me.
--
Ticket URL: <http://trac.turbogears.org/ticket/1389>
TurboGears <http://www.turbogears.org/>
TurboGears front-to-back web development
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears Tickets" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/turbogears-tickets?hl=en
-~----------~----~----~----~------~----~------~--~---