• 
      

    Get rid of die().

    Review Request #8899 — Created April 14, 2017 and submitted

    Information

    RBTools
    release-0.7.x
    314d68d...

    Reviewers

    The die() method is one of the most ancient parts of RBTools, and it's long
    outlived its usefulness, especially now that more and more people are using
    RBTools as an API and not just a command.

    This change gets rid of it in favor of using exceptions, which are already all
    handled correctly.

    • Smoke tested rbt commands.
    • Ran unit tests.
    Description From Last Updated

    If we don't catch this, wont it be printed as: ERRROR: ERROR, no valid diffs: ... bceause of logging? Either …

    brenniebrennie

    Should we specialize this?

    brenniebrennie

    Would it be appropriate to use subprocess.CalledProcessError here?

    brenniebrennie
    brennie
    1. 
        
    2. rbtools/clients/perforce.py (Diff revision 1)
       
       
      Show all issues

      If we don't catch this, wont it be printed as: ERRROR: ERROR, no valid diffs: ... bceause of logging? Either way, I don't think we need the ERROR, at the beginning

    3. rbtools/utils/filesystem.py (Diff revision 1)
       
       
      Show all issues

      Should we specialize this?

      1. I don't think it's really necessary right now.

    4. rbtools/utils/process.py (Diff revision 1)
       
       
      Show all issues

      Would it be appropriate to use subprocess.CalledProcessError here?

      1. That's kind of hard to invoke with a custom message.

    5. 
        
    david
    david
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-0.7.x (a5e8a17)