elm-lang / elm-package

Command line tool to share Elm libraries
BSD 3-Clause "New" or "Revised" License
213 stars 66 forks source link

elm-make: Map.!: given key is not an element in the map #254

Closed mvvvv closed 7 years ago

mvvvv commented 7 years ago

About this message google discussion

I've kept the whole directory with this problem.

try with : elm-make http.elm elmOld.tar.gz

process-bot commented 7 years ago

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.

mvvvv commented 7 years ago

Today, a simple :

$ elm-package install elm-lang/websocket
To install elm-lang/websocket I would like to add the following
dependency to elm-package.json:

    "elm-lang/websocket": "1.0.2 <= v < 2.0.0"

May I add that to elm-package.json for you? [Y/n] Y

Some new packages are needed. Here is the upgrade plan.

  Install:
    elm-lang/websocket 1.0.2
  Upgrade:
    elm-lang/virtual-dom (2.0.1 => 2.0.2)

Do you approve of this plan? [Y/n] Y   
Starting downloads...

  ● elm-lang/websocket 1.0.2
  ● elm-lang/virtual-dom 2.0.2

Packages configured successfully!

And the bug is here again.

Ch4s3 commented 7 years ago

I had the same problem referenced in the google group happen after running elm package install elm-lang/keyboard on elm 0.18 and then running elm make on this code

jerith666 commented 7 years ago

The same issue was also reported as https://github.com/elm-lang/elm-make/issues/133.

ghost commented 7 years ago

We get this every 50 builds or so, elm 18. Usually delete elm-stuff as a work around.

evancz commented 7 years ago

I don't think there is enough here to reproduce and debug this. Is it possible to pin this down more precisely? If so, someone please open a new issue that explains how to reliably reproduce. Does OS matter? Does hand modifying elm-package.json matter? Etc.

mariustresor1 commented 7 years ago

It looks like it might be a package integrity error. Removing elm-stuff and running elm-package install again fixed my issue today.

drathier commented 7 years ago

Ran into this just now on elm 0.18.0 on osx.

  1. Working state
  2. Git pull
  3. New packages required, elm-package install --yes
  4. two new packages install
  5. elm-make: Map.!: given key is not an element in the map
  6. delete elm-stuff
  7. elm-package install --yes
  8. everything works
ivnsch commented 6 years ago

Same description as @drathier (starting at 4. - I just installed a package), also Elm 0.18 and MacOS.

s6o commented 6 years ago

osx sierra, adding a new dependency: url-parser to elm-package.json, after which

> elm-package install
Some new packages are needed. Here is the upgrade plan.

  Install:
    evancz/url-parser 2.0.1
  Upgrade:
    sporto/erl (13.0.1 => 13.0.2)
    truqu/elm-base64 (2.0.2 => 2.0.3)

Do you approve of this plan? [Y/n] Y
Starting downloads...

  ● evancz/url-parser 2.0.1
  ● truqu/elm-base64 2.0.3
  ● sporto/erl 13.0.2

Packages configured successfully!

Of the upgrade packages: elm-base64 is direct dependency listed in elm-package.json, but the erl package is not (explicitly listed).

Deleting the elm-stuff directory and re-compiling as work-around works. No luck in re-producing the issue on a smaller scale...

lukaszsamson commented 6 years ago

Happened after updating existing deps Env: osx 10.13

> elm-package install -y

Starting downloads...

  ● abadi199/dateparser 1.0.4

Packages configured successfully!

...

ERROR in ./elm/page/Main.elm
Module build failed: Error: Compiler process exited with error Compilation failed
elm-make: Map.!: given key is not an element in the map

    at ChildProcess.<anonymous> (/Users/lukaszsamson/myapp/node_modules/node-elm-compiler/index.js:141:27)
    at ChildProcess.emit (events.js:160:13)
    at maybeClose (internal/child_process.js:943:16)
    at Socket.stream.socket.on (internal/child_process.js:363:11)
    at Socket.emit (events.js:160:13)
    at Pipe._handle.close [as _onclose] (net.js:562:12)
 @ ./js/app.js 25:0-43
lbighetti commented 6 years ago

Just pinging for this has just happened to me. No idea how to reproduce, installed elm-csv and broke everything. Deleted elm-stuff and all was good again.