tesla
tesla copied to clipboard
Document the need for telemetry in the mix file
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?
Looks like adding AppSignal to the library works, but this feels like there could be better documentation in one place or another.
The Tesla readme doesn't even link to the Telemetry middleware yet. Is that intentional?
I'm an idiot -- needed to add {:telemetry, "~> 1.2"},
to the mix file (which AppSignal brought in automatically in the place I had it).
But that should be documented, yes?
The Tesla readme doesn't even link to the Telemetry middleware yet. Is that intentional?
It wasn't. Feel free to add it!
But that should be documented, yes?
By all means, please improve the docs!