Bug 1378178

Summary: svn diff fails with 'Cannot display: file marked as a binary type.'
Product: Red Hat Enterprise Linux 7 Reporter: Deepu K S <dkochuka>
Component: subversionAssignee: Joe Orton <jorton>
Status: CLOSED ERRATA QA Contact: Leos Pol <lpol>
Severity: high Docs Contact:
Priority: unspecified    
Version: 7.2CC: a.r.welter, dkochuka, jorton, pbhoot
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: subversion-1.7.14-13.el7 Doc Type: Bug Fix
Doc Text:
Cause: The "svn diff" command did not correctly handle file properties when operating against a remote repository. Consequence: As a consequence, "svn diff" could fail for a file labelled with a text MIME type property. Fix: Property handling in "svn diff" has now been fixed for remote repositories. Result: "svn diff" will now correctly generate diff files.
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-04-10 17:31:32 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1298243, 1420851    

Description Deepu K S 2016-09-21 17:49:06 UTC
Description of problem:
svn diff fails with 'Cannot display: file marked as a binary type.' even though file has svn:mime-type property set to "text/plain"

Version-Release number of selected component (if applicable):
Red Hat Enterprise Linux 7
subversion-1.7.14-10.el7.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Run svn diff on file with svn:mime-type set.
2.
3.

Actual results:
# rpm -q subversion
subversion-1.7.14-10.el7.x86_64

# svn propget svn:mime-type deploy_trunk.pl
text/plain

# svn diff --old deploy_trunk.pl --new svn+ssh://testserver/var/www/repos/newrepo/deploy_trunk.pl
root@testserver's password: 
Index: deploy_trunk.pl
===================================================================
Cannot display: file marked as a binary type.
svn: E000022: Valid UTF-8 data
(hex: 73 76 6e 3a 6d 69 6d 65 2d 74 79 70 65 20 3d 20 28)
followed by invalid UTF-8 sequence
(hex: c8 20 83 ab)

Expected results:
# rpm -q subversion
subversion-1.9.4-2.fc23.x86_64

# svn propget svn:mime-type deploy_trunk.pl
text/plain

# svn diff --old deploy_trunk.pl --new svn+ssh://testserver/var/www/repos/newrepo/deploy_trunk.pl
root@testserver's password: 
Index: deploy_trunk.pl
===================================================================
--- deploy_trunk.pl	(working copy)
+++ deploy_trunk.pl	(revision 3)
@@ -178,4 +178,3 @@
 	/0533/trunk
 	
 =cut
-=cut

Additional info:

Comment 13 errata-xmlrpc 2018-04-10 17:31:32 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2018:0938