Error upgrading to Absinthe 1.5 or Phoenix 1.5

I am upgrading phoenix 1.4 to 1.5.1
and absinthe 1.4 to 1.5
and PubSub 1.1. to 2.0

In application.ex

  def start(_type, _args) do
    children = [
      {Phoenix.PubSub, name: MyApp.PubSub},
      {Absinthe.Subscription, [MyAppWeb.Endpoint]}

    # See
    # for other strategies and supported options
    opts = [strategy: :one_for_one, name: MyApp.Supervisor]
    Supervisor.start_link(children, opts)

in confg.exs

config: myApp, MyAppWeb.Endpoint,
  pubsub_server: MyApp.PubSub,

When I do mix phx.server

(Mix) Could not start application myapp: MyApp.Application.start(:normal, []) returned an error: shutdown: failed to start child: Absinthe.Subscription
    ** (EXIT) an exception was raised:
        ** (FunctionClauseError) no function clause matching in :elixir_aliases.do_concat/2
            (elixir 1.10.3) src/elixir_aliases.erl:120: :elixir_aliases.do_concat([[MyAppWeb.Endpoint], :Registry], "Elixir")
            (elixir 1.10.3) src/elixir_aliases.erl:108: :elixir_aliases.concat/1
            (absinthe 1.5.1) lib/absinthe/subscription/supervisor.ex:11: Absinthe.Subscription.Supervisor.init/1
            (stdlib 3.9) supervisor.erl:295: :supervisor.init/1
            (stdlib 3.9) gen_server.erl:374: :gen_server.init_it/2
            (stdlib 3.9) gen_server.erl:342: :gen_server.init_it/6
            (stdlib 3.9) proc_lib.erl:249: :proc_lib.init_p_do_apply/3

I got an error.
What is my problem?

1 Like

The docs were briefly wrong, this should be {Absinthe.Subscription, MyAppWeb.Endpoint}.


Thank you!