ephraim / lcurse

Python script to have a "curse" compatible client for linux
The Unlicense
51 stars 23 forks source link

Possible error with Unicode characters #42

Closed Dissectional closed 7 years ago

Dissectional commented 7 years ago

Since installing the addon "ElvUI Aura Bars Mover". I am unable to use Import function.

Traceback (most recent call last):
  File "/home/[REDACTED]/git/lcurse/modules/application.py", line 249, in importAddons
    tmp = self.extractAddonMetadataFromTOC(toc)
  File "/home/[REDACTED]/git/lcurse/modules/application.py", line 195, in extractAddonMetadataFromTOC
    line = f.readline()
  File "/usr/lib/python3.5/codecs.py", line 321, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xc2 in position 183: invalid continuation byte
[1]    8117 abort      lcurse

Trying to remove this addon using lcurse also gives a similar error;

Traceback (most recent call last):
  File "/home/[REDACTED]/git/lcurse/modules/application.py", line 372, in removeAddon
    tmp = self.extractAddonMetadataFromTOC(toc)
  File "/home/[REDACTED]/git/lcurse/modules/application.py", line 195, in extractAddonMetadataFromTOC
    line = f.readline()
  File "/usr/lib/python3.5/codecs.py", line 321, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xc2 in position 183: invalid continuation byte
[1]    8228 abort      lcurse

I have manually removed this addon from my Interface/Addons directory and this fixes the issue. The contents of the ElvUI_AuraBarsMovers.toc file are:

## Interface: 70000
## Title: |cff1784d1ElvUI |rAura Bars Mover
## Author: Darth Predator
## Version: 1.25
## Notes: Moveble unit aura bars for |cff1784d1ElvUI|r.
## Notes-ruRU: Âîçìîæíîòü ïåðåìåùåíèÿ ïîëîñ àóð â |cff1784d1ElvUI|r.
## eMail: darthpred@gmail.com
## URL: 
## RequiredDeps: ElvUI
## OptionalDeps: ElvUI_SLE
## DefaultState: Enabled

LibElvUIPlugin-1.0\locales\load_locales.xml
LibElvUIPlugin-1.0\LibElvUIPlugin-1.0.lua
core.lua
options.lua

## X-Tukui-ProjectID: 76
## X-Tukui-ProjectFolders: ElvUI_AuraBarsMovers

Not sure if this is an issue with lcurse or my computer, in the case it may be the latter it's probably worth noting I have always received this error on launch but until this time have had no problems from it:

WARNING: gui translation file could not be found: /home/[REDACTED]/git/lcurse/translations/en_NZ.qm