Vorta: Ignore Errors when Reading Wifis on macOS

Created on 31 Mar 2020  Â·  11Comments  Â·  Source: borgbase/vorta

Describe the bug
I installed vorta through homebrew. Vorta appears in the applications list but when I click on it nothing happens. It does not start.

To Reproduce
Steps to reproduce the behavior:

  1. Install through homebrew on macOS
  2. Start Vorta

Desktop (please complete the following information):

  • OS: macOS Catalina 10.15.4

Additional context
Can't reach the log...

good first issue macos bug

All 11 comments

Can you run it from the command line and see if any error is printed? E.g. from the app Terminal run:

$ /Applications/Vorta.app/Contents/MacOS/vorta

Can you run it from the command line and see if any error is printed? E.g. from the app Terminal run:

$ /Applications/Vorta.app/Contents/MacOS/vorta

I apologize I just realized the reply by email didn't work. On my system /Applications/Vorta.app/Contents/MacOS/vorta is a directory. In /Applications/Vorta.app/Contents/MacOS/ there exists a file called vorta-darwin. If I try to run this one I get the following:

2020-04-09 22:21:40,121 - vorta.i18n - DEBUG - Loading translation failed for ['C'].
2020-04-09 22:21:40,170 - apscheduler.scheduler - INFO - Scheduler started
Traceback (most recent call last):
  File "vorta/__main__.py", line 44, in <module>
  File "vorta/__main__.py", line 37, in main
  File "vorta/application.py", line 60, in __init__
  File "vorta/application.py", line 81, in open_main_window_action
  File "vorta/views/main_window.py", line 38, in __init__
  File "vorta/views/schedule_tab.py", line 29, in __init__
  File "vorta/views/schedule_tab.py", line 56, in populate_from_profile
  File "vorta/views/schedule_tab.py", line 60, in init_wifi
  File "vorta/utils.py", line 136, in get_sorted_wifis
KeyError: 'SSIDString'
[89276] Failed to execute script __main__

[Process completed]

There is an error when reading your Wifi list (lets you choose to only back up in certain networks).

We probably need an exception here. I'll add that. Thanks for reporting!

I see a similar error, but with a different message in detail:

$ /Applications/Vorta.app/Contents/MacOS/vorta

With this, nothing happens, I get the prompt back. Well, seems legit:

$ ls -la /Applications/Vorta.app/Contents/MacOS/vorta
lrwxr-xr-x@ 1 karsten  staff  18 May  4 11:22 /Applications/Vorta.app/Contents/MacOS/vorta -> ../Resources/vorta

$ ls -la /Applications/Vorta.app/Contents/Resources/vorta
total 0
drwxr-xr-x@  3 karsten  staff   96 Mar  3 06:56 .
drwxr-xr-x@ 10 karsten  staff  320 Mar  3 06:56 ..
drwxr-xr-x@  3 karsten  staff   96 Mar  3 06:56 i18n

So let's try /Applications/Vorta.app/Contents/MacOS/vorta-darwin instead:

$ /Applications/Vorta.app/Contents/MacOS/vorta-darwin
2020-05-04 11:25:16,300 - vorta.i18n - DEBUG - Loading translation failed for ['C'].
2020-05-04 11:25:16,325 - apscheduler.scheduler - INFO - Scheduler started
2020-05-04 11:25:16,664 - root - ERROR - Unable to parse list of Wifi networks.
Traceback (most recent call last):
  File "vorta/__main__.py", line 44, in <module>
  File "vorta/__main__.py", line 37, in main
  File "vorta/application.py", line 60, in __init__
  File "vorta/application.py", line 81, in open_main_window_action
  File "vorta/views/main_window.py", line 38, in __init__
  File "vorta/views/schedule_tab.py", line 29, in __init__
  File "vorta/views/schedule_tab.py", line 56, in populate_from_profile
  File "vorta/views/schedule_tab.py", line 60, in init_wifi
TypeError: 'NoneType' object is not iterable
[15851] Failed to execute script __main__

Not sure of that would be fixed by #440…

No, it wouldn't be fixed, @kdambekalns, but I have now added a fix to this PR.

I am on OS X 10.15.5 and have installed Vorta through HomeBrew. The Application does not launch through the Finder. When I attempt to launch it like so:
/Applications/Vorta.app/Contents/MacOS/vorta-darwin

I am still getting the very same output as shown previously:

[email protected]:/Users/Max $ /Applications/Vorta.app/Contents/MacOS/vorta-darwin
2020-06-25 21:00:16,966 - vorta.i18n - DEBUG - Loading translation succeeded for ['en', 'en-US', 'en-Latn-US'].
2020-06-25 21:00:17,001 - apscheduler.scheduler - INFO - Scheduler started
Traceback (most recent call last):
File "vorta/__main__.py", line 44, in
File "vorta/__main__.py", line 37, in main
File "vorta/application.py", line 60, in __init__
File "vorta/application.py", line 81, in open_main_window_action
File "vorta/views/main_window.py", line 52, in __init__
File "vorta/views/schedule_tab.py", line 29, in __init__
File "vorta/views/schedule_tab.py", line 56, in populate_from_profile
File "vorta/views/schedule_tab.py", line 60, in init_wifi
File "vorta/utils.py", line 162, in get_sorted_wifis
File "vorta/utils.py", line 162, in
KeyError: 'SSIDString'
[33206] Failed to execute script __main__

Any suggestions?

You have some entries with missing Wifi names in your /Library/Preferences/SystemConfiguration/com.apple.airport.preferences.plist. @Mallewax .

We already skip those entries further up in the function, but I just noticed it could also fail further down when removing old Wifis. You can try this PR https://github.com/borgbase/vorta/pull/525 or remove the malformed Wifi entry manually. Either way, it should work after the next update.

Thanks for reporting!

Wow, thanks for the quick response.

I am looking at this file. It is very big (in my case about 37,000 lines). No idea what to look for.

But I just moved it to my Desktop, out of this folder and then was trying to start Vorta again, on the command line. Still no luck.

What else can I try?

Andreas

You have an empty Wifi name somewhere (from a misconfigured Wifi you saw/connected to in the past)? Searching for this may find it:

<key>SSIDString</key>
<string></string>

(note the empty value after SSIDString

Else just wait for the next update or use this branch directly (needs Python installed locally).

You may also find the empty Wifi in Preferences > Network > Wifi.

But of course Vorta should just handle such weird input. That's what the above pull request solves.

I’ve searched for an empty string

In my file, but cannot find one. I guess I will have to wait for the upcoming fix….

Thanks anyway.

On Jun 25, 2020, at 22:21, Manu notifications@github.com wrote:

You may also find the empty Wifi in Preferences > Network > Wifi.

But of course Vorta should just handle such weird input. That's what the above pull request solves.

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub https://github.com/borgbase/vorta/issues/429#issuecomment-649912867, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQCBUR6W44YLSRQXTGYSDDLRYQAY7ANCNFSM4LXTV2YQ.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

derphilipp picture derphilipp  Â·  7Comments

thecursedfly picture thecursedfly  Â·  6Comments

michaelmcneff picture michaelmcneff  Â·  3Comments

cerebrux picture cerebrux  Â·  7Comments

strmd picture strmd  Â·  5Comments