GUI doesn't report network errors clearly

Bug #384853 reported by Beni Cherniavsky
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
SubDownloader
Confirmed
Medium
Unassigned

Bug Description

After I have SD open for a long time, upload operations fail with a generic message along the lines of "network connection error, try again later". Simply trying again doesn't help, but logging out and back in does.

The console shows a traceback:

Traceback (most recent call last):
  File "/home/beni/Working/subdownloader/gui/uploadlistview.py", line 132, in ObtainUploadInfo
    results = self._main.OSDBServer.TryUploadSubtitles(videos, no_update = True)
  File "/home/beni/Working/subdownloader/modules/SDService.py", line 456, in TryUploadSubtitles
    return TryUploadSubtitles(videos, no_update)
  File "/home/beni/Working/subdownloader/modules/SDService.py", line 74, in __call__
    result = self.function(*args)
  File "/home/beni/Working/subdownloader/modules/SDService.py", line 501, in _TryUploadSubtitles
    else:
KeyError: 'alreadyindb'

I dug a little into the code - the value of result at this point is {'status': '401 Unauthorized', 'token': 'hselggjokb4qfetn0o81c06l25'}.

The whole SDService.py file seems to handle errors poorly:
1. some errors are caught, written to the log and *ignored* - functions silently return None, etc.
2. XMLRPC status is never checked, it's just assumed to be 200.
I can imagine many other situations where it wouldn't report failures properly to the user.

- Version: 2.0.10 (bzr trunk actually)
- OS: Linux (ubuntu Jaunty)

Changed in subdownloader:
importance: Undecided → Medium
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.