xUnique icon indicating copy to clipboard operation
xUnique copied to clipboard

UnicodeDecodeError

Open glasscat opened this issue 4 years ago • 3 comments

Mac 10.15.4 Python 2.7 xUnique 4.1.4

UnicodeDecodeError: 'ascii' codec can't decode byte 0xe5 in position 20: ordinal not in range(128)

glasscat avatar Nov 05 '20 02:11 glasscat

More details pls

truebit avatar Nov 09 '20 13:11 truebit

I just encountered this as well (Python 2.7.16):

  File "scripts/xUnique.py", line 575, in <module>
    main()
  File "scripts/xUnique.py", line 552, in main
    xunique = XUnique(xcode_proj_path, options.verbose)
  File "scripts/xUnique.py", line 104, in __init__
    self.proj_json = self.pbxproj_to_json()
  File "scripts/xUnique.py", line 127, in pbxproj_to_json
    json_unicode_str = decoded_string(sp_co(pbproj_to_json_cmd))
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 216, in check_output
    process = Popen(stdout=PIPE, *popenargs, **kwargs)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 394, in __init__
    errread, errwrite)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 1047, in _execute_child
    raise child_exception
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 0: ordinal not in range(128)Traceback (most recent call last):
  File "scripts/xUnique.py", line 575, in <module>
    main()
  File "scripts/xUnique.py", line 552, in main
    xunique = XUnique(xcode_proj_path, options.verbose)
  File "scripts/xUnique.py", line 104, in __init__
    self.proj_json = self.pbxproj_to_json()
  File "scripts/xUnique.py", line 127, in pbxproj_to_json
    json_unicode_str = decoded_string(sp_co(pbproj_to_json_cmd))
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 216, in check_output
    process = Popen(stdout=PIPE, *popenargs, **kwargs)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 394, in __init__
    errread, errwrite)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 1047, in _execute_child
    raise child_exception
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 0: ordinal not in range(128)

carlosalban avatar Aug 24 '21 22:08 carlosalban

@carlosalban could you please post sp_co(pbproj_to_json_cmd) output for debug? or just send me the project file?

truebit avatar Aug 25 '21 02:08 truebit