Traceback in czech bible download

Bug #1160506 reported by matysek
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenLP
Status tracked in Trunk
2.0
Fix Released
Medium
matysek
Trunk
Fix Released
Medium
matysek

Bug Description

Recently were made available for openlp new czech bibles.
- they appear in the first-time wizard
- downloading any of them causes the following traceback:

Traceback (most recent call last):
  File "/home/andreas/Projects/OpenLP/trunk/openlp/core/ui/firsttimeform.py", line 222, in onCurrentIdChanged
    self._preWizard()
  File "/home/andreas/Projects/OpenLP/trunk/openlp/core/ui/firsttimeform.py", line 354, in _preWizard
    size = self._getFileSize(u'%s%s' % (self.web, filename))
  File "/home/andreas/Projects/OpenLP/trunk/openlp/core/ui/firsttimeform.py", line 306, in _getFileSize
    return int(meta.getheaders("Content-Length")[0])
IndexError: list index out of range

- this happens in 2.0.1 and in trunk
- the OS and if it is source or build do not matter

Possible cause could be:
- wrong syntax of download.cfg
- download.cfg is not properly parsed.

Related branches

Revision history for this message
matysek (mzibricky) wrote :

After some discussion on IRC this seems to be the root cause:

- openlp need to know the filesize of the bible file
  - this size is checked for bibles on openlp site
  - then bible files are downloaded from sourceforge

- get the filesize will fail for new modules added only to sourceforge and not to openlp site!

Ways to fix it:
- specify filesize in the download.cfg file
- igure out how to get SF.net to return the file size

Revision history for this message
matysek (mzibricky) wrote :

Another issue with download is that OpenLP doesn't actually use the url in the download.cfg.

The download should use only the URL from the download.cfg, no other URLs.

Revision history for this message
Phill (phill-ridout) wrote :

I've set this to medium, as we dont want a regression later on.

Revision history for this message
JUDE ADO (jadoghe) wrote :

please i have been trying to run my irst timewizard when this bug up please assist me on hoe to overcome this trouble. thanks

Traceback (most recent call last):
  File "D:\OpenLP_Code\2.0\build\pyi.win32\OpenLP\out00-PYZ.pyz\openlp.core.ui.firsttimeform", line 219, in nextId
  File "D:\OpenLP_Code\2.0\build\pyi.win32\OpenLP\out00-PYZ.pyz\openlp.core.ui.firsttimeform", line 349, in _buildThemeScreenshots
UnboundLocalError: local variable 'item' referenced before assignment

Revision history for this message
matysek (mzibricky) wrote :

Please try latest 2.0.x release.

Revision history for this message
Phill (phill-ridout) wrote :

I can download the Czech bibles in trunk r2441 matysek, can you confirm?

Revision history for this message
matysek (mzibricky) wrote :

I confirm, that downloading works in trunk r2460.

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.