tesla icon indicating copy to clipboard operation
tesla copied to clipboard

Document the need for telemetry in the mix file

Open nathany-copia opened this issue 1 year ago • 3 comments

When adding Tesla.Middleware.Telemetry to a number of different projects, I see this error when running the test suite:

function Tesla.Middleware.Telemetry.call/3 is undefined (module Tesla.Middleware.Telemetry is not available)

This is in combination with exvcr, though not sure if it's related. I don't actually need to capture telemetry during the test suite, but is there a clean way to not cause this error under test while still having basic Telemetry enabled when running in production?

Update: Actually I'm seeing the same error in mix tasks too. 🤔

Not seeing what I'm missing from https://hexdocs.pm/tesla/Tesla.Middleware.Telemetry.html

I'm trying to use Telemetry along with AppSignal -- which appears to work fine when Tesla is used in my Phoenix repository.

But getting this error when working with small client libraries that I've written (which don't themselves include AppSignal).

https://docs.appsignal.com/elixir/integrations/tesla.html

Is :telemetry.attach required? Or do I need to add AppSignal to all my client libraries?

nathany-copia avatar Aug 18 '23 18:08 nathany-copia