All,<div><br></div><div>The first issue is that the init() function isn't correct for this gen_server.</div><div><br></div><div>On line 83, the init function starts like this:</div><div>init(S) -></div><div>When it should (apparently) be like this:</div>

<div>init([S]) -></div><div><br></div><div>This doesn't make the server run though. The next error states:</div><div><br></div><div><div>6> population_monitor:start().</div><div>******** Population monitor started with parameters:{state,</div>

<div>                                                     [gt],</div><div>                                                     test,[],[],undefined,</div><div>                                                     undefined,undefined,[],0,</div>

<div>                                                     0,0,0,0,undefined,</div><div>                                                     undefined,undefined,</div><div>                                                     undefined,undefined,</div>

<div>                                                     undefined,0.5,10,10,</div><div>                                                     mathema,100,100000,inf,</div><div>                                                     undefined,false}</div>

<div>{error,{{badrecord,population},</div><div>        [{population_monitor,extract_AgentIds,2,</div><div>                             [{file,"population_monitor.erl"},{line,372}]},</div><div>         {population_monitor,init,1,</div>

<div>                             [{file,"population_monitor.erl"},{line,89}]},</div><div>         {gen_server,init_it,6,[{file,"gen_server.erl"},{line,304}]},</div><div>         {proc_lib,init_p_do_apply,3,</div>

<div>                   [{file,"proc_lib.erl"},{line,227}]}]}}</div></div><div><br></div><div>I get the feeling that there's going to be more stuff requiring fixes as you go. Perhaps the best thing its to get in touch with the author directly and find out about the state of the source base before continuing.</div>

<div><br></div><div>Cheers</div><div>OJ</div><div> </div><div><br><div class="gmail_quote">On Mon, Dec 24, 2012 at 5:49 PM, Ivan Uemlianin <span dir="ltr"><<a href="mailto:ivan@llaisdy.com" target="_blank">ivan@llaisdy.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><div><span style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px">Dear Bob</span></div>

<div><span style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px"><br></span></div><div><span style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px">This line should be part of the function population_monitor:init/1 (that's file population_monitor, function init, which takes one argument).</span><div style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px">

<br></div><div style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px">The error it complains of is {badrecord,state}, so perhaps the record S has been badly set up.</div><div style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px">

<br></div><div style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px">Are you learning erlang through neuroevolution :) ?  Do you have other reference resources?</div><div style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px">

<br></div><div style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px">Nadolig Llawen</div><div style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px"><br></div><div style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px">

Ivan</div><div style="font-family:'.Helvetica NeueUI';font-size:18px;line-height:24px"><br></div><br>--<br>festina lente<div><br></div></div><div><div class="h5"><div><br>On 24 Dec 2012, at 07:24, Bob Matthews <<a href="mailto:rgmatthews@orcon.net.nz" target="_blank">rgmatthews@orcon.net.nz</a>> wrote:<br>

<br></div><blockquote type="cite"><div>
  
    
  
  
    <div>Thank you Ivan<br>
      <br>
      line 82: Population_Id = S#state.population_id,<br>
      <br>
      Merry Xmas to you too :)<br>
      <br>
      Bob<br>
      Dunedin<br>
      New Zealand<br>
      <br>
      On 24/12/2012 8:14 p.m., Ivan Uemlianin wrote:<br>
    </div>
    <blockquote type="cite">
      
      <div>I dont have my computer with me but the error is at line 82
        of the file population_monitor.erl.</div>
      <div><br>
      </div>
      <div>Best wishes</div>
      <div><br>
      </div>
      <div>Ivan<br>
        <br>
        --<br>
        festina lente
        <div><br>
        </div>
      </div>
      <div><br>
        On 24 Dec 2012, at 01:32, Bob Matthews <<a href="mailto:rgmatthews@orcon.net.nz" target="_blank">rgmatthews@orcon.net.nz</a>>
        wrote:<br>
        <br>
      </div>
      <blockquote type="cite">
        <div>
          
          <div>The code that I am looking at is
            DXNN2 copyrighted to Gene Sher.<br>
            <br>
            The error message I got which I am having difficulty
            interpreting is as follows....................<br>
            <br>
            4> population_monitor:start().<br>
            {error,{{badrecord,state},<br>
                    [{population_monitor,init,1,<br>
                                        
            [{file,"population_monitor.erl"},{line,82}]},<br>
                    
            {gen_server,init_it,6,[{file,"gen_server.erl"},{line,304}]},<br>
                     {proc_lib,init_p_do_apply,3,<br>
                               [{file,"proc_lib.erl"},{line,227}]}]}}<br>
            <br>
            I am using the latest versionR15B03<br>
            <br>
            Thank you for you help<br>
            <br>
            Bob<br>
            Dunedin New Zealand<br>
            <br>
            On 24/12/2012 11:58 a.m., Matti Oinas wrote:<br>
          </div>
          <blockquote type="cite">
            
            <div>Hi,<br>
              <br>
              My first proposal is to change the editor to something
              more usable like emacs or if you prefer something
              different then notepad++, sublime text or eclipse +
              erlIDE. Everyone of these are able to show you the line
              numbers and offer syntax highlight features.<br>
              <br>
              It would help a lot if you tell us which code you are
              looking at. Server callbacks probably mean gen_server
              callbacks so it doesn't matter if you are using windows or
              linux.<br>
              <br>
              Matti<br>
              <br>
              On 12/24/2012 12:08 AM, Bob Matthews wrote:<br>
            </div>
            <blockquote type="cite">
              
              Hi<br>
              <br>
              I have just started to learn Erlang............<br>
              I am using Windows 7 on a PC<br>
              <br>
              <small><small><b><big><big>Question 1</big></big></b></small></small>) 



              when I get an error message, what is the easiest way for
              me to find the exact line number?<br>
              I use ms Word as an editor.<br>
              <br>
              <b>Question 2</b>) the code I am looking at was run on
              Unix, on a server. <br>
              Part of the code talks about server call-backs etc.<br>
              It is unclear how I translate that to a windows PC<br>
              <br>
              Many thanks<br>
              <br>
              Bob<br>
              <br>
              <fieldset></fieldset>
              <br>
              <pre>_______________________________________________
erlang-questions mailing list
<a href="mailto:erlang-questions@erlang.org" target="_blank">erlang-questions@erlang.org</a>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a>
</pre>
            </blockquote>
            <br>
            <p color="#000000" align="left">No
              virus found in this message.<br>
              Checked by AVG - <a href="http://www.avg.com" target="_blank">www.avg.com</a><br>
              Version: 2013.0.2805 / Virus Database: 2634/5951 - Release
              Date: 12/11/12<br>
              Internal Virus Database is out of date.</p>
          </blockquote>
          <br>
        </div>
      </blockquote>
      <blockquote type="cite">
        <div><span>_______________________________________________</span><br>
          <span>erlang-questions mailing list</span><br>
          <span><a href="mailto:erlang-questions@erlang.org" target="_blank">erlang-questions@erlang.org</a></span><br>
          <span><a href="http://erlang.org/mailman/listinfo/erlang-questions" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a></span><br>
        </div>
      </blockquote>
      <p color="#000000" align="left">No virus
        found in this message.<br>
        Checked by AVG - <a href="http://www.avg.com" target="_blank">www.avg.com</a><br>
        Version: 2013.0.2805 / Virus Database: 2634/5951 - Release Date:
        12/11/12<br>
        Internal Virus Database is out of date.</p>
    </blockquote>
    <br>
  

</div></blockquote></div></div></div><br>_______________________________________________<br>
erlang-questions mailing list<br>
<a href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a><br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><br>OJ Reeves<div>+61 431 952 586<br><a href="http://buffered.io/" target="_blank">http://buffered.io/</a></div>
</div>