Re: [code] [textadept] freezes while running a script.

From: Mitchell <>
Date: Sun, 19 Aug 2012 20:57:12 -0400 (EDT)


On Sun, 19 Aug 2012, Jason wrote:

> Hi,
> I'm having trouble with Textadept freezing while executing a script.
> If I either run a long loop, or wait on things like sockets in the script,
> the entire Textadept UI will freeze.
> Since I'm trying to modernize the outdated Textadept debugger[1] to use a
> remote debugger this proves problematic, so I'd like to request that a
> feature
> be added that allows for `modules/textadept/run.lua` to run a command
> without
> having all of Textadept waiting for it to finish. It seems to me that
> this is a very
> common feature among editors/IDEs, so I hope Textadept will soon follow
> suit.

I worked on this some time ago using GTK's "spawn" facilities but it was
problematic on Windows so I decided against including it.

Obviously Textadept is a single-threaded application. Lua states accessed
from multiple threads can mis-behave and cause problems so I am reluctant
to support it.

> I have though about implementing this with LuaLanes to create a new
> thread, but this is
> probably far too bulky of a solution to make it into an actual Textadept
> release.
> So, thoughts about this?

I am open to patches and suggestions, but am unlikely to look into it
myself unless I have a good amount of time.

> [1]

When I get some time I need to really spend some time looking into fixing
the debugger for Lua 5.2. A quick analysis showed that functions cannot
yield from inside a debug hook (at least that is what I think I recall).
Perhaps there is another way without resorting to the client-server model.


You are subscribed to
To change subscription settings, send an e-mail to
To unsubscribe, send an e-mail to
Received on Sun 19 Aug 2012 - 20:57:12 EDT

This archive was generated by hypermail 2.2.0 : Mon 20 Aug 2012 - 06:50:12 EDT