When searching in groups for name that doesn't exist (eg. asdfasdfasdf) it crashes.
Steps to reproduce
go to groups
in search bar enter gibberish
click enter
Expected Results
Redirects us to the /groups page and notifies us that the group asdfasdfasdf does not exist.
Error Log
2016-07-19 08:45:21,993 INFO [waitress:8221][sqlalchemy.engine.base.Engine:base][_execute_context:1100] (1, 0, u'asdfasdfasd%', u'asdfasdfasd%')
2016-07-19 08:45:21,993 INFO [waitress:8221][sqlalchemy.engine.base.Engine:base][_rollback_impl:666] ROLLBACK
2016-07-19 08:45:21,995 ERROR [waitress:8221][pyramid_debugtoolbar:toolbar][toolbar_tween:227] Exception at http://0.0.0.0:6543/group/search/asdfasdfasd
traceback url: http://0.0.0.0:6543/_debug_toolbar/exception?token=5a1d7d28420c1909a106&tb=139974857294800
Traceback (most recent call last):
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid_debugtoolbar/toolbar.py", line 209, in toolbar_tween
response = _handler(request)
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid_debugtoolbar/panels/performance.py", line 57, in resource_timer_handler
result = handler(request)
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid/tweens.py", line 62, in excview_tween
reraise(*attrs['exc_info'])
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid/tweens.py", line 22, in excview_tween
response = handler(request)
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid_tm/__init__.py", line 101, in tm_tween
reraise(*exc_info)
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid_tm/__init__.py", line 83, in tm_tween
response = handler(request)
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid/router.py", line 158, in handle_request
view_name
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid/view.py", line 547, in _call_view
response = view_callable(context, request)
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid/viewderivers.py", line 442, in rendered_view
result = view(context, request)
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/pyramid/viewderivers.py", line 123, in _class_requestonly_view
response = getattr(inst, attr)()
File "/home/skrzepto/Documents/repo/fas/fas/views/groups.py", line 122, in search
_('No group found for the query: %s') % _id, 'error')
File "/home/skrzepto/.virtualenvs/fas-python2.7/lib/python2.7/site-packages/translationstring/__init__.py", line 95, in __mod__
'Can only interpolate translationstring '
ValueError: Can only interpolate translationstring with dictionaries.
Summary
When searching in groups for name that doesn't exist (eg.
asdfasdfasdf
) it crashes.Steps to reproduce
Expected Results
Redirects us to the /groups page and notifies us that the group
asdfasdfasdf
does not exist.Error Log