Closed nathany-copia closed 2 weeks ago
I'm only running with Elixir 1.16.3 but I also get these warnings:
==> pigeon
Compiling 28 files (.ex)
warning: Supervisor.Spec.worker/3 is deprecated. Use the new child specifications outlined in the Supervisor module instead
│
167 │ worker = worker(Pigeon.Worker, [Config.new(name)], id: name)
│ ~
│
└─ (pigeon 1.6.2) lib/pigeon/fcm.ex:167:14: Pigeon.FCM.start_connection/1
warning: Supervisor.Spec.supervisor/2 is deprecated. Use the new child specifications outlined in the Supervisor module instead
│
38 │ [supervisor(Task.Supervisor, [[name: Pigeon.Tasks]])]
│ ~
│
└─ (pigeon 1.6.2) lib/pigeon.ex:38:6: Pigeon.task_supervisors/0
warning: Supervisor.Spec.worker/3 is deprecated. Use the new child specifications outlined in the Supervisor module instead
│
34 │ [worker(APNS.Token, [%{}], restart: :permanent, shutdown: 5_000)]
│ ~
│
└─ (pigeon 1.6.2) lib/pigeon.ex:34:6: Pigeon.apns_token_agent/0
└─ (pigeon 1.6.2) lib/pigeon.ex:58:5: Pigeon.worker/1
└─ (pigeon 1.6.2) lib/pigeon.ex:62:5: Pigeon.worker/1
└─ (pigeon 1.6.2) lib/pigeon.ex:85:11: Pigeon.workers_for/3
└─ (pigeon 1.6.2) lib/pigeon.ex:104:12: Pigeon.start_connection/1
warning: Supervisor.Spec.worker/3 is deprecated. Use the new child specifications outlined in the Supervisor module instead
│
128 │ Supervisor.start_child(:pigeon, worker(Pigeon.Worker, [config], id: name))
│ ~
│
└─ (pigeon 1.6.2) lib/pigeon/apns.ex:128:37: Pigeon.APNS.start_connection/1
warning: Supervisor.Spec.worker/3 is deprecated. Use the new child specifications outlined in the Supervisor module instead
│
159 │ Supervisor.start_child(:pigeon, worker(Worker, [config], id: name))
│ ~
│
└─ (pigeon 1.6.2) lib/pigeon/adm.ex:159:37: Pigeon.ADM.start_connection/1
Generated pigeon app
Yeah, that was reported in #220 as well.
For whatever reason, the Elixir 1.17 warning is showing up in the test suite of a calling application, whereas the Supervisor warnings only show up when compiling pigeon. 🤷🏻
I'd fix those warnings too, but to be honest, I'm not that familiar with supervisors yet.
Environment
elixir --version
): Elixir 1.17.0 rc.0 https://github.com/elixir-lang/elixir/releases/tag/v1.17.0-rc.0Current behavior
Expected behavior
No warnings from the Elixir compiler.