Bug#806265: Re-sending an account verification link on an already-activated causes a 500 error

Steve McIntyre <[email protected]>
Newsgroups gmane.linux.debian.devel.www
Message-ID <20151126003930.11777.88052.reportbug__18875.597176566$1448498559$gmane$org@tack.local>
Package: wiki.debian.org
Severity: normal

As reported:

when I try to create a user account on the Debian wiki which uses a
name already taken, I get the following message:

This user name already belongs to somebody else. If this is a new
account and you need another verification link, try sending another
one.

"sending another one" links to
https://wiki.debian.org/InstallingDebianOn/Allwinner?action=newaccount&i=1162379783.5.60584&resend=1
in my case. Going to this page results in an internal server error.

I've confirmed this and I can see the problem in the apache logs:

 [wsgi:error] mod_wsgi (pid=19132): Exception occurred processing WSGI script '/srv/wiki.debian.org/bin/moin.wsgi'.
 [wsgi:error]  Traceback (most recent call last):
 [wsgi:error]    File "/usr/lib/python2.7/dist-packages/werkzeug/wsgi.py", line 588, in __call__
 [wsgi:error]      return self.app(environ, start_response)
 [wsgi:error]    File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 264, in __call__
 [wsgi:error]      response = run(context)
 [wsgi:error]    File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 89, in run
 [wsgi:error]      response = dispatch(request, context, action_name)
 [wsgi:error]    File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 137, in dispatch
 [wsgi:error]      response = handle_action(context, pagename, action_name)
 [wsgi:error]    File "/usr/lib/python2.7/dist-packages/MoinMoin/wsgiapp.py", line 203, in handle_action
 [wsgi:error]      handler(context.page.page_name, context)
 [wsgi:error]    File "/usr/lib/python2.7/dist-packages/MoinMoin/action/newaccount.py", line 259, in execute
 [wsgi:error]      mailok, msg = _send_verification_mail(request, theuser)
 [wsgi:error]    File "/usr/lib/python2.7/dist-packages/MoinMoin/action/newaccount.py", line 22, in _send_verification_mail
 [wsgi:error]      'v': user.account_verification}
 [wsgi:error]  AttributeError: User instance has no attribute 'account_verification'


-- System Information:
Debian Release: 8.2
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.16.0-4-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.