[99s-extend] Getting started error: behaviour cowboy_http_handler undefined
Loïc Hoguin
essen at ninenines.eu
Thu Mar 13 00:46:57 CET 2014
It's explained here: http://www.erlang.org/doc/man/code.html
I am not sure why it caused issues on your system, possibly Erlang
ignored it because there was an invalid folder in there. I don't really
know.
On 03/13/2014 12:43 AM, lloyd at writersglen.com wrote:
> Hi,
>
> That fixed it!
>
> But where can I go to understand why and prevent it in future?
>
> I've googled ERL_LIBS, but not found much enlightenment. Should there possibly be a note in Cowboy docs? Or is this something idiosyncratic to my system?
>
> Many thanks!
>
> Lloyd
>
> -----Original Message-----
> From: "Loïc Hoguin" <essen at ninenines.eu>
> Sent: Wednesday, March 12, 2014 6:57pm
> To: lloyd at writersglen.com
> Cc: extend at lists.ninenines.eu
> Subject: Re: [99s-extend] Getting started error: behaviour cowboy_http_handler undefined
>
> Can you try again after running "unset ERL_LIBS"?
>
> On 03/12/2014 11:51 PM, lloyd at writersglen.com wrote:
>> Hi Loïc,
>>
>> Thanks for help.
>>
>> I'm running cowboy master from GitHub and Erlang R16B02.
>>
>> $ echo $ERL_LIBS
>>
>> ...gives me a directory that no longer exists; don't know how it got there, what it should be, or how to change it.
>>
>> E.g.: /home/lloyd/Programming/Erlang/zippity/apps
>>
>> I've looked in .erlang and tried $ export ERL_LIBS=<my path to hello_erlang/ebin>.
>>
>> Thanks again,
>>
>> LRP
>>
>> -----Original Message-----
>> From: "Loïc Hoguin" <essen at ninenines.eu>
>> Sent: Monday, March 10, 2014 4:36pm
>> To: lloyd at writersglen.com, extend at lists.ninenines.eu
>> Subject: Re: [99s-extend] Getting started error: behaviour cowboy_http_handler undefined
>>
>> Try updating Erlang or Cowboy, this isn't the first time this happens
>> and I fixed something at some point.
>>
>> Also see if you have ERL_LIBS already defined, in which case there might
>> be a bug in Cowboy.
>>
>> On 03/10/2014 08:44 PM, lloyd at writersglen.com wrote:
>>> Hello,
>>>
>>> I've slavishly emulated the "Getting started" example in the guide:
>>>
>>> http://ninenines.eu/docs/en/cowboy/HEAD/guide/getting_started/
>>>
>>> But, when I compile I get this error:
>>>
>>> yada yada
>>> ERLC hello_erlang_app.erl hello_handler.erl hello_erlang_sup.erl
>>> compile: warnings being treated as errors
>>> src/hello_handler.erl:2: behaviour cowboy_http_handler undefined
>>> make: *** [ebin/hello_erlang.app] Error 1
>>>
>>> Cowboy seems to be correctly loaded and compiled as a dependency. I can see .../cowboy/ebin/cowboy_http_handler.beam
>>>
>>> However, when I remove the line -behavior(cowboy_http_handler) from hello_handler.erl, system compiles and creates release just fine.
>>>
>>> % -behavior(cowboy_http_handler).
>>>
>>> Could this be a bug in Getting started or some dunder-headed thing on my end?
>>>
>>> Thanks,
>>>
>>> LRP
>>>
>>>
>>> *********************************************
>>> My books:
>>>
>>> THE GOSPEL OF ASHES
>>> http://thegospelofashes.com
>>>
>>> Strength is not enough. Do they have the courage
>>> and the cunning? Can they survive long enough to
>>> save the lives of millions?
>>>
>>> FREEIN' PANCHO
>>> http://freeinpancho.com
>>>
>>> A community of misfits help a troubled boy find his way
>>>
>>> AYA TAKEO
>>> http://ayatakeo.com
>>>
>>> Star-crossed love, war and power in an alternative
>>> universe
>>>
>>> Available through Amazon or by request from your
>>> favorite bookstore
>>>
>>>
>>> **********************************************
>>>
>>> _______________________________________________
>>> Extend mailing list
>>> Extend at lists.ninenines.eu
>>> https://lists.ninenines.eu/listinfo/extend
>>>
>>
>
--
Loïc Hoguin
http://ninenines.eu
More information about the Extend
mailing list