I'm using ex_doc in the :dev environment at my tiny Elixir package.
mix.exs:
defp deps do
[
{:ex_doc, "~> 0.19.1", only: :dev},
{:junit_formatter, "~> 3.0", only: :test},
{:excoveralls, "~> 0.10", only: :test}
]
end
I can successfully pull down the dependencies and run tests:
❯❯❯ mix deps.get
Resolving Hex dependencies...
Dependency resolution completed:
Unchanged:
certifi 2.4.2
earmark 1.3.0
ex_doc 0.19.1
excoveralls 0.10.3
hackney 1.14.3
idna 6.0.0
jason 1.1.2
junit_formatter 3.0.0
makeup 0.5.5
makeup_elixir 0.10.0
metrics 1.0.1
mimerl 1.0.2
nimble_parsec 0.5.0
parse_trans 3.3.0
ssl_verify_fun 1.1.4
unicode_util_compat 0.4.1
All dependencies up to date
❯❯❯ mix test
Compiling 1 file (.ex)
..
Finished in 0.04 seconds
1 doctest, 1 test, 0 failures
Randomized with seed 956225
Wrote JUnit report to: /tmp/junit.xml
All good so far, but I'm getting an exception while running mix docs:
mix docs
==> makeup
Compiling 43 files (.ex)
== Compilation error in file lib/makeup/lexer/combinators.ex ==
** (CompileError) lib/makeup/lexer/combinators.ex:116: undefined function repeat_until/2
(stdlib) lists.erl:1338: :lists.foreach/2
(stdlib) erl_eval.erl:680: :erl_eval.do_apply/6
could not compile dependency :makeup, "mix compile" failed. You can recompile this dependency with "mix deps.compile makeup", update it with "mix deps.update makeup" or clean it with "mix deps.clean makeup"
Erlang/OTP 21 [erts-10.1.3] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1] [hipe] [dtrace]
Elixir 1.7.4 (compiled with Erlang/OTP 21)
nimble_parsec was just released with v0.5.0 that removed repeat_until in favour of lookahead_not (https://github.com/plataformatec/nimble_parsec/commit/46d7337768487f937162f06874cc7ae69a034a96).
You can work around this issue by pinning: {:nimble_parsec, "~> 0.4.0", only: :dev} (you might need override: true too), while we wait until makeup is updated and/or we pin the version too.
@josevalim @tmbb perhaps makeup should embed nimble_parsec without depending on it to avoid issues like that, e.g. by using https://hexdocs.pm/nimble_parsec/Mix.Tasks.NimbleParsec.Compile.html :)
@wojtekmach i don't think that's possible for makeup because it provides a collection of helpers on top of nimble_parsec and the each language makeup itself relies on NimbleParsec as well.
I have opened an issue here: https://github.com/tmbb/makeup/pull/18
oh, fair enough, I admit I haven't looked into makeup internals yet.
It's basically what @josevalim said. I'll publish a new version compatible with nimble_parsec 0.5 as soon as possible.
You can work around this issue by pinning: {:nimble_parsec, "~> 0.4.0", only: :dev} (you might need override: true too), while we wait until makeup is updated and/or we pin the version too.
Yes, that works. Thanks @wojtekmach
There's a new version of makeup that fixes the issue so the workaround is no longer needed!
Most helpful comment
There's a new version of makeup that fixes the issue so the workaround is no longer needed!