Project

General

Profile

Actions

Bug #107

closed

Feature #44: Request for inclusion: Songwrite2

Songwrite2 crashes on untranslated PO files

Added by Jean-Michel Philippe almost 13 years ago. Updated almost 13 years ago.

Status:
Closed
Priority:
Urgent
Category:
Development
Start date:
05/07/2011
Due date:
05/23/2011
% Done:

100%

Estimated time:
2:00 h
Spent time:

Description

Currently only English and French are available in Songwrite. Launching it in the Spanish console says:

$ songwrite2 
Traceback (most recent call last):
  File "/usr/bin/songwrite2", line 31, in <module>
    import songwrite2.model as model
  File "/usr/share/songwrite2/model.py", line 779, in <module>
    DRUM_PATCHES = dict([(int(i), patch) for (i, patch) in DRUM_PATCHES])
ValueError: need more than 1 value to unpack

This is likely due to the fact that the Drum instrument table is a PO message and is empty in the Spanish PO file. If we remove the MO file from locale/ (language not in SVN/Transifex), we get:

$ sudo rm /usr/share/locale/es/LC_MESSAGES/songwrite2.mo
$ songwrite2 
Traceback (most recent call last):
  File "/usr/bin/songwrite2", line 30, in <module>
    import songwrite2.globdef
  File "/usr/share/songwrite2/globdef.py", line 40, in <module>
    translator = gettext.translation("songwrite2", LOCALEDIR, ("en",))
  File "/usr/lib/python2.5/gettext.py", line 469, in translation
    raise IOError(ENOENT, 'No translation file found for domain', domain)
IOError: [Errno 2] No translation file found for domain: 'songwrite2'

It seems it's now looking for the English MO file but it is missing since we're purging locales:

$ ls /usr/share/locale/en/
LC_MESSAGES

Related issues 1 (0 open1 closed)

Related to New applications - Task #137: Generate original Songwrite PO files at CD buildClosedJean-Michel Philippe08/01/201108/22/2011

Actions
Actions

Also available in: Atom PDF