Modify ↓
      
        Opened 16 years ago
Last modified 11 years ago
#5986 new defect
req.args.get('email') returns a list
| Reported by: | Owned by: | ||
|---|---|---|---|
| Priority: | normal | Component: | CaptchaAuthPlugin | 
| Severity: | normal | Keywords: | |
| Cc: | Trac Release: | 0.11 | 
Description
I don't know where the bug is, but captcha plugin fails when an anonymous user try to create (or just preview) a ticket.
here is the traceback:
Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/trac/web/main.py", line 444, in _dispatch_request
    dispatcher.dispatch(req)
  File "/usr/lib/python2.5/site-packages/trac/web/main.py", line 175, in dispatch
    chosen_handler)
  File "/usr/lib/python2.5/site-packages/trac/web/main.py", line 295, in _pre_process_request
    chosen_handler = filter_.pre_process_request(req, chosen_handler)
  File "/usr/lib/python2.5/site-packages/CaptchaAuth-0.6-py2.5.egg/captchaauth/auth.py", line 98, in pre_process_request
    name, email = self.identify(req)
  File "/usr/lib/python2.5/site-packages/CaptchaAuth-0.6-py2.5.egg/captchaauth/auth.py", line 378, in identify
    email = req.args.get('email', '').strip()
AttributeError: 'list' object has no attribute 'strip'
After some debugging, req.args.get('email', ) returns a list like that [u, u'test@…'] if I put test@… in email field.
trac-0.11.5 accountManager-0.2.1dev-r4679
Attachments (0)
Change History (3)
comment:1 Changed 16 years ago by
comment:2 Changed 16 years ago by
no there is not. email field contains only one email, no space arround. I tested to add emails to CC fielld, but that changes nothing: They don't appear in the email field.
comment:3 Changed 11 years ago by
| Owner: | Jeff Hammel deleted | 
|---|
Note: See
        TracTickets for help on using
        tickets.
    



is there some other email field on the page that could cause this to be multi-valued?