Search Error message returned should be a more user friendly wording

Bug #519407 reported by Winnie
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Open Library
Fix Released
Medium
Anand Chitipothu

Bug Description

http://upstream.openlibrary.org/
Enter "Joseph Conrad" into search box
Click on "Search"
Search results have titles with Joseph Conrad and Joseph Conrad author books listed
Click on "More Search Options"
Do not enter any data
Click on "Search"

The following error messages are returned:

/templates/work_search.tmpl: error in processing template: UnboundLocalError: local variable 'results' referenced before assignment (falling back to default template)
/opt/openlibrary/staging/openlibrary/plugins/upstream/templates/work_search.html: error in processing template: UnboundLocalError: local variable 'results' referenced before assignment (falling back to default template)
Unable to render this page.

User should be returned a more user friendly message such as "No results with these search criteria" or " Please select search criteria" - discuss with George on exact wording.

Revision history for this message
George (george-archive) wrote :

A potentially simpler solution would be to not let an empty form be submitted. (That's that same as a couple of our other interactions, for example, when you try to add a new person to a role. If the box is empty, nothing happens.)

Anand - can you take care of this?

Search forms:
- site-wide search, top right
- main search page
- search subjects (on Subjects page)

Changed in openlibrary:
assignee: nobody → Anand Chitipothu (anandology)
importance: Undecided → Medium
milestone: none → upstream
Revision history for this message
George (george-archive) wrote :

Empty form doesn't make an error now. Good!

Changed in openlibrary:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.