elm / compiler

Compiler for Elm, a functional language for reliable webapps.
https://elm-lang.org/
BSD 3-Clause "New" or "Revised" License
7.55k stars 662 forks source link

Problem building dependencies after installing abinayasudhir/html-parser #2043

Open MartinSStewart opened 4 years ago

MartinSStewart commented 4 years ago

Problem building dependencies: Installing abinayasudhir/html-parser 1.0.1 causes the compiler to produce the following error when running elm make src/Main.elm:


./src/Main.elm
Error: Compiler process exited with error Compilation failed
Starting downloads...

  ● abinayasudhir/html-parser 1.0.1

Verifying dependencies (24/24)-- PROBLEM BUILDING DEPENDENCIES -----------------------------------------------

I ran into a compilation error when trying to build the following package:

    abinayasudhir/html-parser 1.0.1

This probably means it has package constraints that are too wide. It may be
possible to tweak your elm.json to avoid the root problem as a stopgap. Head
over to https://elm-lang.org/community to get help figuring out how to take this
path!

Note: To help with the root problem, please report this to the package author
along with the following information:

    elm/core 1.0.4
    elm/html 1.0.0
    elm/parser 1.1.0
    elm/virtual-dom 1.0.2
    rtfeldman/elm-hex 1.0.0

If you want to help out even more, try building the package locally. That should
give you much more specific information about why this package is failing to
build, which will in turn make it easier for the package author to fix it!

Dependency problem!           
 @ ./src/index.js 2:0-33 5:13-16
 @ multi ./node_modules/create-elm-app/config/polyfills.js ./node_modules/create-elm-app/scripts/utils/webpackHotDevClient.js ./node_modules/react-error-overlay/lib/index.js ./src/index.js

however, abinayasudhir/html-parser 1.0.0, which has the exact same dependencies, does not produce any errors.

SSCCE

Here is the SSCCE which contains a project using abinayasudhir/html-parser 1.0.1 and abinayasudhir/html-parser 1.0.0. Note that if you run elm make src/Main.elm on 1.0.1 you'll get a compiler error but if you do the same thing for 1.0.0 it will compile.

MartinSStewart commented 4 years ago

It looks like the cause of this is that the author added a call to some native code in one of the commits https://github.com/abinayasudhir/html-parser/commit/f34fbbceaf9a8469d3f9447270dd2de2e345b3da