On 03/06/2011 2:11 PM, Michal wrote:
On Fri, 03 Jun 2011 13:02:25 -0400
Julien Rioux<jri...@physics.utoronto.ca> wrote:
[...]
I didn't follow the thread but I am just wondering about your
suggested user hint. Do you suggest that such a message should appear
in a popup window when configure.py fails, or that it should appear
as a warning in the documentation somewhere?
It seems that LyX infrastructure isn't quite ready to deliver
messages from configure.py, but I gave at least one good reason to
prepare something - otherwise, while configure.py is sometimes forced to
fail, it will be invisible to the user, unless he/she is skilled enough
to dig deep inside LyX's logs.
AFAIU, the most simplistic approach would be for configure.py to
pop-up a message window with all warning-level log messages at the end
if at least one appeared. It should be optional though, otherwise
non-interactive variants of installers (think Debian package manager)
would have trouble of executing configure.py automatically. For Windows
installers (which are interactive) and especially for Tools ->
Reconfigure this pop-up is a must IMHO, but for other uses it should
stay off by default.
Then such a message(s) could be simply inccorporated into
configure.py. All the other approaches would probably require more
complicated tweaking.
I've just checked, and I don't have any warnings in my
configure.log, so it seems that it's a rare enough event to warrant such
a pop-up.
It's just an idea though - I don't know LyX internals well enough
to be sure.
Regards,
MichaĆ
OK, so you do suggest a sort of error reporting popup window. I just
wanted to make sure I got your suggestion right.
As for the implementation of such a report, no doubt that there are
problems there. I think a general solution is in order. I wouldn't put
the popup window itself in the python script. Rather I would have
specific exit statuses for configure.py.
On the LyX side, a failing exit status should be reported and popup the
corresponding error message for known cases. This is more general than
just the configure.py script. Reporting errors from external scripts is
a long standing request. There's also a ticket for that on the bug
tracker at http://www.lyx.org/trac/ticket/6826
I would also make the log file available in the popup, perhaps hidden by
default but toggleable with a button, and suggest the users to
copy-paste the log to the user list and ask for answers if they can't
find a solution themselves.
--
Julien