datadog/client.NewClientWith swallows errors

Open
#97 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
38/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Stale
Tech stack
go

Research direction

Start with datadog/client.NewClientWith and the dial call it makes, then inspect callers to understand the current return contract. Confirm how dial failures should be propagated and ensure the completed behavior lets callers detect initialization errors instead of only logging them.

Written by the indexing model from the issue text.

Description

When constructing a new DataDog client with this method, I noticed that if the call to dial fails the error is only logged. Returning the error would let callers take specific actions during their application's initialization.

I realize this proposal is a breaking change; if you all think this is a good idea I would be willing to create the patch!

Dominant language
Go
Stars
215
Forks
31
Avg merge
44m
Merged PRs (30d)
2

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from segmentio/stats

All issues in segmentio/stats

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.