[erlang-questions] trouble debugging app in erlide

Daniel Goertzen <>
Thu Jan 27 20:20:14 CET 2011


I setup the startup function as you suggest but it has to directly invoke my
application start function to get debug capability; when I use
application:start(myapp) I don't get debugging.

My application callback module looks like this:


-module(myapp_app).
-behavior(application).
-export([start/2, stop/1]).
-export([start/0]).

start() -> start(normal,[]).      % invoked by erlide debug configuration
%% start() -> application:start(myapp). %no good for debugging!

start(normal, _Args) ->
  ... regular application startup



Good enough for me; thank you again for your help.
Dan.


On Thu, Jan 27, 2011 at 10:33 AM, Vlad Dumitrescu <>wrote:

> Hi!
>
> On Thu, Jan 27, 2011 at 16:36, Daniel Goertzen <>wrote:
>
>> I am using erlide, and I cannot get breakpoints to work on my app when the
>> app is started automatically by my boot script.
>>
>> If I use the console to application:stop()/start() my app, breakpoints
>> start
>> working normally.  But I am intensely lazy and want breakpoints to work
>> right when I launch my Debug Config.
>>
>> Any advice?
>>
>
> I think that the problem is that the application gets started before the
> debugger, thus before the breakpoints are set and the code is interpreted. I
> don't think we can do much about that, short of adding the erlide debugger
> application to the boot script, but that would require large changes to our
> framework.
>
> A suggestion would be to create a parameterless function that starts your
> application and does any other initialization, and specify it as startup
> function in the debug configuration.
>
> regards,
> Vlad
>
>


More information about the erlang-questions mailing list