Anonymous avatarAnonymous created an issue
** Mercurial version (2.3.1).  TortoiseHg version (2.5)
** Command: --nofork workbench
** CWD: T:\P20120720-万事兴KP22
** Encoding: cp936
** Extensions loaded: 
** Python version: 2.7.3 (default, Apr 10 2012, 23:31:26) [MSC v.1500 32 bit (Intel)]
** Windows version: sys.getwindowsversion(major=5, minor=1, build=2600, platform=2, service_pack='Service Pack 3')
** Processor architecture: x86
** Qt-4.8.0 PyQt-4.9.1
Traceback (most recent call last):
  File "tortoisehg\hgqt\fileview.pyo", line 317, in displayFile
  File "tortoisehg\util\hglib.pyo", line 70, in fromunicode
UnicodeEncodeError: 'gbk' codec can't encode character u'\xa1' in position 4: illegal multibyte sequence

Comments (10)

  1. Priory

    I then exported the same patch to a file and tried to import it, with a failure message:

        % hg import --repository C:\dev\rm_dev2 --verbose -- C:\dev\temp\patch_6101\rm_dev_6101.patch
        applying C:\dev\temp\patch_6101\rm_dev_6101.patch
        patching file Code/Sundial/Sundial.root/Sundial/RMUtils/RMUtil.cs
        patching file Code/Sundial/Sundial.root/Sundial/RMUtils/RMUtils - Console.csproj
        patching file Code/Sundial/Sundial.root/Sundial/RM_2010.sln
        Hunk #1 succeeded at 158 with fuzz 2 (offset -2 lines).
        Hunk #2 FAILED at 2471
        1 out of 2 hunks FAILED -- saving rejects to file Code/Sundial/Sundial.root/Sundial/RM_2010.sln.rej
        adding RMUtils - Console.csproj
        abort: patch failed to apply
        [command returned code 255 Wed Oct 24 00:41:51 2012]

    Which is a different error - the .sln file has been modified so the patch can't be directly applied. This suggests that the UnicodeError is only related to copying patches to the clipboard?

  2. Log in to comment
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.