Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

crash on 1.0.0-rc 7 #365

Open
2 tasks done
paulswartz opened this issue Oct 1, 2019 · 7 comments
Open
2 tasks done

crash on 1.0.0-rc 7 #365

paulswartz opened this issue Oct 1, 2019 · 7 comments
Milestone

Comments

@paulswartz
Copy link

Precheck

  • Take a look at the open issues and be sure that your issue is not already covered.
  • Be sure your versions of Dialyxir and Erlex are up to date.

Environment

  • Elixir & Erlang/OTP versions (elixir --version):
Erlang/OTP 21 [erts-10.3.5.4] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1] [hipe]
Elixir 1.9.1 (compiled with Erlang/OTP 21)
  • Which version of Dialyxir are you using? (cat mix.lock | grep dialyxir):
  "dialyxir": {:hex, :dialyxir, "1.0.0-rc.7", "6287f8f2cb45df8584317a4be1075b8c9b8a69de8eeb82b4d9e6c761cf2664cd", [:mix], [{:erlex, ">= 0.2.5", [hex: :erlex, repo: "hexpm", optional: false]}], "hexpm"}

Current behavior

I get a crash running mix dialyzer after updating to RC7.

Finding suitable PLTs
Checking PLT...
[:asn1, :bunt, :compiler, :cowboy, :cowlib, :credo, :crypto, :dialyxir, :eex, :elixir, :erlex, :jason, :kernel, :logger, :logster, :mime, :phoenix,
 :phoenix_pubsub, :plug, :plug_cowboy, :plug_crypto, :public_key, :ranch, :runtime_tools, :snmp, :ssh, :ssl, :stdlib, :telemetry]
Looking up modules in dialyxir_erlang-21.3.8.5_elixir-1.9.1_deps-dev.plt
Finding applications for dialyxir_erlang-21.3.8.5_elixir-1.9.1_deps-dev.plt
Finding modules for dialyxir_erlang-21.3.8.5_elixir-1.9.1_deps-dev.plt
Removing 1 modules from dialyxir_erlang-21.3.8.5_elixir-1.9.1_deps-dev.pltChecking 1193 modules in dialyxir_erlang-21.3.8.5_elixir-1.9.1_deps-dev.plt
Adding 3 modules to dialyxir_erlang-21.3.8.5_elixir-1.9.1_deps-dev.plt
done in 0m4.94s
No :ignore_warnings opt specified in mix.exs and default does not exist.

** (UndefinedFunctionError) function Dialyxir.Project.dialyzer_paths/0 is undefined or private. Did you mean one of:

      * dialyzer_files/0
      * dialyzer_flags/0

    Dialyxir.Project.dialyzer_paths()
    lib/mix/tasks/dialyzer.ex:255: Mix.Tasks.Dialyzer.run_dialyzer/2
    lib/mix/tasks/dialyzer.ex:195: Mix.Tasks.Dialyzer.run/1    (mix) lib/mix/task.ex:331: Mix.Task.run_task/3
    (mix) lib/mix/cli.ex:79: Mix.CLI.run_task/2

Expected behavior

Going back to RC6, everything is fine.

@paulswartz
Copy link
Author

I was also able to address it by deleting my deps and _build directory: maybe something needs to be marked as needing a re-compilation?

@jeremyjh
Copy link
Owner

jeremyjh commented Oct 4, 2019

Are you able to reproduce this? Also any chance you had previously installed Dialyxir as a mix archive?

@aboroska
Copy link

aboroska commented Oct 11, 2019

Previously my project was on 0.5.1. When upgraded to 1.0.0-rc7 I got the same crash. Deleting deps solved the issue, so seems to be some re-compile problem as suggested by @paulswartz.
(FYI I didn't install Dialyxir as a mix archive)

@paulswartz
Copy link
Author

I did not install it as an archive. Since upgrading I haven't seen the issue again, so it seems to only happen when updating the library.

@asummers
Copy link
Collaborator

Out of curiosity, do either of you specify the PLT location in your mix.exs file?

@paulswartz
Copy link
Author

I'm able to reproduce with the following steps:

  • mix new dialyzer_test
  • add {:dialyxir, "~> 0.5"} to mix.exs
  • mix deps.get
  • mix dialyzer
  • update dialyxir version to 1.0.0-rc.7
  • mix deps.get
  • mix dialyzer
  • 💥

@jeremyjh jeremyjh added this to the 1.0 milestone Nov 27, 2019
@jeremyjh
Copy link
Owner

jeremyjh commented Nov 27, 2019

I'd like to fix this, or at least have an adequate understanding and explanation of it before releasing 1.0. A lot of new users are still starting on 0.5 since that is what you land on by default in hex.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants