• Edward Lemur's avatar
    metrics: Separate metrics collection and print notice logic. · 6f812e13
    Edward Lemur authored
    As it is right now, when a function is collecting metrics it prints
    the notice and calls sys.exit() to ensure the notice is the last thing
    that is printed.
    
    git-cl split has to call git-cl upload multiple times, but once it has
    been called once, it exits, so only the first cl is uploaded.
    
    This separates metrics collection from notice printing, so that the
    function that is collecting metrics behaves like a function that isn't.
    It also makes sure we don't collect metrics for multiple functions at
    the same time.
    
    Bug: 868280
    Change-Id: Ic58ebe7d19e09ed85fa8b0af76dcbf608ee4c9bc
    Reviewed-on: https://chromium-review.googlesource.com/1153503Reviewed-by: 's avatarAaron Gable <agable@chromium.org>
    Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
    6f812e13
git_nav_downstream.py 1.85 KB