• 
      

    Add validation for the cache backend setting.

    Review Request #2815 — Created Jan. 21, 2012 and submitted

    Information

    Review Board
    release-1.6.x

    Reviewers

    Add validation for the cache backend setting.
    
    If users type the wrong thing into the cache backend setting in the admin site,
    it can save to the database, which will then cause any request to the site to
    generate a traceback. This is particularly annoying because settings are stored
    as a big JSON blob, so it's not even easy to fix.
    
    This change adds validation using django's parse_backend_uri--if the form can
    parse it, we know that this won't cause problems later on.
    Tested in devserver by specifying a bogus cache backend URI.
    Description From Last Updated

    Should there be another line break here?

    mike_conleymike_conley
    mike_conley
    1. Hey David,
      
      This looks good to me.  Just one style issue, and a question.
      
      Thanks,
      
      -Mike
    2. reviewboard/admin/forms.py (Diff revision 1)
       
       
      Show all issues
      Should there be another line break here?
      1. Not here, but I did add one too many lines below. Will fix.
    3. reviewboard/admin/forms.py (Diff revision 1)
       
       
      I notice that this function is never called - am I correct in assuming that this will be automatically called via Django magic?
      1. Yeah, django calls clean_* for each field, if it exists
    4. 
        
    david
    chipx86
    1. Ship It!
    2. 
        
    david
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-1.6.x (d904929).