erlef / rebar3_hex

Rebar3 Hex library
Apache License 2.0
101 stars 49 forks source link

rebar3 hex info fails with function_clause exception #48

Closed jaseemabid closed 4 years ago

jaseemabid commented 8 years ago

Migrated from https://github.com/erlang/rebar3/issues/1195

$ DEBUG=1 rebar3 hex info lager

===> Load global config file /Users/j/.config/rebar3/rebar.config
===> Expanded command sequence to be run: []
===> Expanded command sequence to be run: [{hex,info}]
lager
  Releases: 3.0.2, 3.0.1, 2.1.1
===> Uncaught error in rebar_core. Run with DEBUG=1 to see stacktrace
===> Uncaught error: function_clause
===> Stack trace to the error location: [{rebar3_hex_info,
                                                 '-join/1-lc$^0/1-0-',
                                                 [nil],
                                                 [{file,
                                                   "/Users/j/.cache/rebar3/plugins/rebar3_hex/src/rebar3_hex_info.erl"},
                                                  {line,184}]},
                                                {rebar3_hex_info,join,1,
                                                 [{file,
                                                   "/Users/j/.cache/rebar3/plugins/rebar3_hex/src/rebar3_hex_info.erl"},
                                                  {line,184}]},
                                                {rebar3_hex_info,package,1,
                                                 [{file,
                                                   "/Users/j/.cache/rebar3/plugins/rebar3_hex/src/rebar3_hex_info.erl"},
                                                  {line,152}]},
                                                {rebar3_hex_info,do,1,
                                                 [{file,
                                                   "/Users/j/.cache/rebar3/plugins/rebar3_hex/src/rebar3_hex_info.erl"},
                                                  {line,42}]},
                                                {rebar_core,do,2,
                                                 [{file,
                                                   "/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar_core.erl"},
                                                  {line,125}]},
                                                {rebar_prv_do,do_tasks,2,
                                                 [{file,
                                                   "/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar_prv_do.erl"},
                                                  {line,68}]},
                                                {rebar_core,do,2,
                                                 [{file,
                                                   "/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar_core.erl"},
                                                  {line,125}]},
                                                {rebar3,main,1,
                                                 [{file,
                                                   "/home/tristan/Devel/rebar3/_build/default/lib/rebar/src/rebar3.erl"},
                                                  {line,56}]}]
===> When submitting a bug report, please include the output of `rebar3 report "your command"`

Report output:

Rebar3 report
 version 3.1.0
 generated at 2016-05-17T09:35:34+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: hex
Entered as:
  hex info lager
-----------------
Operating System: x86_64-apple-darwin15.3.0
ERTS: Erlang/OTP 18 [erts-7.3] [source] [64-bit] [smp:4:4] [async-threads:0] [hipe] [kernel-poll:false] [dtrace]
Root Directory: /usr/local/Cellar/erlang/18.3/lib/erlang
Library directory: /usr/local/Cellar/erlang/18.3/lib/erlang/lib
-----------------
Loaded Applications:
bbmustache: 1.0.4
certifi: 0.4.0
cf: 0.2.1
common_test: 1.12
compiler: 6.0.3
crypto: 3.6.3
cth_readable: 1.2.2
dialyzer: 2.9
edoc: 0.7.18
erlware_commons: 0.19.0
eunit: 2.2.13
eunit_formatters: 0.3.1
getopt: 0.8.2
inets: 6.2
kernel: 4.2
providers: 1.6.0
public_key: 1.1.1
relx: 3.17.0
sasl: 2.7
snmp: 5.2.2
ssl_verify_hostname: 1.0.5
stdlib: 2.8
syntax_tools: 1.7
tools: 2.8.3

-----------------
Escript path: /Users/j/bin/rebar3
Providers:
  app_discovery as auto clean compile compile config cover ct cut deps dialyzer do docs edoc escriptize eunit help info install install_deps key list lock new owner path pkgs publish release relup report search shell state tar tree unlock update upgrade upgrade upgrade user version xref 
tsloughter commented 8 years ago

Hm, do you have [nil] in your .app.src for contributors?

jaseemabid commented 8 years ago

No. The key is missing. https://github.com/basho/lager/blob/master/src/lager.app.src

tsloughter commented 8 years ago

Can you try the rebar3_hex I just published, 2.5.1?

jaseemabid commented 8 years ago

Just tried.

DEBUG=1 rebar3 hex owner list lager
===> Load global config file /Users/j/.config/rebar3/rebar.config
===> Expanded command sequence to be run: []
===> Expanded command sequence to be run: [{hex,owner}]
===> Failed to retrieve package information
starbelly commented 4 years ago

This issue should be resolved in later rebar3_hex versions. Please re-open this issue if you find otherwise.