Problem with v1 theme with non-english characters in the name

Bug #882819 reported by Carsten Tinggaard
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenLP
Fix Released
Low
Meinert Jordan

Bug Description

Windows 7, 64 bit, Home Premium and Vista Home Premium
OpenLP 1.9.7

Importing a v1 theme with non-english characters in the name results in three times of this dialog:
Error
File is not a valid theme
The content encoding is not UTF-8

and one time of this dialog:
Validation Error:
File is not a valid theme

This defect is related to Windows only since non-english characters in filenames are allowed from Win95 and onwards.

Attached example theme

Revision history for this message
Carsten Tinggaard (catini) wrote :
Revision history for this message
Andreas Preikschat (googol-deactivatedaccount) wrote :

Thank you for reporting this. I was able to reproduce this.

Changed in openlp:
importance: Undecided → Medium
status: New → Confirmed
importance: Medium → Low
Meinert Jordan (m2j)
Changed in openlp:
assignee: nobody → Meinert Jordan (m2j)
Changed in openlp:
milestone: none → 1.9.8
Revision history for this message
Meinert Jordan (m2j) wrote :

Some days ago I've had a look into this. The basic problem is, that the file names in zip-files have no defined encoding.
We could use chardet, but it is not relyable for such short strings (even though wrong detection does not need to cause problems).

My approach would be to ignore the filenames and derive new filenames from the string stored in the theme XML.
This would works fine for now. As soon we want to store multiple files of the one type in the same theme it is not trivial anymore to assign the data to the generated filenames.

To be future proove we either have to restrict the filenames of additional files inside a theme or use the proposed solution only for 1.x themes while expecting filenames in 2.x themes being utf8 encoded.

Which one of these options should we prefere?

Revision history for this message
Carsten Tinggaard (catini) wrote :

I would prefer the approach to ignore the filename and derive filename from the string inside the theme XML - and restrict this way only for 1.x themes

Jon Tibble (meths)
Changed in openlp:
status: Confirmed → Fix Committed
Jon Tibble (meths)
Changed in openlp:
status: Fix Committed → Fix Released
Revision history for this message
Meinert Jordan (m2j) wrote :

The fix wouldn't work system independent

Changed in openlp:
status: Fix Released → In Progress
Tim Bentley (trb143)
Changed in openlp:
status: In Progress → Fix Released
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.