unnawut / licensir

An Elixir mix task that lists all the licenses used by your Mix project dependencies.
https://hex.pm/packages/licensir
MIT License
73 stars 28 forks source link

Error when running it as a an archive task #15

Closed joladev closed 5 years ago

joladev commented 5 years ago

Installed it using archive.install

➜  hello_web git:(master) mix archive.install hex licensir 0.5.0
Resolving Hex dependencies...
Dependency resolution completed:
New:
  licensir 0.5.0
  table_rex 2.0.0
* Getting licensir (Hex package)
* Getting table_rex (Hex package)
Resolving Hex dependencies...
Dependency resolution completed:
Unchanged:
  table_rex 2.0.0
All dependencies are up to date
==> table_rex
Compiling 7 files (.ex)
warning: Map.size/1 is deprecated. Use Kernel.map_size/1 instead
  lib/table_rex/renderer/text.ex:344

Generated table_rex app
==> licensir
Compiling 7 files (.ex)
Generated licensir app
Generated archive "licensir-0.5.0.ez" with MIX_ENV=prod
Are you sure you want to install "licensir-0.5.0.ez"? [Yn] 
* creating /Users/johanna/.asdf/installs/elixir/1.9.1-otp-22/.mix/archives/licensir-0.5.0

then ran mix licenses

➜  hello_web git:(master) mix licenses

Notice: This is not a legal advice. Use the information below at your own risk.
** (UndefinedFunctionError) function TableRex.quick_render!/2 is undefined (module TableRex is not available)
    TableRex.quick_render!([["cowboy", "2.6.3", "ISC"], ["cowlib", "2.7.3", "ISC"], ["file_system", "0.2.7", "WTFPL"], ["gettext", "0.16.1", "Apache 2.0"], ["hex_core", "0.6.1", "Unsure (found: Apache-2.0, Apache 2.0)"], ["jason", "1.1.2", "Apache 2.0"], ["mime", "1.3.1", "Apache 2.0"], ["phoenix", "1.4.9", "Unsure (found: MIT, Unrecognized license file content)"], ["phoenix_html", "2.13.2", "Unsure (found: MIT, Unrecognized license file content)"], ["phoenix_live_reload", "1.2.1", "MIT"], ["phoenix_live_view", "0.1.1", "Unsure (found: MIT, Unrecognized license file content)"], ["phoenix_pubsub", "1.1.2", "Unsure (found: MIT, Unrecognized license file content)"], ["plug", "1.8.3", "Apache 2.0"], ["plug_cowboy", "2.1.0", "Apache 2.0"], ["plug_crypto", "1.0.0", "Apache 2.0"], ["ranch", "1.7.1", "ISC"], ["telemetry", "0.4.0", "Apache 2.0"]], ["Package", "Version", "License"])
    lib/mix/tasks/licenses.ex:23: Mix.Tasks.Licenses.run/1
    (mix) lib/mix/task.ex:331: Mix.Task.run_task/3
    (mix) lib/mix/cli.ex:79: Mix.CLI.run_task/2
joladev commented 5 years ago

Oh, I found a closed issue describing the same thing and the fix was using 0.5.1

https://github.com/unnawut/licensir/issues/13

unnawut commented 5 years ago

Glad to see you here Johanna! Thanks for raising this. I'm updating the README accordingly.

joladev commented 5 years ago

@unnawut was just about to make a PR 😄

This is a very nice project!

unnawut commented 5 years ago

Whoops. Sorry! :bowing_man: And thank you!