evancz/elm-architecture-tutorial

Random example fails to import Random module

jlleblanc opened this issue · 3 comments

After attempting to code along with the tutorial, I ran into the following error when trying to import the Random module:

I found multiple modules named 'Random'.

Module 'Main' is trying to import it.

Modules with that name were found in the following locations:

    directory ././Random.elm
    package elm-lang/core

After running into this issue with the code I typed while following along, I tried cutting and pasting https://raw.githubusercontent.com/evancz/elm-architecture-tutorial/master/examples/04-random.elm in its place. The same error occurs.

  • OS: MacOS 10.11.6
  • Browser: Chrome Version 59.0.3071.115 (Official Build) (64-bit)
  • Elm version: 0.18.0

Thanks for the issue! Make sure it satisfies this checklist. My human colleagues will appreciate it!

Here is what to expect next, and if anyone wants to comment, keep these things in mind.

The problem is that you've named your Elm file "Random" too—change it to something else and the import should work fine. I've run into this a couple times myself.

@joshforisha That was it, THANK YOU!!!