Closed parkerlreed closed 3 years ago
Just did a manual build (without aur pkg) and it works for me on arch.
Traceback (most recent call last):
File "/usr/bin/opensnitch-ui", line 40, in <module>
service = UIService(app, on_exit, args.config)
File "/usr/lib/python3.7/site-packages/opensnitch/service.py", line 42, in __init__
self._prompt_dialog = PromptDialog()
File "/usr/lib/python3.7/site-packages/opensnitch/dialogs/prompt.py", line 44, in __init__
self._apps_parser = LinuxDesktopParser()
File "/usr/lib/python3.7/site-packages/opensnitch/desktop_parser.py", line 35, in __init__
self._parse_desktop_file(desktop_file)
File "/usr/lib/python3.7/site-packages/opensnitch/desktop_parser.py", line 60, in _parse_desktop_file
parser.read(desktop_path, 'utf8')
File "/usr/lib/python3.7/configparser.py", line 696, in read
self._read(fp, filename)
File "/usr/lib/python3.7/configparser.py", line 1110, in _read
raise e
configparser.ParsingError: Source contains parsing errors: '/home/arch/.local/share/applications/wine-extension-vmp.desktop'
[line 4]: '\x01FileVersion\n'
Similar issue using opensnitch-git from the AUR.
Maintainer of the AUR package here: Seems like opensnitch sometimes crashes when parsing invalid .desktop
files, ie. when those are missing some fields ore have an invalid encoding. I could, for example, reproduce the error @parkerlreed had with recoll
installed; changing the encoding of /usr/share/applications/recoll-searchgui.desktop
to utf8
fixed it.
(I pretty much just put a print statement in line 60 in desktop_parser.py
to show me the file that was parsed before the error to find the culprit).
It might help to put some try/catch-thing around parser.read(desktop_path, 'utf8')
, but as my python-fu is rather limited I'll leave that to someone who knows how to do it.
Confirm lsfxz! As soon as I deleted the two [ru] lines Name and Comment in that file the error was gone and opensnitch compiled without further problems.
This should be fixed with latest AUR package.
opensnitch-git 20181122.363_61cf3d1-1 python-grpcio 1.16.1-1 python-grpcio-tools 1.14.0-1 python-unicode-slugify-git r41.8a9c3dc-2 go-pie 2:1.11.2-2
Enabled the service and then tried running the UI.