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

latest rebar3 compatibility issue #24

Open
key-master opened this issue Apr 16, 2020 · 4 comments
Open

latest rebar3 compatibility issue #24

key-master opened this issue Apr 16, 2020 · 4 comments

Comments

@key-master
Copy link

key-master commented Apr 16, 2020

It looks like recent rebar3 update have broken rebar3_erllambda

reproduction steps:
rebar3 version:

rebar 3.13.0+build.4578.ref9076a48 on Erlang/OTP 21 Erts 10.3.5.3

rebar.config

{plugins,
 [
  rebar3_erllambda
 ]}.

command:

kirill@docker:~/rebar3_test$ DEBUG=1 ~/.cache/rebar3/bin/rebar3 local install
===> Fetching rebar3_erllambda v1.1.1
===> Downloaded package, caching at /home/kirill/.cache/rebar3/hex/hexpm/packages/rebar3_erllambda-1.1.1.tar
===> Writing {pkg,<<"rebar3_erllambda">>,<<"1.1.1">>,
                         <<"0A01EF4B6F8FEB0A2FC5F806BD9AE03CB728B50AAE40FD2E3010C3F7F52F2726">>,
                         <<"B30B6EB5208D266730862EDF4D7475EADFF78908CF9B0D54B5E7DEB183017CBA">>,
                         #{api_key => undefined,api_organization => undefined,
                           api_repository => undefined,
                           api_url => <<"https://hex.pm/api">>,
                           http_adapter => r3_hex_http_httpc,
                           http_adapter_config => #{profile => rebar},
                           http_etag => undefined,http_headers => #{},
                           http_user_agent_fragment =>
                               <<"(rebar3/3.13.0+build.4578.ref9076a48) (httpc)">>,
                           name => <<"hexpm">>,repo_key => undefined,
                           repo_name => <<"hexpm">>,
                           repo_organization => undefined,
                           repo_public_key =>
                               <<"-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEApqREcFDt5vV21JVe2QNB\nEdvzk6w36aNFhVGWN5toNJRjRJ6m4hIuG4KaXtDWVLjnvct6MYMfqhC79HAGwyF+\nIqR6Q6a5bbFSsImgBJwz1oadoVKD6ZNetAuCIK84cjMrEFRkELtEIPNHblCzUkkM\n3rS9+DPlnfG8hBvGi6tvQIuZmXGCxF/73hU0/MyGhbmEjIKRtG6b0sJYKelRLTPW\nXgK7s5pESgiwf2YC/2MGDXjAJfpfCd0RpLdvd4eRiXtVlE9qO9bND94E7PgQ/xqZ\nJ1i2xWFndWa6nfFnRxZmCStCOZWYYPlaxr+FZceFbpMwzTNs4g3d4tLNUcbKAIH4\n0wIDAQAB\n-----END PUBLIC KEY-----">>,
                           repo_url => <<"https://repo.hex.pm">>,
                           repo_verify => true,repo_verify_origin => true}} to cache at /home/kirill/.cache/rebar3/hex/hexpm/packages/rebar3_erllambda-1.1.1.tar
===> sh info:
	cwd: "/home/kirill/rebar3_test"
	cmd: rm -rf /home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda

===> 	opts: [{use_stdout,false},abort_on_error]

===> Port Cmd: rm -rf /home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda
Port Opts: [exit_status,
            {line,16384},
            use_stdio,stderr_to_stdout,hide,eof,binary]

===> Moving checkout "/tmp/.tmp_dir511852571684" to "/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda"
===> sh info:
	cwd: "/home/kirill/rebar3_test"
	cmd: mv /tmp/.tmp_dir511852571684 /home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda

===> 	opts: [{use_stdout,false},abort_on_error]

===> Port Cmd: mv /tmp/.tmp_dir511852571684 /home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda
Port Opts: [exit_status,
            {line,16384},
            use_stdio,stderr_to_stdout,hide,eof,binary]

===> Compile (untagged)
===> run_hooks("/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda", pre_hooks, compile) -> no hooks defined

===> run_hooks("/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda", pre_hooks, erlc_compile) -> no hooks defined

===> FILE "provider.erl" NOT FOUND
===> Compiling rebar3_erllambda
===> erlopts [debug_info]
===> files to compile ["/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda/src/rebar3_erllambda.erl",
                              "/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda/src/rebar3_erllambda_zip.erl",
                              "/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda/src/rebar3_erllambda_release.erl"]
===> Starting 2 compile worker(s)
===>      Compiled /home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda/src/rebar3_erllambda.erl
_build/default/plugins/rebar3_erllambda/src/rebar3_erllambda_release.erl:62: Warning: variable 'HandlerInfo' is unused

===>      Compiled /home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda/src/rebar3_erllambda_release.erl
===>      Compiled /home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda/src/rebar3_erllambda_zip.erl
===> run_hooks("/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda", post_hooks, erlc_compile) -> no hooks defined

===> run_hooks("/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda", pre_hooks, app_compile) -> no hooks defined

===> run_hooks("/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda", post_hooks, app_compile) -> no hooks defined

===> run_hooks("/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda", post_hooks, compile) -> no hooks defined

===> error: undef [{relx,opt_spec_list,[],[]},
                          {rebar3_erllambda_release,init,1,
                              [{file,
                                   "/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda/src/rebar3_erllambda_release.erl"},
                               {line,41}]},
                          {rebar3_erllambda,init,1,
                              [{file,
                                   "/home/kirill/rebar3_test/_build/default/plugins/rebar3_erllambda/src/rebar3_erllambda.erl"},
                               {line,22}]},
                          {rebar_state,'-create_logic_providers/2-fun-0-',2,
                              [{file,
                                   "/tmp/rebar3.32IFw3/rebar3/src/rebar_state.erl"},
                               {line,491}]},
                          {lists,foldl,3,[{file,"lists.erl"},{line,1263}]},
                          {rebar_state,create_logic_providers,2,
                              [{file,
                                   "/tmp/rebar3.32IFw3/rebar3/src/rebar_state.erl"},
                               {line,490}]},
                          {rebar_plugins,'-handle_plugins/4-fun-0-',4,
                              [{file,
                                   "/tmp/rebar3.32IFw3/rebar3/src/rebar_plugins.erl"},
                               {line,101}]},
                          {lists,foldl,3,[{file,"lists.erl"},{line,1263}]}]
===> Failed creating providers. Run with DEBUG=1 for stacktrace or consult rebar3.crashdump.

@velimir could you please take a look
@motobob FYI

@motobob
Copy link

motobob commented Apr 16, 2020

try to clean you local rebar3 cache and relx.

@key-master
Copy link
Author

I had removed ~/.cache before logs capture for this issue.

@velimir
Copy link
Contributor

velimir commented Apr 17, 2020

@key-master in the latest changes of rebar3, integration with relx (version 4.0.0) was modified, which has broken backward compatibility.

Would you please try to downgrade the rebar3 to the latest stable version of the rebar3 which is 3.13.0 and try that again?

Thanks for reporting though, as soon as the modifications to the rebar3 are released rebar3_erllambda should be modified accordingly.

@key-master
Copy link
Author

rebar3 version 3.13.1 works fine

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

No branches or pull requests

3 participants