These are chat archives for synrc/n2o

6th
Jan 2016
heiheshang
@heiheshang
Jan 06 2016 01:33
Пропустил видать
heiheshang
@heiheshang
Jan 06 2016 07:07
@5HT единственное не пойму как отловить, что передача закончилась ?
heiheshang
@heiheshang
Jan 06 2016 08:39
@5HT все заработало
heiheshang
@heiheshang
Jan 06 2016 08:49
беда у меня какая-то с mad приключилась, куда копать ?
escript: exception error: no match of right hand side value 
                 {error,
                     {'EXIT',
                         {badarg,
                             [{erlang,iolist_size,
                                  [[97,112,112,115,47,114,101,118,105,101,119,
                                    47,112,114,105,118,47,115,116,97,116,105,
                                    99,47,100,102,57,53,97,99,101,56,101,53,
                                    53,56,101,101|...]],
                                  []},
                              {zip,binary_io,2,[{file,"zip.erl"},{line,1735}]},
                              {zip,put_z_files,6,
                                  [{file,"zip.erl"},{line,860}]},
                              {zip,do_zip,3,[{file,"zip.erl"},{line,462}]},
                              {zip,zip,3,[{file,"zip.erl"},{line,452}]},
                              {mad_escript,static,0,
                                  [{file,
                                       "/home/brashik/deps/mad/src/package/mad_escript.erl"},
                                   {line,19}]},
                              {mad_escript,main,1,
                                  [{file,
                                       "/home/brashik/deps/mad/src/package/mad_escript.erl"},
                                   {line,9}]},
                              {mad,'-main/1-fun-3-',3,
                                  [{file,
                                       "/Users/5HT/depot/synrc/mad/src/mad.erl"},
                                   {line,19}]},
                              {lists,foldl,3,[{file,"lists.erl"},{line,1262}]},
                              {mad,main,1,
                                  [{file,
                                       "/Users/5HT/depot/synrc/mad/src/mad.erl"},
                                   {line,18}]},
                              {escript,run,2,
                                  [{file,"escript.erl"},{line,757}]},
                              {escript,start,1,
                                  [{file,"escript.erl"},{line,277}]},
                              {init,start_it,1,[]},
                              {init,start_em,1,[]}]}}}
  in function  mad_escript:static/0 (/home/brashik/deps/mad/src/package/mad_escript.erl, line 19)
  in call from mad_escript:main/1 (/home/brashik/deps/mad/src/package/mad_escript.erl, line 9)
  in call from mad:'-main/1-fun-3-'/3 (/Users/5HT/depot/synrc/mad/src/mad.erl, line 19)
  in call from lists:foldl/3 (lists.erl, line 1262)
  in call from mad:main/1 (/Users/5HT/depot/synrc/mad/src/mad.erl, line 18)
  in call from escript:run/2 (escript.erl, line 757)
  in call from escript:start/1 (escript.erl, line 277)
  in call from init:start_it/1 
  in call from init:start_em/1
Ram Kumar
@ramka001
Jan 06 2016 13:03
hi @5HT is it possible to produce a wf:wire(#alert{text="Already Registered"}) message when the {error,exists} message is returned?
1> kvs:add(#user{id="maxim@synrc.com"}).
{error,exist}
Namdak Tonpa
@5HT
Jan 06 2016 13:32
case kvs:add(#user{id="maxim@synrc.com"}) of
          {error,exist} -> wf:wire(#alert{text="Already Registered"});
          _ -> skip end
@heiheshang перед тем как копать и репортить ошибку
сначала нужно написать как ты ее воспроизводишь
heiheshang
@heiheshang
Jan 06 2016 13:47
./mad deps compile plan repl
Namdak Tonpa
@5HT
Jan 06 2016 13:48
ну простой ответ такой: не воспроизводится
Ram Kumar
@ramka001
Jan 06 2016 13:48
thanx @5HT I was trying this today
heiheshang
@heiheshang
Jan 06 2016 13:49
я его сломал
Egor
@madmake
Jan 06 2016 14:00
Кстати никому не прилетало что то подобное
=ERROR REPORT==== 5-Jan-2016::03:53:50 ===
Error in process <0.5047.0> with exit value:
{[{reason,function_clause},
  {mfa,{n2o_cowboy,handle,2}},
  {stacktrace,
      [{cow_qs,unhex,"\"",
           [{file,"/usr/home/stallion/www/matbet2/deps/cowlib/src/cow_qs.erl"},
            {line,345}]},
       {cow_qs,parse_qs_value,4,
           [{file,"/usr/home/stallion/www/matbet2/deps/cowlib/src/cow_qs.erl"},
            {line,55}]},
       {cowboy_req,qs_vals,1,
           [{file,
                "/usr/home/stallion/www/matbet2/deps/cowboy/src/cowboy_req.erl"},
            {line,255}]},
       {n2o_query,init,2,
           [{file,
                "/usr/home/stallion/www/matbet2/deps/n2o/src/handlers/n2o_query.erl"},
            {line,7}]},
       {n2o_cx,'-fold/3-fun-0-',3,
           [{file,"/usr/home/stallion/www/matbet2/deps/n2o/src/n2o_cx.erl"},
            {line,32}]},
       {lists,foldl,3,[{file,"lists.erl"},{line,1262}]},
       {n2o_document,run,1,
           [{file,
                "/usr/home/stallion/www/matbet2/deps/n2o/src/endpoints/n2o_document.erl"},
            {line,14}]},
       {n2o_cowboy,handle,2,
           [{file,
                "/usr/home/stallion/www/matbet2/deps/n2o/src/endpoints/cowboy/n2o_cowboy.erl"},
            {line,14}]},
       {cowboy_handler,handler_handle,4,
           [{file,
                "/usr/home/stallion/www/matbet2/deps/cowboy/src/cowboy_handler.erl"},
            {line,111}]},
       {cowboy_protocol,execute,4,
           [{file,
                "/usr/home/stallion/www/matbet2/deps/cowboy/src/cowboy_protocol.erl"},
            {line,442}]}]},
  {req,
      [{socket,#Port<0.147753>},
       {transport,ranch_tcp},
       {connection,close},
       {pid,<0.5047.0>},
       {method,<<"GET">>},
       {version,'HTTP/1.0'},
       {peer,{{127,0,0,1},42213}},
       {host,<<"127.0.0.1">>},
       {host_info,undefined},
       {port,8000},
       {path,<<"/server-status">>},
       {path_info,undefined},
       {qs,<<"HTTP_POST=%\"%6346">>},
       {qs_vals,undefined},
       {bindings,[]},
       {headers,
           [{<<"host">>,<<"127.0.0.1:8000">>},
            {<<"connection">>,<<"close">>},
            {<<"user-agent">>,<<"apache 0day by @hxmonsegur">>},
            {<<"accept">>,<<"*/*">>}]},
       {p_headers,[{<<"connection">>,[<<"close">>]}]},
       {cookies,undefined},
       {meta,[]},
       {body_state,waiting},
       {buffer,<<>>},
       {multipart,undefined},
       {resp_compress,false},
       {resp_state,waiting},
       {resp_headers,[]},
       {resp_body,<<>>},
       {onresponse,undefined}]},
  {state,{state,undefined,undefined}}],
 [{cowboy_protocol,execute,4,
      [{file,
           "/usr/home/stallion/www/matbet2/deps/cowboy/src/cowboy_protocol.erl"},
       {line,442}]}]}
185.130.5.224 - - [05/Jan/2016:03:53:51 +0300] "GET /server-status?HTTP_POST=%\x22%6346#%#/&#736%\x22#423|;&HTTP_CGI_GET=GRESYYK\x22K&J\x22#L523D2G23H23 HTTP/1.0" 500 0 "-" "apache 0day by @hxmonsegur"
Namdak Tonpa
@5HT
Jan 06 2016 14:02
написано же что ошибка в ковбое
@heiheshang я закомитил новый mad можешь сделать git pull и проверить
если не поможет то скорее вего проблема на твоей стороне