Modify

Opened 4 years ago

Closed 4 years ago

#7807 closed defect (fixed)

Show error into "after registration form"

Reported by: zefir Owned by: hasienda
Priority: normal Component: AccountManagerPlugin
Severity: normal Keywords: user registration
Cc: Trac Release: 0.11

Description

After registration have this error:

TypeError: __call__() got an unexpected keyword argument 'user'

From log:

2010-10-09 19:22:40,074 Trac[main] ERROR: Internal Server Error:.
Traceback (most recent call last):
  File "build/bdist.linux-i686/egg/trac/web/main.py", line 513, in _dispatch_request
    dispatcher.dispatch(req)
  File "build/bdist.linux-i686/egg/trac/web/main.py", line 235, in dispatch
    resp = chosen_handler.process_request(req)
  File "build/bdist.linux-i686/egg/acct_mgr/web_ui.py", line 401, in process_request
    user=tag.b(req.args.get('user')))))
TypeError: __call__() got an unexpected keyword argument 'user'

I changed in acct_mgr/web_ui.py strings 399-401:

                    """Registration has been finished successfully.
                    You may login as user %(user)s now.""",
                    user=tag.b(req.args.get('user')))))

into:

                    "Registration has been finished successfully."
                    "You may login as user ", tag.b(req.args.get('user')), " now.")))

for fix this error.

Attachments (1)

web_ui.py.diff (478 bytes) - added by zefir 4 years ago.
patch of this error

Download all attachments as: .zip

Change History (3)

Changed 4 years ago by zefir

patch of this error

comment:1 Changed 4 years ago by hasienda

  • Keywords user added
  • Status changed from new to assigned
  • Trac Release changed from 0.12 to 0.11

Thanks for taking your time for the report and suggested patch.

I confess, that I was not aware of this, since I'm already some steps ahead testing unreleased code. This would have been fixed by one of the next changesets introducing i18n support anyway, but we certainly should have stable code even in trunk at any time.

I'll apply your fix and revert message formatting later, since the suggested code is somewhat incompatible with i18n (see #6803). But you could hardly know this in advance.

comment:2 Changed 4 years ago by hasienda

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [9276]) AccountManagerPlugin: Intermediate fix for registraiont confirmation message introduced in [9199], closes #7807.

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.