Opened 16 years ago

Last modified 16 years ago

#1980 closed defect

Assert Error

Reported by: drpython Owned by: robind
Priority: normal Milestone:
Component: wxStyledText Version:
Keywords: Cc: drpython, robind
Blocked By: Blocking:
Patch: no


This seems to be fatal on Windows (and merely a supreme
annoyance on linux).

'Assertion [line < pdoc->LinesTotal()] failed at
../../src/stc\scintilla\src\Editor.cxx 1825 '

This happens.

On windows, it happens when "I open an interpreter from
the program menu. I shrink its size down all the way so
it isn't invisible. I end the interpreter from the
program menu. I open another interpreter from the
program menu, and it crashes. "
(this is in my editor, drpython).

Basically, I have an stc which uses AddText to add
output from a piped python process. The problem occurs
when the stc is not visible, then made visible,
cleared, and a new process opened.

You can reproduce this error by running drpython:
Click the Python Icon. This will open an intepreter.
Then hide the prompt (drag it to the bottom, or hit F6,
or use the menu). Then run python again. Viola! Error.

Now it gets better. If I use .ClearAll() or
SetText(), it still crashes. If I move the clear
statement around in the runcommand function (which
actually sets up the wx.Execute code, etc) it doesn't
change it. If I don't clear the text (I remove that
one line), or I use SetText('\n'), and set the stc text
to one line or more, everything is fine.

What on Earth is going on? How can I work around this?
This looks like a nasty internal stc bug. Is it?


Change History (3)

comment:1 Changed 16 years ago by robind

Which version?

Can you duplicate this in a simpler example, or perhaps by
modifying the demo?

comment:2 Changed 16 years ago by drpython (on both Linux (GTK Port) and Windows XP).
Running Python 2.2 on the windows box, 2.3 on the linux box.

I will fiddle with the demo to try to duplicate this, or at
least post a single simple file that replicates the problem.

comment:3 Changed 16 years ago by drpython

Oh how embarressing.

Basically I could not repduce this by adding sizers to the
Process tab in the demo. So I went into the drpython code,
convinced it was something to do with scrolling. It wasn't.

I seem to have inadvertnantly fixed the problem, and I am

not certain what it was I fixed. As such, I would not worry
about this. I very much doubt it will pop up again as an
error in any other situation.


Note: See TracTickets for help on using tickets.