Comment 16 for bug 1663697

Revision history for this message
su_v (suv-lp) wrote :

Another update:
* The crash of core inkscape is now tracked in bug #1666314.

* A workaround to prevent the known trigger of the crash is described by Alvin in bug #1662531:
https://bugs.launchpad.net/inkscape/+bug/1662531/comments/69

* The question why LANG is set at all in inkex.localize() on Windows is still open (bug #1666108):
https://bugs.launchpad.net/inkscape/+bug/1666108/comments/1

* Proposed changes for inkex.py:
Unless LANG is needed for translations of messages returned by extension scripts, a solution to prevent the crash on Windows of inkscape (trunk) instances with GUI spawned via Popen() from extension scripts could be to remove line 57 in share/extensions/inkex.py (or to comment the line out, as in attached proposed diff).

* Explanation:
AFAICT default environments on Windows do not define %LANG%. If the variable is defined nevertheless to anything other than C or POSIX, then the initial instance already crashes on launch (bug #1666314). There is no reason to forcefully unset LANG on Windows in inkex.localize() because if it is set, affected inkscape builds (currently only trunk) already crash before any extension can be run.

Whether or not, and if to what extent, the environment variables LANG and LC_ALL of the parent process on Windows have an effect on inkscape for localization IMHO needs to be addressed in Inkscape core first: currently, these environment variables do affect at least the UI language (and possibly other aspects of localization like the character used for the decimal point) of the main application, even if rarely used on Windows.