Elm install issues

127 views
Skip to first unread message

Ryan Erb

unread,
Jul 23, 2016, 4:19:21 PM7/23/16
to Elm Discuss
Trying to learn Elm, got the very basics working, but there are ton of complie errors that I am unsure about.

23 Jul 15:59:05 - error: Compiling of web/elm/elm-stuff/packages/elm-lang/core/4.0.3/src/Array.elm failed. Command failed: elm-make --yes --output ../static/vendor/array.js elm-stuff/packages/elm-lang/core/4.0.3/src/Array.elm
I cannot find module 'Native.Array'.
Module 'Array' is trying to import it.
Potential problems could be:
  * Misspelled the module name
  * Need to add a source directory or new dependency to elm-package.json
 ^G


Almost all the errors relate to 'Native.(something)'. 


Was trying to find some package named Native, but cant seem to find anything.


Am i missing some install step possibly?


Thanks,

Ryan Erb

unread,
Jul 23, 2016, 4:38:28 PM7/23/16
to Elm Discuss
Looking into more of the errors and these ones stood out:

Elm compile: elm-stuff/packages/elm-lang/core/4.0.3/src/Maybe.elm, in web/elm, to ../static/vendor/maybe.js
[debug] Live reload: priv/static/css/seatsaver.css
[debug] Live reload: priv/static/images/phoenix.png
Your dependencies form a cycle:
  ┌─────┐
  │    Maybe
  └─────┘
You may need to move some values to a new module to get rid of the cycle.

There is also one like this but with "Result",

The only packages i have install are 
"elm-lang/core": "4.0.3 <= v < 5.0.0",
"elm-lang/html": "1.1.0 <= v < 2.0.0"

Nick H

unread,
Jul 23, 2016, 5:22:34 PM7/23/16
to elm-d...@googlegroups.com
What command are you running that is giving you these errors?

Try "rm -rf elm-stuff/build-artifacts".

--
You received this message because you are subscribed to the Google Groups "Elm Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elm-discuss...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Ryan Erb

unread,
Jul 23, 2016, 5:34:26 PM7/23/16
to elm-d...@googlegroups.com

Integrating it with Phoenix, so when i start the server it tries to compile everything. Not to sure where to find the command. so I guess what ever the elm-brunch does?

Been following this tutorial.  http://www.cultivatehq.com/posts/phoenix-elm-2/

I did notice that evancz/elm-html is deprecated so i didn't install that package.

Nick H

unread,
Jul 23, 2016, 7:08:18 PM7/23/16
to elm-d...@googlegroups.com
I'm afraid I don't know anything about the elm-brunch plugin. You should be able to compile your code by doing "elm make MainModule.elm --output elm.js" (Substitute MainModule.elm and elm.js for appropriate names). Does this give you the same errors as when you are using the plugin?

Be warned, that tutorial is for an old version of Elm... the language has changed quite a bit since it was written.

--

Ryan Erb

unread,
Jul 24, 2016, 2:42:22 PM7/24/16
to Elm Discuss
It does seem like the elm-brunch is doing some weird things. Not to sure if something is now broken because of .17 now. 

Running the commands by hand seems to solve the issues. Guess I just wont have the live reloading.

Thanks for the help!!!!

Aaron VonderHaar

unread,
Jul 24, 2016, 2:49:26 PM7/24/16
to elm-d...@googlegroups.com

Is it possible elm-brunch is trying to add boilerplate to the js so it can be required by other JavaScript files?  If so, that might be messing things up.  I believe elm-make 0.17 adds the necessary boilerplate to make the output usable with require (though I haven't used that myself).


--

OvermindDL1

unread,
Jul 25, 2016, 10:10:13 AM7/25/16
to Elm Discuss
`elm-brunch` is working perfectly for me with Phoenix and brunch.  What is the log output?
Reply all
Reply to author
Forward
0 new messages