I started freash again with the minimal example and put
defp deps do
[
{:phoenix, "~> 1.5.3"},
{:phoenix_html, "~> 2.11"},
{:phoenix_live_reload, "~> 1.2", only: :dev},
{:phoenix_live_dashboard, "~> 0.2.0"},
{:telemetry_metrics, "~> 0.4"},
{:telemetry_poller, "~> 0.4"},
{:gettext, "~> 0.11"},
{:jason, "~> 1.0"},
{:plug_cowboy, "~> 2.0"},
{:gun, github: "ninenines/gun"}
]
end
in mix.exs
but then I get
$ mix deps.get
* Getting gun (https://github.com/ninenines/gun.git)
remote: Enumerating objects: 59, done.
remote: Counting objects: 100% (59/59), done.
remote: Compressing objects: 100% (36/36), done.
remote: Total 2990 (delta 12), reused 45 (delta 9), pack-reused 2931
Empfange Objekte: 100% (2990/2990), 1.22 MiB | 285.00 KiB/s, Fertig.
Löse Unterschiede auf: 100% (1841/1841), Fertig.
* Getting cowlib (https://github.com/ninenines/cowlib)
remote: Enumerating objects: 74, done.
remote: Counting objects: 100% (74/74), done.
remote: Compressing objects: 100% (57/57), done.
remote: Total 1617 (delta 20), reused 52 (delta 11), pack-reused 1543
Empfange Objekte: 100% (1617/1617), 978.08 KiB | 0 bytes/s, Fertig.
Löse Unterschiede auf: 100% (1057/1057), Fertig.
Resolving Hex dependencies...
Dependency resolution completed:
Unchanged:
cowboy 2.8.0
cowlib 2.9.1
file_system 0.2.8
gettext 0.18.0
jason 1.2.1
mime 1.3.1
phoenix 1.5.3
phoenix_html 2.14.2
phoenix_live_dashboard 0.2.6
phoenix_live_reload 1.2.4
phoenix_live_view 0.13.3
phoenix_pubsub 2.0.0
plug 1.10.3
plug_cowboy 2.3.0
plug_crypto 1.1.2
ranch 1.7.1
telemetry 0.4.2
telemetry_metrics 0.5.0
telemetry_poller 0.5.1
Dependencies have diverged:
* cowlib (https://github.com/ninenines/cowlib)
different specs were given for the cowlib app:
> In deps/gun/rebar.config:
{:cowlib, ~r/.*/, [env: :prod, override: true, git: "https://github.com/ninenines/cowlib", ref: "2.9.0"]}
> In deps/cowboy/rebar.config:
{:cowlib, "~> 2.9.1", [env: :prod, hex: "cowlib", repo: "hexpm", optional: false]}
Ensure they match or specify one of the above in your deps and set "override: true"
** (Mix) Can't continue due to errors on dependencies
$ mix deps.unlock cowlib
$ mix deps.get
* Updating cowlib (https://github.com/ninenines/cowlib)
Resolving Hex dependencies...
Dependency resolution completed:
Unchanged:
cowboy 2.8.0
file_system 0.2.8
gettext 0.18.0
jason 1.2.1
mime 1.3.1
phoenix 1.5.3
phoenix_html 2.14.2
phoenix_live_dashboard 0.2.6
phoenix_live_reload 1.2.4
phoenix_live_view 0.13.3
phoenix_pubsub 2.0.0
plug 1.10.3
plug_cowboy 2.3.0
plug_crypto 1.1.2
ranch 1.7.1
telemetry 0.4.2
telemetry_metrics 0.5.0
telemetry_poller 0.5.1
New:
cowlib 2.9.1
Dependencies have diverged:
* cowlib (https://github.com/ninenines/cowlib)
different specs were given for the cowlib app:
> In deps/gun/rebar.config:
{:cowlib, ~r/.*/, [env: :prod, override: true, git: "https://github.com/ninenines/cowlib", ref: "2.9.0"]}
> In deps/cowboy/rebar.config:
{:cowlib, "~> 2.9.1", [env: :prod, hex: "cowlib", repo: "hexpm", optional: false]}
Ensure they match or specify one of the above in your deps and set "override: true"
** (Mix) Can't continue due to errors on dependencies
peter@ux550vdp:~/tmpdir/test$ ls
assets _build config deps lib mix.exs mix.lock priv README.md test
$ vim mix.exs
I then tried
defp deps do
[
{:phoenix, "~> 1.5.3"},
{:phoenix_html, "~> 2.11"},
{:phoenix_live_reload, "~> 1.2", only: :dev},
{:phoenix_live_dashboard, "~> 0.2.0"},
{:telemetry_metrics, "~> 0.4"},
{:telemetry_poller, "~> 0.4"},
{:gettext, "~> 0.11"},
{:jason, "~> 1.0"},
{:plug_cowboy, "~> 2.0"},
{:cowlib, "~> 1.9.0", override: true},
{:gun, github: "ninenines/gun"}
]
end
to fix cowlib the lower version of the two (2.9.1
and 2.9.0
) as before, where it had worked (2.6.0
):
$ mix deps.get
** (Mix) No matching version for cowlib ~> 1.9.0 (from: mix.exs) in registry
The latest version is: 2.9.1
If there is an obvious mistake that I have made then please tell me but I think you already helped me a lot and I consider this as suffifiently solved (i.e. that the reason is outdated latest version of gun in hex.pm). Both of you, thank you very much.