Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix complication bug in Go Resources page #3949

Merged
merged 1 commit into from
Feb 6, 2024
Merged

Conversation

pellared
Copy link
Member

@pellared pellared commented Feb 6, 2024

The example of resource.New does not even compile.

I updated the example to match open-telemetry/opentelemetry-go#4887

@pellared pellared changed the title Go: Fix resources page Fix complication bug in Go Resources page Feb 6, 2024
@pellared pellared marked this pull request as ready for review February 6, 2024 12:32
@pellared pellared requested review from a team February 6, 2024 12:32
@theletterf
Copy link
Member

@open-telemetry/go-instrumentation-maintainers Please have a look — thanks!

@pellared
Copy link
Member Author

pellared commented Feb 6, 2024

@open-telemetry/go-instrumentation-maintainers Please have a look — thanks!

@open-telemetry/go-approvers 😉

@cartermp cartermp merged commit 031d52c into main Feb 6, 2024
16 checks passed
@cartermp cartermp deleted the pellared-patch-1 branch February 6, 2024 13:11
)
if err != nil {
log.Println(err) // Log issues during resource creation. Note that resource.New still returns a resource.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure this is guaranteed. We make this guarantee for two specific error types, but the user needs to check res is not nil before they can safely use it in all cases.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will make a followup PR once open-telemetry/opentelemetry-go#4887 is merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants