i-n-g-m-a-r

i-n-g-m-a-r OP

Running mix test on a new Phoenix installation (1.5.9) results in many “Function passed as a handler with ID’” messages.

Does anyone know whether this is a problem and how to solve it?

Thank you.

09:13:48.858 [info]  Function passed as a handler with ID {Phoenix.Logger, [:phoenix, :channel_handled_in]} is local function.
This mean that it is either anonymous function or capture of function without module specified. That may cause performance penalty when calling such handler. For more details see note in `telemetry:attach/4` documentation.

https://hexdocs.pm/telemetry/telemetry.html#attach-4

09:13:48.871 [info]  Function passed as a handler with ID {Phoenix.Logger, [:phoenix, :channel_joined]} is local function.
This mean that it is either anonymous function or capture of function without module specified. That may cause performance penalty when calling such handler. For more details see note in `telemetry:attach/4` documentation.

https://hexdocs.pm/telemetry/telemetry.html#attach-4

09:13:48.871 [info]  Function passed as a handler with ID {Phoenix.Logger, [:phoenix, :endpoint, :start]} is local function.
This mean that it is either anonymous function or capture of function without module specified. That may cause performance penalty when calling such handler. For more details see note in `telemetry:attach/4` documentation.

https://hexdocs.pm/telemetry/telemetry.html#attach-4

09:13:48.871 [info]  Function passed as a handler with ID {Phoenix.Logger, [:phoenix, :endpoint, :stop]} is local function.
This mean that it is either anonymous function or capture of function without module specified. That may cause performance penalty when calling such handler. For more details see note in `telemetry:attach/4` documentation.

https://hexdocs.pm/telemetry/telemetry.html#attach-4

09:13:48.872 [info]  Function passed as a handler with ID {Phoenix.Logger, [:phoenix, :error_rendered]} is local function.
This mean that it is either anonymous function or capture of function without module specified. That may cause performance penalty when calling such handler. For more details see note in `telemetry:attach/4` documentation.

https://hexdocs.pm/telemetry/telemetry.html#attach-4

09:13:48.872 [info]  Function passed as a handler with ID {Phoenix.Logger, [:phoenix, :router_dispatch, :start]} is local function.
This mean that it is either anonymous function or capture of function without module specified. That may cause performance penalty when calling such handler. For more details see note in `telemetry:attach/4` documentation.

https://hexdocs.pm/telemetry/telemetry.html#attach-4

09:13:48.872 [info]  Function passed as a handler with ID {Phoenix.Logger, [:phoenix, :socket_connected]} is local function.
This mean that it is either anonymous function or capture of function without module specified. That may cause performance penalty when calling such handler. For more details see note in `telemetry:attach/4` documentation.

https://hexdocs.pm/telemetry/telemetry.html#attach-4

First 7 of 7 Posts Switch mode

03juan

03juan

I just tried it on a fresh 1.5.9 install and don’t see those errors. Did you make any changes to the dependencies?

Out the box phx_new 1.5.9 depends on telemetry_poller v0.4 which would install v0.5.1, but the link in the errors suggests you’re using 1.0, which depends on telemetry 1.0, so you may have a version mismatch.

hauleth

hauleth

Update Phoenix.

Yes, I know whether it is problem - I have implemented that warning.

It can be problem in production as calling local captures between processes (and storing them in ETS) can be quite expensive due to BEAM guarantees about local calls. Remote captures (aka one in form of &module.function/arity) are much less expensive, as these are almost equivalent to just 3-ary tuple ({module, function, arity}). Phoenix used local captures there in the past, and now it is fixed.

03juan

03juan

If they want to use 1.5.9 to follow a book or tutorials, would it be easy to change where those calls are made? Or at least they can live with the warnings. Unless the intention is a production system, in which case definitely upgrade.

i-n-g-m-a-r

i-n-g-m-a-r OP

Below is the output for mix deps.update --all
My mix.exs file defines {:phoenix, "~> 1.5.9"}
The actual phoenix version seems to be phoenix 1.5.13
The messages remain the same.

  connection 1.1.0
  cowboy 2.9.0
  cowboy_telemetry 0.4.0
  cowlib 2.11.0
  db_connection 2.4.1
  decimal 2.0.0
  ecto 3.7.1
  ecto_sql 3.7.2
  elixir_uuid 1.2.1
  file_system 0.2.10
  gettext 0.19.1
  jason 1.3.0
  mime 2.0.2
  oban 2.11.1
  phoenix 1.5.13
  phoenix_ecto 4.4.0
  phoenix_html 2.14.3
  phoenix_live_dashboard 0.6.5
  phoenix_live_reload 1.3.3
  phoenix_live_view 0.17.7
  phoenix_pubsub 2.0.0
  plug 1.13.3
  plug_cowboy 2.5.2
  plug_crypto 1.2.2
  postgrex 0.16.2
  ranch 1.8.0
  telemetry 1.0.0
  telemetry_metrics 0.6.1
  telemetry_poller 1.0.0

03juan

03juan

Yes if the project was initialised with phoenix 1.5.x and now you’ve upgraded telemetry to 1.0 and live_view to 0.17 then why not upgrade to phoenix 1.6 as per @hauleth?

i-n-g-m-a-r

i-n-g-m-a-r OP

Thank you both, that works.

It didn’t occur to me that mix phx.new would not install the latest version.
I should pay better attention.

03juan

03juan

You need to upgrade the phx_new package from hex every time a new Phoenix version is released.

 mix archive.install hex phx_new latest

Or at least before you start a new project.

— All posts loaded —

Where Next? Top

Trending in Questions Top

stjefim
Hello! Suppose you are building workflow (order / task / payment) processing system with the following requirements: Each workflow con...
New
jonnycharles
I’m in search of an Elixir library that offers PDF generation capabilities similar to Ruby’s Prawn. While there have been discussions abo...
New
spammy
I’m looking to build a personal workflow to quickly deploy web applications written in elixir/phoenix, for local consumption (ie not on t...
New
dli
Before I dive in myself, did anyone successfully sprinkle Hologram into their existing LiveView app? Looking for hints regarding: Addi...
New
bottlenecked
Hi all, I wanted to ask how the community is dealing with post-release steps. Today we have Ecto migrations, which make sure that the db...
New
roeland
Kia ora, We have been using elixir-google-api to connect to Google Drive. However, with the updates to Tesla due to CVEs this is now bro...
New
michallepicki
I am using Oban and occasionally, shortly after a deployment, a handful of jobs can fail because of dependency on other parts of the syst...
New

Other Trending Topics Top

JesseHerrick
Hey, I’m Jesse and I’m the main contributor behind Dexter, a full-featured, lightning-fast Elixir LSP optimized for large codebases. It s...
New
jimsynz
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
Damirados
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge & Solve. They are GUI (Emerge) and State management (S...
New
netoum
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New
ausimian
Emily is an Elixir library that runs Nx computations on Apple’s MLX. Install it as the default Nx backend and Nx, defn, Axon, Nx.Serving,...
New
juhalehtonen
There has been a thread to discuss the Stack Overflow Developer Survey on this forum every year since 2018, so here’s yet another one for...
New

We're in Beta

About us Mission Statement