Add a centralized list of API error codes.

Review Request #4305 — Created July 7, 2013 and submitted

Information

Review Board
master

Reviewers

Add a centralized list of API error codes.

Right now we don't use the API error codes very much from our frontend code, but
I'm expecting that to change as we make things more dynamic. This adds a
centralized list of them so we don't sprinkle constants everywhere.
Ran js-tests, used the codes in my new review request rewrite.
Description From Last Updated

===

chipx86chipx86
reviewbot
  1. This is a review from Review Bot.
      Tool: PEP8 Style Checker
      Processed Files:
      Ignored Files:
        reviewboard/static/rb/js/models/diffModel.js
        reviewboard/static/rb/js/models/baseResourceModel.js
    
    
  2. 
      
reviewbot
  1. This is a review from Review Bot.
      Tool: Pyflakes
      Processed Files:
      Ignored Files:
        reviewboard/static/rb/js/models/diffModel.js
        reviewboard/static/rb/js/models/baseResourceModel.js
    
    
  2. 
      
chipx86
  1. Seems fine, but I'm wondering if we should just make this its own object. That would let us shorten all references quite a bit.
  2. 
      
david
reviewbot
  1. This is a review from Review Bot.
      Tool: PEP8 Style Checker
      Processed Files:
        reviewboard/settings.py
      Ignored Files:
        reviewboard/static/rb/js/utils/apiErrors.js
        reviewboard/static/rb/js/models/diffModel.js
    
    
  2. 
      
reviewbot
  1. This is a review from Review Bot.
      Tool: Pyflakes
      Processed Files:
        reviewboard/settings.py
      Ignored Files:
        reviewboard/static/rb/js/utils/apiErrors.js
        reviewboard/static/rb/js/models/diffModel.js
    
    
  2. 
      
chipx86
  1. Ship It!
  2. 
      
david
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to master (932b2e3).
Loading...