Closed Michal-Mikolas closed 10 years ago
Thanks @Michal-Mikolas, this should be fixed with version 1.5.1 of sublime WakaTime.
I updated my Sublime Text Wakatime plugin to last commit (version 1.5.1) and the error still occurs:
Traceback (most recent call last):
File ".\logging\__init__.py", line 768, in emit
File ".\logging\__init__.py", line 648, in format
File "C:\Dropbox\SublimeText2\Data\Packages\Wakatime\packages\wakatime\wakatime\log.py", line 62, in format
return CustomEncoder().encode(data)
File "C:\Dropbox\SublimeText2\Data\Packages\Wakatime\packages\wakatime\wakatime\packages\simplejson\encoder.py", line 264, in encode
chunks = list(chunks)
File "C:\Dropbox\SublimeText2\Data\Packages\Wakatime\packages\wakatime\wakatime\packages\simplejson\encoder.py", line 612, in _iterencode
for chunk in _iterencode_dict(o, _current_indent_level):
File "C:\Dropbox\SublimeText2\Data\Packages\Wakatime\packages\wakatime\wakatime\packages\simplejson\encoder.py", line 535, in _iterencode_dict
yield _encoder(value)
File "C:\Dropbox\SublimeText2\Data\Packages\Wakatime\packages\wakatime\wakatime\packages\simplejson\encoder.py", line 65, in py_encode_basestring_ascii
s = s.decode('utf-8')
File ".\encodings\utf_8.py", line 16, in decode
UnicodeDecodeError: 'utf8' codec can't decode bytes in position 22-26: unsupported Unicode code range
Error: Response code 102 from wakatime package
For sure, attaching full python log, from start Sublime Text: http://pastebin.com/UbjTtY7u
When I add code
print(data)
to log.py at line 62, console shows me this before error:
OrderedDict([('now', 'Mon Dec 02 22:50:56 St\xf8edn\xed Evropa (b\xec\x9en\xfd \xe8as) 2013'), ('version', '0.4.10'), ('plugin', 'sublime/2221 sublime-wakatime/1.5.1'), ('time', 1386021055.3959999), ('isWrite', True), ('file', u'C:\\Dropbox\\SublimeText2\\Data\\Packages\\Wakatime\\packages\\wakatime\\wakatime\\log.py'), ('level', 'ERROR'), ('message', {'response_code': 401, 'HTTPError': 'HTTP Error 401: UNAUTHORIZED'})])
I am from Czech Republic, so string St\xf8edn\xed Evropa means Střední Evropa (Central Europe). Don't know what encoding it is (maybe windows-1250, which is for central europe common).
Hope this helps.
@Michal-Mikolas thanks for the error message and printed data! It helped a bunch!
It should be fixed in v1.5.2 now.
In my Sublime Text 2, I am getting still same error.
But in clean install of Sublime Text 2, and in Sublime Text 3 with all plugins from my old Sublime Text 2, it works OK.
So, I think it is fixed now. Thank you ;-)
Thanks to your help :)
Hello, I installed and configured Wakatime to Sublime Text 2. Everytime I save any open file, I get error in python console and no time is tracked by Wakatime:
I have Windows 7 64bit.
Thanks.