Fix mangling of SVN diffs that contain lines that look like headers.

Review Request #8934 — Created May 9, 2017 and submitted

Information

RBTools
release-0.7.x
bc5f118...

Reviewers

If a file has a removed line that looks vaguely like a file header (i.e. the
line is "-- XX (Y)"), the entry for the removed line in the diff would get
filtered out by our code that tries to mangle the diffs to make renames and
copies work properly.

This change makes the code that detects and mangles file headers much more
specific, looking at each chunk of 5 lines instead of lines one by one.

  • Created a reproduction case and verified that rbt diff and svn diff
    produced the same output.
  • Wrote a unit test and checked that the test failed before the change and
    succeeded afterward.
  • Ran entire test suite.
Description From Last Updated

W503 line break before binary operator

reviewbotreviewbot

I'd kinda rather keep the and at the end of the line, so we don't deal with errors every time …

chipx86chipx86

W503 line break before binary operator

reviewbotreviewbot

W503 line break before binary operator

reviewbotreviewbot

W503 line break before binary operator

reviewbotreviewbot
Checks run (1 failed, 1 succeeded)
flake8 failed.
JSHint passed.

flake8

brennie
  1. Ship It!
  2. 
      
chipx86
  1. 
      
  2. rbtools/clients/svn.py (Diff revision 1)
     
     
     
     
     
    Show all issues

    I'd kinda rather keep the and at the end of the line, so we don't deal with errors every time we post anything (and to be consistent with the majority of our code).

  3. 
      
david
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-0.7.x (8e28fae)
Loading...