Yoni
2014-10-01 21:28:31 UTC
Hi LyX developers,
I've encountered this bug in LyX 2.0.6 (on Windows 8.1), and it still
exists as of LyX 2.1.2.
After playing around with macros a little bit, I noticed that sometimes I
would rename a macro (i.e. from \mymacro to \myothermacro) and rebuild the
pdf, I would not get errors about \mymacro being unrecognized. (The control
is simply ignored.) I would get the error in a new document but not in the
document I was working on.
After trying to place invalid control sequences in several places in the
file I noticed that if I put it in the beginning of the document, these
errors are raised, but in the ending, they don't get raised. By doing a
"binary search" I pinpointed an exact point after which these errors are
suppressed.
I don't understand the conditions that ensure this, but I managed to create
a small example that reproduces it:
LyX 2.1.2 on Windows 8.1 default install, default document settings, create
a new document and write two lines:
The first line has "blah blah blah blah blah blah blah blah blah blah"
(must be exactly 10 blahs) and then the
formula $B^{d+1}\left(0,\frac{r}{\sqrt{d}}\right)\subset\left[-\frac{r}{\sqrt{d}},\frac{r}{\sqrt{d}}\right]^{d+1}$
In the second line, just put an invalid control sequence like "\blah".
At least on my computer, compiling this won't raise an error. If you remove
one of the blahs or change the formula too much, you'll get the error again
though. I think part of the contributing factors for the bug is that the
formula appears on the far right side of the line.
I am attaching a file that has the above contents.
Yoni
I've encountered this bug in LyX 2.0.6 (on Windows 8.1), and it still
exists as of LyX 2.1.2.
After playing around with macros a little bit, I noticed that sometimes I
would rename a macro (i.e. from \mymacro to \myothermacro) and rebuild the
pdf, I would not get errors about \mymacro being unrecognized. (The control
is simply ignored.) I would get the error in a new document but not in the
document I was working on.
After trying to place invalid control sequences in several places in the
file I noticed that if I put it in the beginning of the document, these
errors are raised, but in the ending, they don't get raised. By doing a
"binary search" I pinpointed an exact point after which these errors are
suppressed.
I don't understand the conditions that ensure this, but I managed to create
a small example that reproduces it:
LyX 2.1.2 on Windows 8.1 default install, default document settings, create
a new document and write two lines:
The first line has "blah blah blah blah blah blah blah blah blah blah"
(must be exactly 10 blahs) and then the
formula $B^{d+1}\left(0,\frac{r}{\sqrt{d}}\right)\subset\left[-\frac{r}{\sqrt{d}},\frac{r}{\sqrt{d}}\right]^{d+1}$
In the second line, just put an invalid control sequence like "\blah".
At least on my computer, compiling this won't raise an error. If you remove
one of the blahs or change the formula too much, you'll get the error again
though. I think part of the contributing factors for the bug is that the
formula appears on the far right side of the line.
I am attaching a file that has the above contents.
Yoni