Corrected work with encoding on subversion and generate diff

Review Request #6205 — Created Aug. 7, 2014 and discarded

Information

Review Board
master
934db59...

Reviewers

When repository encoding different from UTF-8, applying unicode (utf-8) diff to non utf-8 original file may cause an error (reviewboard/diffviewer/diffutils.py 'patch' function).
Also in code of both subversion client encoding of repository was hardcoded.


 
Description From Last Updated

list comprehension redefines 'file_attachment' from line 583

reviewbotreviewbot

undefined name '_'

reviewbotreviewbot

undefined name '_'

reviewbotreviewbot

Col: 80 E501 line too long (83 > 79 characters)

reviewbotreviewbot

Might as well use a list, since this is called encoding_list

daviddavid
reviewbot
  1. Tool: Pyflakes
    Processed Files:
        reviewboard/reviews/views.py
        reviewboard/webapi/resources/base_patched_file.py
        reviewboard/scmtools/svn/pysvn.py
        reviewboard/scmtools/svn/base.py
        reviewboard/webapi/resources/base_original_file.py
        reviewboard/diffviewer/chunk_generator.py
        reviewboard/diffviewer/diffutils.py
        reviewboard/scmtools/svn/subvertpy.py
        reviewboard/scmtools/svn/__init__.py
    
    
    
    Tool: PEP8 Style Checker
    Processed Files:
        reviewboard/reviews/views.py
        reviewboard/webapi/resources/base_patched_file.py
        reviewboard/scmtools/svn/pysvn.py
        reviewboard/scmtools/svn/base.py
        reviewboard/webapi/resources/base_original_file.py
        reviewboard/diffviewer/chunk_generator.py
        reviewboard/diffviewer/diffutils.py
        reviewboard/scmtools/svn/subvertpy.py
        reviewboard/scmtools/svn/__init__.py
    
    
  2. reviewboard/reviews/views.py (Diff revision 1)
     
     
    Show all issues
     list comprehension redefines 'file_attachment' from line 583
    
  3. Show all issues
     undefined name '_'
    
  4. Show all issues
     undefined name '_'
    
  5. Show all issues
    Col: 80
     E501 line too long (83 > 79 characters)
    
  6. 
      
1T
reviewbot
  1. Tool: Pyflakes
    Processed Files:
        reviewboard/reviews/views.py
        reviewboard/webapi/resources/base_patched_file.py
        reviewboard/scmtools/svn/pysvn.py
        reviewboard/scmtools/svn/base.py
        reviewboard/webapi/resources/base_original_file.py
        reviewboard/diffviewer/chunk_generator.py
        reviewboard/diffviewer/diffutils.py
        reviewboard/scmtools/svn/subvertpy.py
        reviewboard/scmtools/svn/__init__.py
    
    
    
    Tool: PEP8 Style Checker
    Processed Files:
        reviewboard/reviews/views.py
        reviewboard/webapi/resources/base_patched_file.py
        reviewboard/scmtools/svn/pysvn.py
        reviewboard/scmtools/svn/base.py
        reviewboard/webapi/resources/base_original_file.py
        reviewboard/diffviewer/chunk_generator.py
        reviewboard/diffviewer/diffutils.py
        reviewboard/scmtools/svn/subvertpy.py
        reviewboard/scmtools/svn/__init__.py
    
    
  2. 
      
david
  1. Something about the way you updated the diff isn't correct. Revision 2 seems to use your first revision as a parent diff, instead of just containing a full diff between upstream and your code.

    1. I've updated diff, but got an 500 error during publishing changes.

  2. 
      
1T
david
  1. I haven't looked too closely at the code yet, because your "Testing done" section is not filled out. For a change like this, we really need to know what testing steps you've taken already.

  2. reviewboard/scmtools/svn/base.py (Diff revision 3)
     
     
    Show all issues

    Might as well use a list, since this is called encoding_list

  3. 
      
1T
Review request changed
Status:
Discarded