4774: UTF8 decode errors when accessing subversion repo

seb

What version are you running?

3.0.11

What's the URL of the page containing the problem?

Any that access the repo, such as creating a new review request, viewing an existing request, or even trying to administer the repo: http://reviewboard.taitradio.net/admin/db/scmtools/repository/1/

What steps will reproduce the problem?

  1. Going to any of these URLs results in a 500 Server Error response.

What is the expected output? What do you see instead?

Expected the normal page, got a 500 instead.

What operating system are you using? What browser?

Ubuntu Bionic & Chrome on the browser side.
Ubuntu Bionic on the server side. This was recently re-deployed and previously running on Xenial. It may be that it broke as part of that process.

Please provide any additional information below.

I have attached rb-crash.txt that contains the information sent via email.
Sensitive information was replaced with ***.

Traceback (most recent call last):
  File "/home/reviewboard/.venv/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 112, in get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/home/reviewboard/.venv/local/lib/python2.7/site-packages/django/contrib/admin/options.py", line 465, in wrapper
    return self.admin_site.admin_view(view)(*args, **kwargs)
  File "/home/reviewboard/.venv/local/lib/python2.7/site-packages/django/utils/decorators.py", line 99, in _wrapped_view
    response = view_func(request, *args, **kwargs)
  File "/home/reviewboard/.venv/local/lib/python2.7/site-packages/django/views/decorators/cache.py", line 52, in _wrapped_view_func
    response = view_func(request, *args, **kwargs)
  File "/home/reviewboard/.venv/local/lib/python2.7/site-packages/django/contrib/admin/sites.py", line 198, in inner
    return view(request, *args, **kwargs)
  File "/home/reviewboard/.venv/local/lib/python2.7/site-package
seb
#1 seb

Creating a new repository accessing the same repo seems to work just fine.

seb
#2 seb

Ok, I tracked it down to the fact that the deployment process did not preserve SITE/conf/settings_local.py and in particular the master key there-in. I have restored that file from back-ups and it is now working again.

Catching the exception and giving a more explanatory error message saying that RB failed to decrypt the password, possibly due to a lost master key, might help someone else.

Also, if someone genuinely looses their master key, there is, as far as I could work out, currently no way to clear the encrypted passwords and set new ones except to delete the entire repo and creating it from scratch, which, AFAIK, looses all reviews. I'd say that definitely needs fixing.