-
-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
msgfmt corrupts non-translatable fields in pattern files #70
Comments
After the error I can't close the Gaupol window and I need to kill the process. Note that Fedora 24 is an old, unsupported version. |
I saw this too, it's related to switching from intltool to gettext. After running Edit: That allows you to run locally, but the installed pattern files seem broken by |
It works fine for me now, thanks. |
Spanish translator here.
First, note that I can't trigger the crash running gaupol directly in English without a local data install.
It doesn't happen with Gaupol 1.2
Steps:
Clone Gaupol 1.3 from repo.
Install in a temporary location:
python3 setup.py clean
mkdir -p locale/es/LC_MESSAGES
msgfmt -cv --check-accelerators=_ po/es.po -o locale/es/LC_MESSAGES/gaupol.mo
python3 setup.py install_data -d /tmp/gaupol
Here I deleted ~/.config/gaupol, to discard something attached to my specific config.
Run gaupol, create a empty subtitle file, run "Correct Text..."
Pick only the "Corregir errores frecuentes" task. Next.
Select the "Otro" script, and the "Errores humanos" type of errors. Between the 3 errors listed, pick only "Espacios iniciales y finales". Next.
Here I got the "Something is wrong" window, with the next traceback:
File: censored/gaupol/gaupol/util.py
Line: 44
In: call_function
function(*args, **kwargs)
File: censored/gaupol/gaupol/assistants.py
Line: 1033
In: _correct_texts
page.correct_texts(dummy, rows, doc)
File: censored/gaupol/gaupol/assistants.py
Line: 462
In: correct_texts
project.correct_common_errors(indices, doc, patterns)
File: censored/gaupol/aeidon/deco.py
Line: 189
In: wrapper
value = function(*args, **kwargs)
File: censored/gaupol/aeidon/agents/text.py
Line: 174
In: correct_common_errors
parser.set_regex(string, flags)
File: censored/gaupol/aeidon/finder.py
Line: 182
In: set_regex
self.pattern = re.compile(pattern, flags)
File: /usr/lib/python3.5/re.py
Line: 224
In: compile
return _compile(pattern, flags)
File: /usr/lib/python3.5/re.py
Line: 293
In: _compile
p = sre_compile.compile(pattern, flags)
File: /usr/lib/python3.5/sre_compile.py
Line: 536
In: compile
p = sre_parse.parse(p, flags)
File: /usr/lib/python3.5/sre_parse.py
Line: 829
In: parse
p = _parse_sub(source, pattern, 0)
File: /usr/lib/python3.5/sre_parse.py
Line: 437
In: _parse_sub
itemsappend(_parse(source, state))
File: /usr/lib/python3.5/sre_parse.py
Line: 638
In: _parse
source.tell() - here + len(this))
sre_constants.error: nothing to repeat at position 0
Environment
Platform: Linux-4.11.12-100.fc24.i686+PAE-i686-with-fedora-24-Twenty_Four
Locale: es_ES.utf_8
Versions
aeidon: 1.3
chardet: 2.2.1
enchant: 1.6.8
gaupol: 1.3
gstreamer: 1.8.3.0
gtk+: 3.20.10
pygobject: 3.20.1
python: 3.5.3
The text was updated successfully, but these errors were encountered: