kellymclaughlin / rebar3-eqc-plugin

A rebar3 plugin to enable the execution of Erlang QuickCheck properties
Apache License 2.0
13 stars 20 forks source link

Crash when (up/down)grading QuickCheck but not deleting .rebar3 #23

Open eproxus opened 7 years ago

eproxus commented 7 years ago

The following crash occurs when replacing the QuickCheck version by upgrading or downgrading it into the local Erlang install (as per the Quviq instructions). This is an example after upgrading QuickCheck from 1.40.1 to 1.40.2:

$ DEBUG=1 rebar3 eqc
===> Load global config file /Users/user/.config/rebar3/rebar.config
===> Expanded command sequence to be run: [{default,app_discovery},
                                                  {default,install_deps},
                                                  {default,lock},
                                                  {default,compile},
                                                  {default,eqc}]
===> Not adding provider default eqc from module rebar3_eqc because it already exists from module rebar3_eqc
===> Not adding provider default eqc from module rebar3_eqc because it already exists from module rebar3_eqc
===> Verifying dependencies...
===> run_hooks("/Users/user/project", pre_hooks, compile) -> no hooks defined

===> Compiling project
===> run_hooks("/Users/user/project", pre_hooks, compile) -> no hooks defined

===> run_hooks("/Users/user/project", pre_hooks, erlc_compile) -> no hooks defined

===> erlopts [debug_info,debug_info,
                     {parse_transform,eqc_cover},
                     {d,'EQC'},
                     {d,'TEST'}]
===> files to compile ["/Users/user/project/_build/eqc/lib/project/src/project_util.erl",
                              "/Users/user/project/_build/eqc/lib/project/src/project_data.erl",
                              "/Users/user/project/_build/eqc/lib/project/src/project_format.erl",
                              "/Users/user/project/_build/eqc/lib/project/src/project.erl"]
===> run_hooks("/Users/user/project", post_hooks, erlc_compile) -> no hooks defined

===> run_hooks("/Users/user/project", pre_hooks, app_compile) -> no hooks defined

===> run_hooks("/Users/user/project", post_hooks, app_compile) -> no hooks defined

===> run_hooks("/Users/user/project", post_hooks, compile) -> no hooks defined

===> run_hooks("/Users/user/project", post_hooks, compile) -> no hooks defined

Newest available version is: 1.40.2
You can download it from http://www.quviq.com
Starting Quviq QuickCheck version 1.40.1
   (compiled for R19 at {{2017,3,21},{13,42,53}})
Licence for Rexroth Bosch Group reserved until {{2017,4,12},{11,49,26}}
===> erlopts [debug_info,
                     {src_dirs,["/Users/user/project/_build/eqc/lib/project/eqc"]},
                     debug_info,
                     {parse_transform,eqc_cover},
                     {d,'EQC'},
                     {d,'TEST'}]
===> files to compile ["/Users/user/project/_build/eqc/lib/project/eqc/project_format_eqc_eqc.erl",
                              "/Users/user/project/_build/eqc/lib/project/eqc/project_util_eqc.erl",
                              "/Users/user/project/_build/eqc/lib/project/eqc/project_gen.erl",
                              "/Users/user/project/_build/eqc/lib/project/eqc/project_data_eqc.erl",
                              "/Users/user/project/_build/eqc/lib/project/eqc/project_format_eqc.erl"]
===> Uncaught error in rebar_core. Run with DEBUG=1 to see stacktrace or consult rebar3.crashdump
===> Uncaught error: {badmatch,{error,enoent}}
===> Stack trace to the error location:
[{rebar_erlc_compiler,modify_erlcinfo,5,
                      [{file,"/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar_erlc_compiler.erl"},
                       {line,461}]},
 {rebar_erlc_compiler,'-update_erlcinfo_fun/2-fun-0-',4,
                      [{file,"/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar_erlc_compiler.erl"},
                       {line,447}]},
 {lists,foldl,3,[{file,"lists.erl"},{line,1263}]},
 {rebar_erlc_compiler,update_erlcinfo,3,
                      [{file,"/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar_erlc_compiler.erl"},
                       {line,432}]},
 {rebar_erlc_compiler,'-update_erlcinfo_fun/2-fun-0-',4,
                      [{file,"/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar_erlc_compiler.erl"},
                       {line,447}]},
 {lists,foldl,3,[{file,"lists.erl"},{line,1263}]},
 {rebar_erlc_compiler,init_erlcinfo,4,
                      [{file,"/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar_erlc_compiler.erl"},
                       {line,395}]},
 {rebar_erlc_compiler,compile_dirs,5,
                      [{file,"/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar_erlc_compiler.erl"},
                       {line,195}]}]
===> When submitting a bug report, please include the output of `rebar3 report "your command"`

If the .rebar3 folder is removed, everything works. This might be a bug in Rebar 3 itself.

Report:

$ rebar3 report "eqc"
Rebar3 report
 version 3.3.6
 generated at 2017-04-12T09:04:14+00:00
=================
Please submit this along with your issue at https://github.com/erlang/rebar3/issues (and feel free to edit out private information, if any)
-----------------
Task: eqc
Entered as:
  eqc
-----------------
Operating System: x86_64-apple-darwin16.4.0
ERTS: Erlang/OTP 19 [erts-8.3] [source] [64-bit] [smp:4:4] [async-threads:0] [hipe] [kernel-poll:false]
Root Directory: /Users/user/.asdf/installs/erlang/19.3/lib/erlang
Library directory: /Users/user/.asdf/installs/erlang/19.3/lib/erlang/lib
-----------------
Loaded Applications:
bbmustache: 1.3.0
certifi: 0.4.0
cf: 0.1.2
common_test: 1.14
compiler: 7.0.4
crypto: 3.7.3
cth_readable: 1.2.4
dialyzer: 3.1
edoc: 0.8.1
erlware_commons: 1.0.0
eunit: 2.3.2
eunit_formatters: 0.3.1
getopt: 0.8.2
inets: 6.3.6
kernel: 5.2
providers: 1.6.0
public_key: 1.4
relx: 3.22.3
sasl: 3.0.3
snmp: 5.2.5
ssl_verify_fun: 1.1.1
stdlib: 3.3
syntax_tools: 2.1.1
tools: 2.9.1

-----------------
Escript path: /Users/user/.bin/rebar3
Providers:
  app_discovery as clean compile compile config cover ct cut deps dialyzer do docs edoc eqc escriptize eunit geas get-deps help info install install_deps key list lock new owner path pkgs publish release relup report search shell state tartree unlock update upgrade upgrade upgrade user version xref