• 
      

    Catch unexpected errors when validating diffs.

    Review Request #7458 — Created June 26, 2015 and submitted

    Information

    Review Board
    release-2.0.x
    9695cdf...

    Reviewers

    Unexpected errors could cause the diff validation resource to return a
    HTTP 500, which is not very useful. We now catch this and return a more
    suitable error, and log a traceback.

    Generated a fake exception, and saw the error information logged and
    returned through the API.

    Had a customer test this as well.

    Description From Last Updated

    Can we log the exception here?

    daviddavid
    reviewbot
    1. Tool: Pyflakes
      Processed Files:
          reviewboard/webapi/resources/validate_diff.py
      
      
      
      Tool: PEP8 Style Checker
      Processed Files:
          reviewboard/webapi/resources/validate_diff.py
      
      
    2. 
        
    david
    1. 
        
    2. Show all issues

      Can we log the exception here?

      1. This will appear as part of the exception traceback.

      2. Oh, it's logging.exception.

    3. 
        
    david
    1. Ship It!
    2. 
        
    chipx86
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-2.0.x (bcad7db)