Menu

#106 Advanced Title Search errors out when Term1 is omitted

closed-fixed
MartyD
5
2009-09-08
2009-08-30
Ahasuerus
No

Advanced Title Search errors out when Term2 is specified, but Term1 is omitted:

<type 'exceptions.NameError'> Python 2.5: /usr/bin/python
Sun Aug 30 18:09:46 2009

A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.
/var/www/cgi-bin/edit/tp_search.cgi in ()
128 need_right_paren = 1
129 else:
130 terms += " " +op1+ " "
131 # Escape spaces since 'AND NOT' is possible
132 followups = followups + "+op%3D" + escape_spaces(op1)
terms undefined, op1 = 'AND'

<type 'exceptions.NameError'>: name 'terms' is not defined

Discussion

  • Ahasuerus

    Ahasuerus - 2009-08-31
    • assigned_to: nobody --> marty-d
     
  • MartyD

    MartyD - 2009-09-08

    Fixed by the commits of 8-Sep-2009 for edit/ap_search.py 1.9, pp_search 1.8, and tp_search 1.8. All three types of advanced search had this same problem. Modified each set of code to check for omission of prior term(s) and to handle the various constructions appropriately, rather than assuming any prior terms are present.

     
  • MartyD

    MartyD - 2009-09-08
    • status: open --> open-fixed
     
  • Ahasuerus

    Ahasuerus - 2009-09-08

    Implemented in patch r2009-21.

     
  • Ahasuerus

    Ahasuerus - 2009-09-08
    • status: open-fixed --> closed-fixed
     

Anonymous
Anonymous

Add attachments
Cancel





MongoDB Logo MongoDB